Skip to content

Commit c2f708d

Browse files
committed
Remove supported-algorithms in favour of integrity preference fields
Closes tus/draft-digest-fields-problem-types#2.
1 parent fb282e1 commit c2f708d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

draft-kleidl-digest-fields-problem-types.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,19 +79,19 @@ The terms "integrity fields" and "integrity preference fields" are from {{DIGEST
7979

8080
This section defines the "https://iana.org/assignments/http-problem-types#unsupported-hashing-algorithm" problem type {{PROBLEM}}. A server MAY use this problem type when responding to a request, whose integrity or integrity preference fields reference a hashing algorithm that the server can not or does not want to support for this request, and if the server wants to indicate this problem to the sender.
8181

82-
Two problem type extension members are defined: the `unsupported-algorithm` and `supported-algorithms` members. A response using this problem type SHOULD populate both members, with the value of `unsupported-algorithm` being the algorithm key of the unsupported algorithm from the request and the value of `supported-algorithms` being an array of the algorithm keys, as registered in the "Hash Algorithms for HTTP Digest Fields" registry, of the supported algorithms.
82+
For this problem type, the `unsupported-algorithm` is defined as the only extension member. It SHOULD be populated in a response using this problem type, with its value being the algorithm key of the unsupported algorithm from the request. The response SHOULD include the corresponding integrity preference field to indicate the server's algorithm support and preference.
8383

8484
The following example shows a response for a request with an integrity field utilizing an unsupported hashing algorithm `foo`. The response also includes a list of supported algorithms.
8585

8686
~~~ http-message
8787
HTTP/1.1 400 Bad Request
8888
Content-Type: application/problem+json
89+
Want-Content-Digest: sha-512=3, sha-256=10
8990

9091
{
9192
"type": "https://iana.org/assignments/http-problem-types#unsupported-hashing-algorithm",
9293
"title": "hashing algorithm is not supported",
93-
"unsupported-algorithm": "foo",
94-
"supported-algorithms": ["sha-256", "sha-512"]
94+
"unsupported-algorithm": "foo"
9595
}
9696
~~~
9797

0 commit comments

Comments
 (0)