Added get_attributes() method to pkcs7_t.
This commit is contained in:
@@ -681,6 +681,12 @@ METHOD(pkcs7_t, set_attributes, void,
|
|||||||
this->attributes = attributes;
|
this->attributes = attributes;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
METHOD(pkcs7_t, get_attributes, pkcs9_t*,
|
||||||
|
private_pkcs7_t *this)
|
||||||
|
{
|
||||||
|
return this->attributes;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* build a DER-encoded issuerAndSerialNumber object
|
* build a DER-encoded issuerAndSerialNumber object
|
||||||
*/
|
*/
|
||||||
@@ -990,6 +996,7 @@ static private_pkcs7_t *pkcs7_create_empty(void)
|
|||||||
.create_certificate_enumerator = _create_certificate_enumerator,
|
.create_certificate_enumerator = _create_certificate_enumerator,
|
||||||
.set_certificate = _set_certificate,
|
.set_certificate = _set_certificate,
|
||||||
.set_attributes = _set_attributes,
|
.set_attributes = _set_attributes,
|
||||||
|
.get_attributes = _get_attributes,
|
||||||
.build_envelopedData = _build_envelopedData,
|
.build_envelopedData = _build_envelopedData,
|
||||||
.build_signedData = _build_signedData,
|
.build_signedData = _build_signedData,
|
||||||
.destroy = _destroy,
|
.destroy = _destroy,
|
||||||
|
|||||||
@@ -112,10 +112,17 @@ struct pkcs7_t {
|
|||||||
/**
|
/**
|
||||||
* Add authenticated attributes.
|
* Add authenticated attributes.
|
||||||
*
|
*
|
||||||
* @param attributes attributes to be included
|
* @param attributes attributes to be included (gets adopted)
|
||||||
*/
|
*/
|
||||||
void (*set_attributes) (pkcs7_t *this, pkcs9_t *attributes);
|
void (*set_attributes) (pkcs7_t *this, pkcs9_t *attributes);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get attributes.
|
||||||
|
*
|
||||||
|
* @reutrn attributes (internal data)
|
||||||
|
*/
|
||||||
|
pkcs9_t *(*get_attributes) (pkcs7_t *this);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Build a data object
|
* Build a data object
|
||||||
*
|
*
|
||||||
|
|||||||
Reference in New Issue
Block a user