|
Mixes for Privacy and Anonymity in the Internet
|
Public Member Functions | |
| ~CACertificate () | |
| CACertificate * | clone () const |
| SINT32 | encode (UINT8 *buff, UINT32 *bufflen, UINT32 type) const |
| SINT32 | encode (DOMElement *&elemRoot, XERCES_CPP_NAMESPACE::DOMDocument *doc) const |
| SINT32 | getRawSubjectKeyIdentifier (UINT8 *r_ski, UINT32 *r_skiLen) |
| SINT32 | getAuthorityKeyIdentifier (UINT8 *r_aki, UINT32 *r_akiLen) const |
| SINT32 | getSubjectKeyIdentifier (UINT8 *r_ski, UINT32 *r_skiLen) |
| LERNGRUPPE Accessor method for the subjectKeyIdentifier (SKI) extension stored in this certificate. | |
| SINT32 | setSubjectKeyIdentifier (UINT8 *a_value, UINT32 a_valueLen) |
| LERNGRUPPE Sets the subjectKeyIdentifier extension for this certificate to the given value. | |
| SINT32 | setSubjectKeyIdentifier () |
| LERNGRUPPE Sets the subjectKeyIdentifier extension for this certificate to the hash of the public key. | |
| SINT32 | verify (const CACertificate *a_cert) const |
| bool | isValid () const |
Static Public Member Functions | |
| static CACertificate * | decode (const UINT8 *const buff, UINT32 bufflen, UINT32 type, const char *const passwd=NULL) |
| Extracts a certificate from an encoded (DER,XML) form. | |
| static CACertificate * | decode (const DOMNode *node, UINT32 type, const char *passwd=NULL) |
| static UINT8 * | getXmlElementName () |
| static SINT32 | removeColons (const UINT8 *a_cSki, UINT32 a_cSkiLen, UINT8 *&r_ski, UINT32 *r_skiLen) |
| LERNGRUPPE Removes the colons from the string representation of the given SKI. | |
Private Member Functions | |
| CACertificate () | |
| CACertificate (X509 *x) | |
| X509 * | getX509 () const |
Static Private Member Functions | |
| static X509 * | decode (const UINT8 **derX509, UINT32 derX509Len) |
Private Attributes | |
| X509 * | m_pCert |
| ASN1_OCTET_STRING * | m_pSKI |
| AUTHORITY_KEYID * | m_pAKI |
Static Private Attributes | |
| static UINT8 * | m_spXmlElementName = 0 |
Friends | |
| class | CASignature |
| class | CAASymCipher |
| class | CASSLContext |
| class | CATLSClientSocket |
| CACertificate::CACertificate | ( | ) | [private] |
| CACertificate::CACertificate | ( | X509 * | x | ) | [private] |
| CACertificate* CACertificate::clone | ( | ) | const |
References CACertificate(), and m_pCert.
Referenced by CACertStore::add(), CAXMLBI::getInstance(), CACmdLnOptions::getLogEncryptionKey(), CACmdLnOptions::getNextMixTestCertificate(), CACmdLnOptions::getPrevMixTestCertificate(), CACmdLnOptions::setNextMixTestCertificate(), CACmdLnOptions::setPrevMixTestCertificate(), and CATLSClientSocket::setServerCertificate().
| CACertificate * CACertificate::decode | ( | const UINT8 *const | buff, |
| UINT32 | bufflen, | ||
| UINT32 | type, | ||
| const char *const | passwd = NULL |
||
| ) | [static] |
Extracts a certificate from an encoded (DER,XML) form.
References CACertificate(), CERT_DER, CERT_PKCS12, CERT_XML_X509CERTIFICATE, E_SUCCESS, equals(), getDOMElementValue(), and parseDOMDocument().
Referenced by decode(), CACmdLnOptions::setLoggingOptions(), CACmdLnOptions::setNextMix(), CACmdLnOptions::setNextMixCertificate(), CACmdLnOptions::setOwnCertificate(), CACmdLnOptions::setOwnOperatorCertificate(), CACmdLnOptions::setPrevMixCertificate(), CACmdLnOptions::setTrustedRootCertificates(), and CAXMLBI::setValues().
| CACertificate * CACertificate::decode | ( | const DOMNode * | node, |
| UINT32 | type, | ||
| const char * | passwd = NULL |
||
| ) | [static] |
References CERT_DER, CERT_PKCS12, CERT_X509CERTIFICATE, decode(), E_SUCCESS, equals(), and getDOMElementValue().
| static X509* CACertificate::decode | ( | const UINT8 ** | derX509, |
| UINT32 | derX509Len | ||
| ) | [static, private] |
| SINT32 CACertificate::encode | ( | UINT8 * | buff, |
| UINT32 * | bufflen, | ||
| UINT32 | type | ||
| ) | const |
References CERT_DER, CERT_XML_X509CERTIFICATE, E_SUCCESS, E_UNKNOWN, m_pCert, and X509_CERTIFICATE_TAGNAME_LEN.
Referenced by CACmdLnOptions::buildDefaultConfig(), CACertStore::encode(), encode(), and CAXMLBI::toXmlElement().
| SINT32 CACertificate::encode | ( | DOMElement *& | elemRoot, |
| XERCES_CPP_NAMESPACE::DOMDocument * | doc | ||
| ) | const |
References createDOMElement(), E_SUCCESS, encode(), m_pCert, and setDOMElementValue().
| SINT32 CACertificate::getAuthorityKeyIdentifier | ( | UINT8 * | r_aki, |
| UINT32 * | r_akiLen | ||
| ) | const |
References E_SUCCESS, E_UNKNOWN, m_pAKI, and removeColons().
Referenced by CACmdLnOptions::setOwnCertificate().
| SINT32 CACertificate::getRawSubjectKeyIdentifier | ( | UINT8 * | r_ski, |
| UINT32 * | r_skiLen | ||
| ) |
References E_SUCCESS, E_UNKNOWN, m_pSKI, CAMsg::printMsg(), and setSubjectKeyIdentifier().
Referenced by CACmdLnOptions::setOwnCertificate().
| SINT32 CACertificate::getSubjectKeyIdentifier | ( | UINT8 * | r_ski, |
| UINT32 * | r_skiLen | ||
| ) |
LERNGRUPPE Accessor method for the subjectKeyIdentifier (SKI) extension stored in this certificate.
| E_SUCCESS | upon successful retrieval |
| E_UNKNOWN | otherwise |
References E_SUCCESS, E_UNKNOWN, m_pSKI, CAMsg::printMsg(), removeColons(), and setSubjectKeyIdentifier().
Referenced by CACmdLnOptions::buildDefaultConfig(), CACmdLnOptions::getOperatorSubjectKeyIdentifier(), and CACmdLnOptions::setOwnCertificate().
| X509* CACertificate::getX509 | ( | ) | const [private] |
References m_pCert.
Referenced by CATLSClientSocket::doTLSConnect().
| static UINT8* CACertificate::getXmlElementName | ( | ) | [static] |
References m_spXmlElementName.
| bool CACertificate::isValid | ( | ) | const |
References m_pCert, and CAMsg::printMsg().
Referenced by verify().
| SINT32 CACertificate::removeColons | ( | const UINT8 * | a_cSkid, |
| UINT32 | a_cSkidLen, | ||
| UINT8 *& | r_ski, | ||
| UINT32 * | r_skiLen | ||
| ) | [static] |
LERNGRUPPE Removes the colons from the string representation of the given SKI.
| a_cSkid | The string from which the colons should be removed |
| a_cSkidLen | The length of a_cSkid |
| r_ski | |
| r_skiLen |
| E_SUCCESS | upon successful removal |
| E_UNKNOWN | otherwise |
References E_SUCCESS, E_UNKNOWN, and CAMsg::printMsg().
Referenced by getAuthorityKeyIdentifier(), CAMultiSignature::getSKI(), and getSubjectKeyIdentifier().
| SINT32 CACertificate::setSubjectKeyIdentifier | ( | UINT8 * | a_value, |
| UINT32 | a_valueLen | ||
| ) |
LERNGRUPPE Sets the subjectKeyIdentifier extension for this certificate to the given value.
| a_value | The value which should be set as SKI |
| a_valueLen | The length of a_value |
| E_SUCCESS | upon successful removal |
| E_UNKNOWN | otherwise |
LERNGRUPPE Sets the subjectKeyIdentifier extension for this certificate to the hash of the public key.
| E_SUCCESS | upon successful removal |
| E_UNKNOWN | otherwise |
Referenced by getRawSubjectKeyIdentifier(), and getSubjectKeyIdentifier().
| SINT32 CACertificate::verify | ( | const CACertificate * | a_cert | ) | const |
References E_SUCCESS, E_UNKNOWN, isValid(), m_pAKI, m_pCert, m_pSKI, and CAMsg::printMsg().
Referenced by CACmdLnOptions::setOwnCertificate(), and CACertStore::verifyMixCert().
friend class CAASymCipher [friend] |
friend class CASignature [friend] |
friend class CASSLContext [friend] |
friend class CATLSClientSocket [friend] |
AUTHORITY_KEYID* CACertificate::m_pAKI [private] |
Referenced by CACertificate(), getAuthorityKeyIdentifier(), verify(), and ~CACertificate().
X509* CACertificate::m_pCert [private] |
ASN1_OCTET_STRING* CACertificate::m_pSKI [private] |
UINT8 * CACertificate::m_spXmlElementName = 0 [static, private] |
Referenced by getXmlElementName().
1.7.6.1