IPKIFCryptoKeyAgree.h

Go to the documentation of this file.
00001 
00009 #ifndef __IPKIFCryptoKeyAgree_H__
00010 #define __IPKIFCryptoKeyAgree_H__
00011 
00012 #include "PKIFdll.h"
00013 
00014 FD_SMART_PTR(CPKIFCredential);
00015 FD_SMART_PTR(CPKIFCertificate);
00016 FD_SMART_PTR(CPKIFBuffer);
00017 FD_SMART_PTR(CPKIFKeyMaterial);
00018 FD_SMART_PTR(IPKIFKeyAgreeContext);
00019 
00020 class CPKIFAlgorithm;
00021 
00026 class CAC_API CAC_NO_VTABLE IPKIFCryptoKeyAgree
00027 {
00028 public:
00029     IPKIFCryptoKeyAgree(); 
00030     virtual ~IPKIFCryptoKeyAgree();
00031 
00032     // ephemeral-static or static-static key agreement
00034     virtual IPKIFKeyAgreeContextPtr SecretAgree(CPKIFCredentialPtr& myPrivateKey, const CPKIFCertificatePtr& theirCert, 
00035         const CPKIFAlgorithm * alg) = 0;
00037     virtual IPKIFKeyAgreeContextPtr SecretAgree(CPKIFCredentialPtr& myPrivateKey, const CPKIFBufferPtr& theirPublicKey, 
00038         const CPKIFAlgorithm * alg) = 0;
00039 
00040     // (single-pass only) authenticated key agreement
00041     // originator interfaces
00043     virtual IPKIFKeyAgreeContextPtr SecretAgree(const CPKIFCredentialPtr& myPrivateKey, CPKIFCredentialPtr & ephemeralKeyPair,
00044         const CPKIFCertificatePtr& theirCert, const CPKIFAlgorithm * alg) = 0;
00046     virtual IPKIFKeyAgreeContextPtr SecretAgree(const CPKIFCredentialPtr& myPrivateKey, CPKIFCredentialPtr & ephemeralKeyPair,
00047         const CPKIFBufferPtr& theirPublicKey, const CPKIFAlgorithm * alg) = 0;
00048     // recipient interfaces
00050     virtual IPKIFKeyAgreeContextPtr SecretAgree(const CPKIFCredentialPtr& myPrivateKey, const CPKIFBufferPtr& ephemeralPublicKey, 
00051         const CPKIFCertificatePtr& theirCert, const CPKIFAlgorithm * alg) = 0;
00053     virtual IPKIFKeyAgreeContextPtr SecretAgree(const CPKIFCredentialPtr& myPrivateKey, const CPKIFBufferPtr& ephemeralPublicKey, 
00054         const CPKIFBufferPtr& theirPublicKey, const CPKIFAlgorithm * alg) = 0;
00055     
00057     virtual CPKIFKeyMaterialPtr DeriveKey(const IPKIFKeyAgreeContextPtr & context, unsigned long keyLen) = 0;
00058 
00059 private:
00061     IPKIFCryptoKeyAgree(const IPKIFCryptoKeyAgree& copy);
00063     IPKIFCryptoKeyAgree& operator=(const IPKIFCryptoKeyAgree& rhs); 
00064 };
00065 DECLARE_SMART_POINTERS(IPKIFCryptoKeyAgree);
00066 
00067 #endif //__IPKIFCryptoKeyAgree_H__
00068 

Generated on Mon Nov 15 11:15:51 2010 for PublicKeyInfrastructureFramework(PKIF) by  doxygen 1.5.6