The message formats for OCSP requests and responses are defined in [
RFC 6960]. [
RFC 6960] also defines the standard extensions for OCSP messages based on the extension model employed in X.509 version 3 certificates (see [
RFC 5280]). This document only specifies the new format for the Nonce extension and does not change the specifications of any of the other standard extensions defined in [
RFC 6960].
This section replaces the entirety of
Section 4.4.1 of
RFC 6960, which describes the OCSP Nonce extension.
The nonce cryptographically binds a request and a response to prevent replay attacks. The nonce is included as one of the requestExtensions in requests; in responses, it would be included as one of the responseExtensions. In both the request and the response, the nonce will be identified by the object identifier id-pkix-ocsp-nonce, while the extnValue is the value of the nonce. If the Nonce extension is present, then the length of the nonce
MUST be at least 1 octet and can be up to 32 octets.
A server
MUST reject any OCSP request that has a nonce in the Nonce extension with a length of either 0 octets or more than 32 octets with the malformedRequest OCSPResponseStatus, as described in
Section 4.2.1 of
RFC 6960.
The value of the nonce
MUST be generated using a cryptographically strong pseudorandom number generator (see [
RFC 4086]). The minimum nonce length of 1 octet is defined to provide backward compatibility with older clients that follow [
RFC 6960]. Newer OCSP clients that support this document
MUST use a length of 32 octets for the nonce in the Nonce extension. OCSP responders
MUST accept lengths of at least 16 octets and
MAY choose to ignore the Nonce extension for requests where the length of the nonce is less than 16 octets.
id-pkix-ocsp OBJECT IDENTIFIER ::= { id-ad-ocsp }
id-pkix-ocsp-nonce OBJECT IDENTIFIER ::= { id-pkix-ocsp 2 }
Nonce ::= OCTET STRING(SIZE(1..32))