Module: Miscellaneous
Definition in file ASN1HelperLib.h.
#include "ooasn1.h"
#include "asn1ber.h"
#include "PKIFString.h"
#include "PKIX1Implicit88.h"
#include "GeneralName.h"
#include "components.h"
Go to the source code of this file.
Functions | |
void | FreeASN1Context (OOCTXT *ctx) |
void | CopyOID (ASN1OBJID *dest, ASN1OBJID *src) |
ASN1OBJID * | ConvertStringToASN1OBJID (const CPKIFStringPtr &str) |
void | CopyGeneralName (CACX509V3GeneralName &objName, CPKIFGeneralNamePtr &gn) |
void | CopyName (CACX509V3Name **dest, CACX509V3Name &name) |
void | CopyName (CACX509V3Name *dest, CACX509V3Name &name) |
ASN1OBJID* ConvertStringToASN1OBJID | ( | const CPKIFStringPtr & | str | ) |
Interface: Subsystem
This is a helper function that converts a string representation of an oid into ASN1OBJID object
str | [in] This is a smart poiter to a CPKIFString object containing the dot form of OID that will be converted to ASN1OBJID object |
Definition at line 117 of file ASN1HelperLib.cpp.
References stringtok().
Referenced by BuildCACX509V3AttributeTypeAndValue(), CalculateHashOfArchiveTimestampChain(), CPKIFOID::CPKIFOID(), CPKIFX509Extension::Encode(), CPKIFTSTInfo::Encode(), CPKIFTimeStampResponse::Encode(), CPKIFTimeStampRequest::Encode(), CPKIFTBSRequest::Encode(), CPKIFSignedData::Encode(), CPKIFRevInfoWantBack::Encode(), CPKIFOCSPRequest::Encode(), CPKIFEvidenceRecord::Encode(), CPKIFCVRequest::Encode(), CPKIFContentInfo::Encode(), CPKIFArchiveTimestamp::Encode(), GetEncGenNameFromStr(), GetPKIFGenNameFromStr(), GetSignerInfo(), CPKIFContentTypeAttribute::GetValues(), CPKIFCryptoPPKeyMaterial::InitWithSPKI(), PopulateACReference(), PopulateDListWithASN1OBJID(), PopulateDListWithCACX509V3AlgorithmIdentifier(), PopulateKeyAgreePublicKey(), PopulatePKCReference(), PopulateQuery(), PopulateReplyObjects(), PopulateValidationPolicy(), SetupAttributesInObjectiveStructure(), and CPKIFPolicyInformationSet::value().
void CopyGeneralName | ( | CACX509V3GeneralName & | objName, | |
CPKIFGeneralNamePtr & | gn | |||
) |
Interface: External
This function is not used by applications. It is invoked internally to create a CPKIFGeneralNameList object from a CACX509V3GeneralNames structure.
CPKIFException(COMMON_INVALID_INPUT) |
objName | [in] A reference to a CACX509V3GeneralName object. |
gn | [in] A smart pointer to CPKIFGeneralName object. |
Definition at line 160 of file ASN1HelperLib.cpp.
References CACASNWRAPPER_CREATE, COMMON_INVALID_INPUT, CopyName(), CPKIFGeneralName::DIRECTORYNAME, CPKIFGeneralName::DNSNAME, CPKIFGeneralName::EDIPARTYNAME, CPKIFGeneralName::IPADDRESS, CPKIFGeneralName::NOTSET, CPKIFGeneralName::OID, CPKIFGeneralName::OTHERNAME, CPKIFGeneralName::RFC822, TOOLKIT_APP, CPKIFGeneralName::URI, and CPKIFGeneralName::X400ADDRESS.
Referenced by CPKIFTSTInfo::Encode(), CPKIFTBSRequest::Encode(), CPKIFCVRequest::Encode(), EncodeGeneralName(), CPKIFSigningCertificateAttribute::GetValues(), PopulateACReference(), PopulateDListWithCACX509V3GeneralName(), PopulatePKCReference(), PopulateReplyObjects(), and PopulateValidationPolicy().
void CopyName | ( | CACX509V3Name * | dest, | |
CACX509V3Name & | name | |||
) |
Interface: Subsystem
This is a helper function that duplocates CACX509V3Name objects
dest | [out] A pointer to a pointer to CACX509V3Name object that will contain the new CACX509V3Name |
name | [in] A referenece to CACX509V3Name object that will be copied |
Definition at line 278 of file ASN1HelperLib.cpp.
void CopyName | ( | CACX509V3Name ** | dest, | |
CACX509V3Name & | name | |||
) |
Interface: Subsystem
This is a helper function that duplocates CACX509V3Name objects
dest | [out] A pointer to a pointer to CACX509V3Name object that will contain the new CACX509V3Name |
name | [in] A referenece to CACX509V3Name object that will be copied |
Definition at line 229 of file ASN1HelperLib.cpp.
Referenced by CopyGeneralName(), GetSignerInfo(), and PopulateKARIDFromKeyMaterial().
void CopyOID | ( | ASN1OBJID * | dest, | |
ASN1OBJID * | src | |||
) |
Interface: External
This function makes a copy of an ASN1OBJID object.
dest | [in/out] A pointer to an ASN1OBJID object. |
src | [in] A pointer to an ASN1OBJID object. |
Definition at line 97 of file ASN1HelperLib.cpp.
Referenced by BuildCACX509V3AttributeTypeAndValue(), CalculateHashOfArchiveTimestampChain(), CPKIFOID::CPKIFOID(), CPKIFTSTInfo::Encode(), CPKIFTimeStampResponse::Encode(), CPKIFTimeStampRequest::Encode(), CPKIFTBSRequest::Encode(), CPKIFSignedData::Encode(), CPKIFRevInfoWantBack::Encode(), CPKIFOCSPRequest::Encode(), CPKIFEvidenceRecord::Encode(), CPKIFEnvelopedData::Encode(), CPKIFEncryptedData::Encode(), CPKIFCVRequest::Encode(), CPKIFContentInfo::Encode(), CPKIFArchiveTimestamp::Encode(), GetEncGenNameFromStr(), GetPKIFGenNameFromStr(), GetSignerInfo(), PopulateACReference(), PopulateDListWithASN1OBJID(), PopulateDListWithCACX509V3AlgorithmIdentifier(), PopulateKeyAgreePublicKey(), PopulatePKCReference(), PopulateQuery(), PopulateReplyObjects(), PopulateValidationPolicy(), SetupAttributesInObjectiveStructure(), and CPKIFPolicyInformationSet::value().
void FreeASN1Context | ( | OOCTXT * | ctx | ) |
Interface: Subsystem
This function frees memory used by OOCTXT structure. These structures are created and used internally. Applications need not invoke this function. The OOCTXT structure is defined as follows.
typedef struct _OOCTXT { // ASN.1 context block
ASN1BUFFER buffer; // data buffer ASN1BUFSAVE savedInfo; // saved buffer info ASN1ErrInfo errInfo; // run-time error info ASN1MemBlk* memBlk_p; // memory block list OSUINT32 initCode; // code double word to indicate init OSUINT16 flags; // flag bits DList fieldList; // PER field list Asn1SizeCnst* pSizeConstraint; // Size constraint list const char* pCharSet; // String of permitted characters Asn1RTStack nameStack; // Element name stack DList evtHndlrList; // Event handler object list void* errHndlrCB; // Error handler callback function
} OOCTXT;
ctx | [in] A pointer to an OOCTXT structure |
Definition at line 77 of file ASN1HelperLib.cpp.
Referenced by CPKIFASNWrapper< T >::clear(), and CPKIFASNWrapper< T >::Decode().