mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-07-06 11:30:49 +02:00
Guard OCSP signature params with WC_RSA_PSS ifdef
OCSPBASICRESPASN_IDX_SIGNATURE_PARAMS is only defined when WC_RSA_PSS is enabled but was used unconditionally in EncodeBasicOcspResponse, causing a build error when WC_RSA_PSS is not defined.
This commit is contained in:
@@ -32932,6 +32932,7 @@ WC_MAYBE_UNUSED static int EncodeBasicOcspResponse(OcspResponse* resp,
|
||||
if (ret == 0) {
|
||||
SetASN_OID(&dataASN[OCSPBASICRESPASN_IDX_SIGALGO_OID], resp->sigOID,
|
||||
oidSigType);
|
||||
#ifdef WC_RSA_PSS
|
||||
if (resp->sigParams != NULL && resp->sigParamsSz != 0) {
|
||||
SetASN_Buffer(&dataASN[OCSPBASICRESPASN_IDX_SIGNATURE_PARAMS],
|
||||
resp->sigParams, resp->sigParamsSz);
|
||||
@@ -32941,6 +32942,7 @@ WC_MAYBE_UNUSED static int EncodeBasicOcspResponse(OcspResponse* resp,
|
||||
OCSPBASICRESPASN_IDX_SIGNATURE_PARAMS,
|
||||
ocspBasicRespASN_Length);
|
||||
}
|
||||
#endif
|
||||
if (resp->cert != NULL && resp->certSz > 0) {
|
||||
SetASN_Buffer(&dataASN[OCSPBASICRESPASN_IDX_CERTS_SEQ],
|
||||
resp->cert, resp->certSz);
|
||||
|
||||
Reference in New Issue
Block a user