The results of certtool and api are different

Description of problem:

The results of parsing the certificate using gnutls_x509_crt_import are different from those of parsing the certificate using certtool -i --inraw --infile fd.der

Version of gnutls used:

gnutls-cli 3.7.3

Distributor of gnutls (e.g., Ubuntu, Fedora, RHEL)

Ubuntu

How reproducible:

Steps to Reproduce:

  • one Parse the certificate using gnutls_x509_crt_import
  • two Parse the certificate using certtool -i --inraw --infile Cert1731937920100M2.der Cert1731937920100M2.der

Actual results:

gnutls_x509_crt_import success,return GNUTLS_E_SUCCESS (0) certtool -i --inraw --infile fd.der throws error:gnutls_x509_ext_import_authority_key_id: ASN1 parser:Error in DER parsing

Expected results:

gnutls_x509_crt_import Returns an error value