for certificates with really large serial numbers CERT_asHash returned -1 as serial number. After reading the Net::SSLeay documentation I changed the decoding function to P_ASN1_INTEGER_get_dec:
BEWARE: If the value stored in ASN1_INTEGER is greater than max. integer that can be stored in 'long' type (usually 32bit but may vary according to platform) then this function will return -1. For getting large ASN1_INTEGER values consider using "P_ASN1_INTEGER_get_dec" or "P_ASN1_INTEGER_get_hex".
Hi,
for certificates with really large serial numbers CERT_asHash returned -1 as serial number. After reading the Net::SSLeay documentation I changed the decoding function to P_ASN1_INTEGER_get_dec:
BEWARE: If the value stored in ASN1_INTEGER is greater than max. integer that can be stored in 'long' type (usually 32bit but may vary according to platform) then this function will return -1. For getting large ASN1_INTEGER values consider using "P_ASN1_INTEGER_get_dec" or "P_ASN1_INTEGER_get_hex".
Cheers,
Christopher