Skip to content

Commit

Permalink
Merge pull request #7710 from anhu/preTBS_altsigalg_fix
Browse files Browse the repository at this point in the history
Stop stripping out the sequence header on the AltSigAlg extension.
  • Loading branch information
SparkiDev authored Jul 15, 2024
2 parents 0d8763b + f5e27bf commit 1378313
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions wolfcrypt/src/asn.c
Original file line number Diff line number Diff line change
Expand Up @@ -20984,6 +20984,7 @@ static int DecodeAltSigAlg(const byte* input, int sz, DecodedCert* cert)
(void)cert;
}

/* We do this to make sure the format of the extension is correct. */
if (ret == 0) {
GetASN_OID(&dataASN[ALTSIG_ALGOID_OID], oidSigType);

Expand All @@ -20993,8 +20994,8 @@ static int DecodeAltSigAlg(const byte* input, int sz, DecodedCert* cert)
}

if (ret == 0) {
cert->altSigAlgDer = dataASN[ALTSIG_ALGOID_SEQ].data.u8;
cert->altSigAlgLen = dataASN[ALTSIG_ALGOID_SEQ].length;
cert->altSigAlgDer = (byte *)input;
cert->altSigAlgLen = sz;
cert->altSigAlgOID = dataASN[ALTSIG_ALGOID_OID].data.oid.sum;
}

Expand Down

0 comments on commit 1378313

Please sign in to comment.