CryptoObject.h

00001 #ifndef CRYPTO_OBJECT_H
00002 #define CRYPTO_OBJECT_H 
00003 
00004 
00005 #include "common.h"
00006 
00011 class CryptoObject
00012 {
00013   // below are the Object ID's
00014   //Card Capability Container                  2.16.840.1.101.3.7.1.219.0
00015   //Card Holder Unique Identifier              2.16.840.1.101.3.7.2.48.0
00016   //X.509 Certificate for PIV Authentication   2.16.840.1.101.3.7.2.1.1 *** (logon)
00017   //Card Holder Fingerprint I                  2.16.840.1.101.3.7.2.96.16
00018   //Card Holder Fingerprint II                 2.16.840.1.101.3.7.2.96.17
00019   //Printed Information                        2.16.840.1.101.3.7.2.48.1
00020   //Card Holder Facial Image                   2.16.840.1.101.3.7.2.96.48
00021   //X.509 Certificate for Digital Signature    2.16.840.1.101.3.7.2.1.0 *** (signing / encrypt)
00022   //X.509 Certificate for Key Management       2.16.840.1.101.3.7.2.1.2 *** (decrypt)
00023   //X.509 Certificate for Card Authentication  2.16.840.1.101.3.7.2.5.0 
00024   //Security Object                            2.16.840.1.101.3.7.2.144.0
00025   public:
00026     
00027     // pure virtual
00028     virtual ~CryptoObject(){}
00032     virtual const char* getDescription() = 0;
00036     virtual CK_OBJECT_HANDLE getHandle() = 0;
00043     virtual CK_ATTRIBUTE* getAttribute(CK_ATTRIBUTE_TYPE type) = 0;
00047     virtual map<CK_ATTRIBUTE_TYPE,CK_ATTRIBUTE*> getAttributes() = 0;
00052     virtual CK_OBJECT_CLASS getClass() = 0;
00060     virtual CK_ATTRIBUTE* matchAttribute(CK_ATTRIBUTE* attrib) = 0;
00066     virtual bool doAllAttribsMatch(CK_ATTRIBUTE*  attributes,CK_ULONG numAttribs) = 0;
00067 
00068     
00069 };
00070 #endif

Generated on Fri Jan 12 15:48:41 2007 for NIST_PKCS11 by doxygen 1.3.1 using KingsTools