Skip to content

Commit 3aff4c3

Browse files
authored
Merge pull request #4 from ietf-wg-httpapi/no-calculated-digest
Do not include calculated digest in problem
2 parents 5113d08 + 9c68fa9 commit 3aff4c3

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

draft-ietf-httpapi-digest-fields-problem-types.md

+2-3
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ This problem type indicates a fault in the sender's calculation or encoding of t
184184

185185
This section defines the "https://iana.org/assignments/http-problem-types#digest-mismatching-value" problem type. A server MAY use this problem type when responding to a request, whose integrity fields include a digest value that does not match the digest value that the server calculated for the request content or representation.
186186

187-
Three problem type extension members are defined: the `algorithm`, `provided-digest`, and `calculated-digest` members. A response using this problem type SHOULD populate all members, with the value of `algorithm` being the algorithm key of the used hashing algorithm, with the value of `provided-digest` being the digest value taken from the request's integrity fields, and the value of `calculated-digest` being the calculated digest. The digest values MUST BE serialized as byte sequences as described in {{Section 4.1.8 of STRUCTURED-FIELDS}}.
187+
Two problem type extension members are defined: the `algorithm` and `provided-digest` members. A response using this problem type SHOULD populate all members, with the value of `algorithm` being the algorithm key of the used hashing algorithm and the value of `provided-digest` being the digest value taken from the request's integrity fields. The digest value MUST be serialized as byte sequences as described in {{Section 4.1.8 of STRUCTURED-FIELDS}}.
188188

189189
The following example shows a request with the content `{"hello": "woXYZ"}` (plus LF), but the representation digest for `{"hello": "world"}` (plus LF). The subsequent response indicates the mismatching SHA-256 digest values.
190190

@@ -206,8 +206,7 @@ Content-Type: application/problem+json
206206
"type": "https://iana.org/assignments/http-problem-types#digest-mismatching-value",
207207
"title": "digest value from request does not match expected value",
208208
"algorithm": "sha-256",
209-
"provided-digest": ":RK/0qy18MlBSVnWgjwz6lZEWjP/lF5HF9bvEF8FabDg=:",
210-
"calculated-digest": ":8vXo+0QVwf2woEblm4hTAftp0/K5fWSMZG4CKtplwjc=:"
209+
"provided-digest": ":RK/0qy18MlBSVnWgjwz6lZEWjP/lF5HF9bvEF8FabDg=:"
211210
}
212211
~~~
213212
{: title="Response indicating the mismatching digests"}

0 commit comments

Comments
 (0)