In Files

  • openssl/ossl_pkcs7.c

Parent

Class/Module Index [+]

Quicksearch

OpenSSL::PKCS7::RecipientInfo

Public Class Methods

new(p1) click to toggle source
 
               static VALUE
ossl_pkcs7ri_initialize(VALUE self, VALUE cert)
{
    PKCS7_RECIP_INFO *p7ri;
    X509 *x509;

    x509 = GetX509CertPtr(cert); /* NO NEED TO DUP */
    GetPKCS7ri(self, p7ri);
    if (!PKCS7_RECIP_INFO_set(p7ri, x509)) {
        ossl_raise(ePKCS7Error, NULL);
    }

    return self;
}
            

Public Instance Methods

enc_key() click to toggle source
 
               static VALUE
ossl_pkcs7ri_get_enc_key(VALUE self)
{
    PKCS7_RECIP_INFO *p7ri;

    GetPKCS7ri(self, p7ri);

    return asn1str_to_str(p7ri->enc_key);
}
            
issuer() click to toggle source
 
               static VALUE
ossl_pkcs7ri_get_issuer(VALUE self)
{
    PKCS7_RECIP_INFO *p7ri;

    GetPKCS7ri(self, p7ri);

    return ossl_x509name_new(p7ri->issuer_and_serial->issuer);
}
            
serial() click to toggle source
 
               static VALUE
ossl_pkcs7ri_get_serial(VALUE self)
{
    PKCS7_RECIP_INFO *p7ri;

    GetPKCS7ri(self, p7ri);

    return asn1integer_to_num(p7ri->issuer_and_serial->serial);
}
            
There is an updated format of the API docs for this version here.