diff options
author | Anthony Neal <aneal@zeroc.com> | 2002-03-13 20:10:07 +0000 |
---|---|---|
committer | Anthony Neal <aneal@zeroc.com> | 2002-03-13 20:10:07 +0000 |
commit | 27c5fa0a95a523c5bea82eecc420e805b4533aae (patch) | |
tree | b18f7be9632d266d7e8f6c16b02de831a3e11d57 /cpp/src/Ice/SslRSAKeyPair.cpp | |
parent | cleanup (diff) | |
download | ice-27c5fa0a95a523c5bea82eecc420e805b4533aae.tar.bz2 ice-27c5fa0a95a523c5bea82eecc420e805b4533aae.tar.xz ice-27c5fa0a95a523c5bea82eecc420e805b4533aae.zip |
Refactor of SSL Extension, phase 1.
Diffstat (limited to 'cpp/src/Ice/SslRSAKeyPair.cpp')
-rw-r--r-- | cpp/src/Ice/SslRSAKeyPair.cpp | 40 |
1 files changed, 22 insertions, 18 deletions
diff --git a/cpp/src/Ice/SslRSAKeyPair.cpp b/cpp/src/Ice/SslRSAKeyPair.cpp index 9f18a5e3af3..4ffe2033976 100644 --- a/cpp/src/Ice/SslRSAKeyPair.cpp +++ b/cpp/src/Ice/SslRSAKeyPair.cpp @@ -15,69 +15,73 @@ #include <Ice/SslRSAPublicKey.h>
#include <assert.h>
-void ::IceInternal::incRef(::IceSecurity::Ssl::OpenSSL::RSAKeyPair* p) { p->__incRef(); }
-void ::IceInternal::decRef(::IceSecurity::Ssl::OpenSSL::RSAKeyPair* p) { p->__decRef(); }
+void ::IceInternal::incRef(::IceSSL::OpenSSL::RSAKeyPair* p) { p->__incRef(); }
+void ::IceInternal::decRef(::IceSSL::OpenSSL::RSAKeyPair* p) { p->__decRef(); }
using std::back_inserter;
using std::string;
using Ice::ByteSeq;
using IceUtil::Base64;
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::RSAKeyPair(const string& key, const string& cert) :
- _privateKey(new RSAPrivateKey(key)),
- _publicKey(new RSAPublicKey(cert))
+IceSSL::OpenSSL::RSAKeyPair::RSAKeyPair(const string& key, const string& cert) :
+ _privateKey(new RSAPrivateKey(key)),
+ _publicKey(new RSAPublicKey(cert))
{
+ assert(_privateKey != 0);
+ assert(_publicKey != 0);
}
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::RSAKeyPair(const ByteSeq& keySeq, const ByteSeq& certSeq) :
- _privateKey(new RSAPrivateKey(keySeq)),
- _publicKey(new RSAPublicKey(certSeq))
+IceSSL::OpenSSL::RSAKeyPair::RSAKeyPair(const ByteSeq& keySeq, const ByteSeq& certSeq) :
+ _privateKey(new RSAPrivateKey(keySeq)),
+ _publicKey(new RSAPublicKey(certSeq))
{
+ assert(_privateKey != 0);
+ assert(_publicKey != 0);
}
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::~RSAKeyPair()
+IceSSL::OpenSSL::RSAKeyPair::~RSAKeyPair()
{
}
void
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::keyToBase64(string& b64Key)
+IceSSL::OpenSSL::RSAKeyPair::keyToBase64(string& b64Key)
{
_privateKey->keyToBase64(b64Key);
}
void
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::certToBase64(string& b64Cert)
+IceSSL::OpenSSL::RSAKeyPair::certToBase64(string& b64Cert)
{
_publicKey->certToBase64(b64Cert);
}
void
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::keyToByteSeq(ByteSeq& keySeq)
+IceSSL::OpenSSL::RSAKeyPair::keyToByteSeq(ByteSeq& keySeq)
{
_privateKey->keyToByteSeq(keySeq);
}
void
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::certToByteSeq(ByteSeq& certSeq)
+IceSSL::OpenSSL::RSAKeyPair::certToByteSeq(ByteSeq& certSeq)
{
_publicKey->certToByteSeq(certSeq);
}
RSA*
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::getRSAPrivateKey() const
+IceSSL::OpenSSL::RSAKeyPair::getRSAPrivateKey() const
{
return _privateKey->getRSAPrivateKey();
}
X509*
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::getX509PublicKey() const
+IceSSL::OpenSSL::RSAKeyPair::getX509PublicKey() const
{
return _publicKey->getX509PublicKey();
}
-IceSecurity::Ssl::OpenSSL::RSAKeyPair::RSAKeyPair(const RSAPrivateKeyPtr& rsa, const RSAPublicKeyPtr& x509) :
- _privateKey(rsa),
- _publicKey(x509)
+IceSSL::OpenSSL::RSAKeyPair::RSAKeyPair(const RSAPrivateKeyPtr& rsa, const RSAPublicKeyPtr& x509) :
+ _privateKey(rsa),
+ _publicKey(x509)
{
}
|