ASN1 structures with bitstring starting with the "17 1E" and a length of 256 bit cannot be parsed correctly. The bitstring is interpreted as a date field.
Example of a CSR containing such a bitstring. Of course the CSR is not a valid on and the signature is not valid as well. However, the bitstring should be parseable correctly.
In the method parseTime() in asn1.js it is correctly recognised that this is not a valid date.
Would it be possible to ignore the date in case of a bitstring content type guess?
ASN1 structures with bitstring starting with the "17 1E" and a length of 256 bit cannot be parsed correctly. The bitstring is interpreted as a date field.
Example of a CSR containing such a bitstring. Of course the CSR is not a valid on and the signature is not valid as well. However, the bitstring should be parseable correctly.
-----BEGIN CERTIFICATE REQUEST----- MIHBMHUCAQAwDzENMAsGA1UEAwwEdGVzdDAqMAUGAytlcAMhABceg8GyUYA/ht0B 6c+ohr6JpzFtg3JkmsIjHsZp+BqEoDMwMQYJKoZIhvcNAQkOMSQwIjALBgNVHQ8E BAMCBDAwEwYDVR0lBAwwCgYIKwYBBQUHAwEwBQYDK2VwA0EAm2DTuzGJx+ZLfZ5F S6UoPKuV9CDVW2NQBGRWr7E9JfkVlJi4AXp7fOjWggmUO+ddJvbPEesZaRllXZr4 xataBQ== -----END CERTIFICATE REQUEST-----
openssl is able to parse the CSR correctly: