Hi all,
I'm writing a program to parse x.509 certificates with libtomcrypt.
In order to parse the der-encoded certificates, my program calls the der_decode_sequence_flexi() function.
But, this function cause an assertion like the following.
Assertion failed: addr_range.min () != 0 && addr_range.max () != 0
When I check on the call stack with the bt command of gdb, this error occurs during parsing an integer value at line 125
in the der_decode_sequence_flexi.c and the actual code is
if ((err == mp_init(&l->data)) != CRYPT_OK)
The sample der-encoded file, test.der, works very well, but other certificates doesn't.
Do some initialization functions have to be called to use the mp_init()?
Regards,
Sungjin.