Fix REQ format bug

Attributes not OPTIONAL
This commit is contained in:
Zhi Guan
2023-02-06 17:07:08 +08:00
parent 97e33d4b9a
commit 8a62b91da9
5 changed files with 13 additions and 42 deletions

View File

@@ -1762,6 +1762,9 @@ int x509_attributes_print(FILE *fp, int fmt, int ind, const char *label, const u
format_print(fp, fmt, ind, "%s\n", label);
ind += 4;
}
if (!dlen) {
format_print(fp, fmt, ind, "(null)\n");
}
while (dlen) {
if (asn1_sequence_from_der(&p, &len, &d, &dlen) != 1) {
error_print();