Migrating from 1.0.2 to 1.1.1

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Migrating from 1.0.2 to 1.1.1

Dmitry Belyavsky-3
Hello,

I try to migrate the following code from 1.0.2 to 1.1.1:

=========
 ASN1_OBJECT *seed_id = OBJ_txt2obj(my_oid,1);
 int seed_pos = EVP_PKEY_get_attr_by_OBJ(pk, seed_id, -1);

  if (seed_pos >= 0)
  {
    X509_ATTRIBUTE *attr = EVP_PKEY_get_attr(pk, seed_pos);
    CE_CHECK(X509at_add1_attr(&(p8->attributes), attr) != NULL, 0, CRYPTOCOM_R_NO_MEMORY);
  }
==========
The code is intended to add a custom attribute to PKCS8 attributes.
How do I do it in 1.1.1?

Thank you!

--
SY, Dmitry Belyavsky