ASN1_ITEM_st表述一个“项”,这个“项”是一种复合结构,templates是一个ASN1_ITEM_st容器,该容器可以容纳一个ASN1_ITEM_st也可以容纳多个ASN1_ITEM_st,多个ASN1_ITEM_st同样以templates为更低一级的容器,实质上在我们的例子中,x509_cinf结构体就是一个ASN1_ITEM_st,其中包含一系列的ASN1_TEMPLATE,这个一会...
ASN1_ITEM_st表述一个“项”,这个“项”是一种复合结构,templates是一个ASN1_ITEM_st容器,该容器可以容纳一个ASN1_ITEM_st也可以容纳多个ASN1_ITEM_st,多个ASN1_ITEM_st同样以templates为更低一级的容器,实质上在我们的例子中,x509_cinf结构体就是一个ASN1_ITEM_st,其中包含一系列的ASN1_TEMPLATE,这个一会...
if (ASN1_item_ex_d2i(pval, in, len, it, -1, 0, 0, &c) > 0) return *pval; return NULL; } 见下图: 所以说,openssl中的d2i的过程实际上是很简单的,无非就是将具体数据的传输语法在抽象语法的指导下转换为实际语法,上面的例子中只是说明了如何转换为openssl的c语言的内部结构体的过程,但是并不...
inti2d_RSAPublicKey_bio(BIO *bp, RSA *rsa){returnASN1_item_i2d_bio(ASN1_ITEM_rptr(RSAPublicKey), bp, rsa); } 开发者ID:1234-,项目名称:openssl,代码行数:4,代码来源:x_all.c 示例7: i2d_X509_REQ_bio ▲点赞 1▼ inti2d_X509_REQ_bio(BIO *bp, X509_REQ *req){returnASN1_i...
V_ASN1_OCTET_STRING,digest);/* Now sign the attributes */EVP_SignInit_ex(&ctx_tmp,md_tmp,NULL); alen = ASN1_item_i2d((ASN1_VALUE *)sk,&abuf,ASN1_ITEM_rptr(PKCS7_ATTR_SIGN));if(!abuf)gotoerr; EVP_SignUpdate(&ctx_tmp,abuf,alen); ...
#define ASN1_F_ASN1_I2D_FP 117 #define ASN1_F_ASN1_INTEGER_SET 118 #define ASN1_F_ASN1_INTEGER_TO_BN 119 #define ASN1_F_ASN1_ITEM_D2I_FP 206 #define ASN1_F_ASN1_ITEM_DUP 191 #define ASN1_F_ASN1_ITEM_EX_COMBINE_NEW 121 #define ASN1_F_ASN1_ITEM_EX_D2I 120 #define...
103 {ERR_FUNC(ASN1_F_ASN1_ITEM_DUP), "ASN1_item_dup"}, 104 {ERR_FUNC(ASN1_F_ASN1_ITEM_EX_COMBINE_NEW), "ASN1_ITEM_EX_COMBINE_NEW"}, 105 {ERR_FUNC(ASN1_F_ASN1_ITEM_EX_D2I), "ASN1_ITEM_EX_D2I"}, 106 {ERR_FUNC(ASN1_F_ASN1_ITEM_I2D_BIO), "ASN1_item_i2d_bio...
a_i2d_fp.c a_int.c a_mbstr.c a_object.c a_octet.c a_print.c a_sign.c a_strex.c a_strnid.c a_time.c a_type.c a_utctm.c a_utf8.c a_verify.c ameth_lib.c asn1_err.c asn1_gen.c asn1_item_list.c asn1_item_list.h asn1_lib.c asn1_local.h asn1_pa...
ASN1_INTEGER*ASN1_INTEGER_new(void);voidASN1_INTEGER_free(ASN1_INTEGER*a);type*d2i_ASN1_INTEGER(ASN1_INTEGER**a,constunsignedchar**in,longlen);inti2d_ASN1_INTEGER(ASN1_INTEGER*a,unsignedchar**out);constASN1_ITEM ASN1_INTEGER_it; ...
*/ if (!ASN1_item_pack(oaep, ASN1_ITEM_rptr(RSA_OAEP_PARAMS), &os)) goto err; X509_ALGOR_set0(alg, OBJ_nid2obj(NID_rsaesOaep), V_ASN1_SEQUENCE, os); os = NULL; rv = 1; err: RSA_OAEP_PARAMS_free(oaep); ASN1_STRING_free(os); return rv; } Example #8 0 Show...