Skip to content

Commit

Permalink
Script updating gh-pages from 4b65e13. [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
ID Bot committed Jun 27, 2024
1 parent 913ebdd commit be042ee
Show file tree
Hide file tree
Showing 2 changed files with 107 additions and 3 deletions.
57 changes: 55 additions & 2 deletions draft-kleidl-digest-fields-problem-types.html
Original file line number Diff line number Diff line change
Expand Up @@ -1134,6 +1134,9 @@ <h2 id="name-copyright-notice">
<ul class="compact toc ulBare ulEmpty">
<li class="compact toc ulBare ulEmpty" id="section-toc.1-1.3.2.1">
<p id="section-toc.1-1.3.2.1.1" class="keepWithNext"><a href="#section-3.1" class="auto internal xref">3.1</a>.  <a href="#name-unsupported-hashing-algorit" class="internal xref">Unsupported Hashing Algorithm</a></p>
</li>
<li class="compact toc ulBare ulEmpty" id="section-toc.1-1.3.2.2">
<p id="section-toc.1-1.3.2.2.1"><a href="#section-3.2" class="auto internal xref">3.2</a>.  <a href="#name-invalid-digest-value" class="internal xref">Invalid Digest Value</a></p>
</li>
</ul>
</li>
Expand Down Expand Up @@ -1213,12 +1216,35 @@ <h3 id="name-unsupported-hashing-algorit">

{
"type": "https://iana.org/assignments/http-problem-types#unsupported-hashing-algorithm",
"title": "upload is already completed",
"title": "hashing algorithm is not supported",
"unsupported-algorithm": "foo",
"supported-algorithms": ["sha-256", "sha-512"]
}
</pre><a href="#section-3.1-4" class="pilcrow"></a>
</div>
<p id="section-3.1-5">If the sender receives this problem type, it <span class="bcp14">SHOULD</span> retry the request while picking another hashing algorithm. If the response includes an array of supported algorithms, it <span class="bcp14">SHOULD</span> choose one of them.<a href="#section-3.1-5" class="pilcrow"></a></p>
</section>
</div>
<div id="invalid-digest-value">
<section id="section-3.2">
<h3 id="name-invalid-digest-value">
<a href="#section-3.2" class="section-number selfRef">3.2. </a><a href="#name-invalid-digest-value" class="section-name selfRef">Invalid Digest Value</a>
</h3>
<p id="section-3.2-1">This section defines the <code>https://iana.org/assignments/http-problem-types#invalid-digest-value</code> problem type <span>[<a href="#PROBLEM" class="cite xref">PROBLEM</a>]</span>. A resource <span class="bcp14">MAY</span> use this problem type in a response to a request, whose integrity fields include a digest value, that cannot be generated by the corresponding hashing algorithm. For example, if the digest value of the <code>sha-512</code> hashing algorithm is not 64 bytes long, it cannot be a valid digest value and the resource can skip computing the digest value.<a href="#section-3.2-1" class="pilcrow"></a></p>
<p id="section-3.2-2">The resource <span class="bcp14">SHOULD</span> a human-readable description why the value is considered invalid in the <code>title</code> member.<a href="#section-3.2-2" class="pilcrow"></a></p>
<p id="section-3.2-3">The following example shows a response for a request with an invalid digest value.<a href="#section-3.2-3" class="pilcrow"></a></p>
<div class="lang-http-message sourcecode" id="section-3.2-4">
<pre>
HTTP/1.1 400 Bad Request
Content-Type: application/problem+json

{
"type": "https://iana.org/assignments/http-problem-types#invalid-digest-value",
"title": "digest value for sha-512 is not 64 bytes long"
}
</pre><a href="#section-3.2-4" class="pilcrow"></a>
</div>
<p id="section-3.2-5">If the sender receives this problem type, it <span class="bcp14">SHOULD NOT</span> retry the request without modification. Such an error is likely rooted in a fault in the sender's computation or encoding of the digest value.<a href="#section-3.2-5" class="pilcrow"></a></p>
</section>
</div>
</section>
Expand Down Expand Up @@ -1259,6 +1285,29 @@ <h2 id="name-iana-considerations">
</dd>
<dd class="break"></dd>
</dl>
<p id="section-5-3">IANA is asked to register the following entry in the "HTTP Problem Types" registry:<a href="#section-5-3" class="pilcrow"></a></p>
<span class="break"></span><dl class="dlParallel" id="section-5-4">
<dt id="section-5-4.1">Type URI:</dt>
<dd style="margin-left: 1.5em" id="section-5-4.2">
<p id="section-5-4.2.1">https://iana.org/assignments/http-problem-types#invalid-digest-value<a href="#section-5-4.2.1" class="pilcrow"></a></p>
</dd>
<dd class="break"></dd>
<dt id="section-5-4.3">Title:</dt>
<dd style="margin-left: 1.5em" id="section-5-4.4">
<p id="section-5-4.4.1">Invalid Digest Value<a href="#section-5-4.4.1" class="pilcrow"></a></p>
</dd>
<dd class="break"></dd>
<dt id="section-5-4.5">Recommended HTTP status code:</dt>
<dd style="margin-left: 1.5em" id="section-5-4.6">
<p id="section-5-4.6.1">400<a href="#section-5-4.6.1" class="pilcrow"></a></p>
</dd>
<dd class="break"></dd>
<dt id="section-5-4.7">Reference:</dt>
<dd style="margin-left: 1.5em" id="section-5-4.8">
<p id="section-5-4.8.1">This document<a href="#section-5-4.8.1" class="pilcrow"></a></p>
</dd>
<dd class="break"></dd>
</dl>
</section>
</div>
<div id="sec-normative-references">
Expand All @@ -1284,9 +1333,13 @@ <h2 id="name-normative-references">
<span class="refAuthor">Leiba, B.</span>, <span class="refTitle">"Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words"</span>, <span class="seriesInfo">BCP 14</span>, <span class="seriesInfo">RFC 8174</span>, <span class="seriesInfo">DOI 10.17487/RFC8174</span>, <time datetime="2017-05" class="refDate">May 2017</time>, <span>&lt;<a href="https://www.rfc-editor.org/rfc/rfc8174">https://www.rfc-editor.org/rfc/rfc8174</a>&gt;</span>. </dd>
<dd class="break"></dd>
<dt id="RFC9530">[RFC9530]</dt>
<dd>
<dd>
<span class="refAuthor">Polli, R.</span> and <span class="refAuthor">L. Pardue</span>, <span class="refTitle">"Digest Fields"</span>, <span class="seriesInfo">RFC 9530</span>, <span class="seriesInfo">DOI 10.17487/RFC9530</span>, <time datetime="2024-02" class="refDate">February 2024</time>, <span>&lt;<a href="https://www.rfc-editor.org/rfc/rfc9530">https://www.rfc-editor.org/rfc/rfc9530</a>&gt;</span>. </dd>
<dd class="break"></dd>
<dt id="STRUCTURED-FIELDS">[STRUCTURED-FIELDS]</dt>
<dd>
<span class="refAuthor">Nottingham, M.</span> and <span class="refAuthor">P. Kamp</span>, <span class="refTitle">"Structured Field Values for HTTP"</span>, <span class="seriesInfo">RFC 8941</span>, <span class="seriesInfo">DOI 10.17487/RFC8941</span>, <time datetime="2021-02" class="refDate">February 2021</time>, <span>&lt;<a href="https://www.rfc-editor.org/rfc/rfc8941">https://www.rfc-editor.org/rfc/rfc8941</a>&gt;</span>. </dd>
<dd class="break"></dd>
</dl>
</section>
</div>
Expand Down
53 changes: 52 additions & 1 deletion draft-kleidl-digest-fields-problem-types.txt
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ Table of Contents
2. Conventions and Definitions
3. Problem Types
3.1. Unsupported Hashing Algorithm
3.2. Invalid Digest Value
4. Security Considerations
5. IANA Considerations
6. Normative References
Expand Down Expand Up @@ -156,11 +157,44 @@ Table of Contents

{
"type": "https://iana.org/assignments/http-problem-types#unsupported-hashing-algorithm",
"title": "upload is already completed",
"title": "hashing algorithm is not supported",
"unsupported-algorithm": "foo",
"supported-algorithms": ["sha-256", "sha-512"]
}

If the sender receives this problem type, it SHOULD retry the request
while picking another hashing algorithm. If the response includes an
array of supported algorithms, it SHOULD choose one of them.

3.2. Invalid Digest Value

This section defines the https://iana.org/assignments/http-problem-
types#invalid-digest-value problem type [PROBLEM]. A resource MAY
use this problem type in a response to a request, whose integrity
fields include a digest value, that cannot be generated by the
corresponding hashing algorithm. For example, if the digest value of
the sha-512 hashing algorithm is not 64 bytes long, it cannot be a
valid digest value and the resource can skip computing the digest
value.

The resource SHOULD a human-readable description why the value is
considered invalid in the title member.

The following example shows a response for a request with an invalid
digest value.

HTTP/1.1 400 Bad Request
Content-Type: application/problem+json

{
"type": "https://iana.org/assignments/http-problem-types#invalid-digest-value",
"title": "digest value for sha-512 is not 64 bytes long"
}

If the sender receives this problem type, it SHOULD NOT retry the
request without modification. Such an error is likely rooted in a
fault in the sender's computation or encoding of the digest value.

4. Security Considerations

Although an error appeared while handling the digest fields, the
Expand All @@ -184,6 +218,18 @@ Table of Contents

Reference: This document

IANA is asked to register the following entry in the "HTTP Problem
Types" registry:

Type URI: https://iana.org/assignments/http-problem-types#invalid-
digest-value

Title: Invalid Digest Value

Recommended HTTP status code: 400

Reference: This document

6. Normative References

[DIGEST] Polli, R. and L. Pardue, "Digest Fields", RFC 9530,
Expand All @@ -207,6 +253,11 @@ Table of Contents
DOI 10.17487/RFC9530, February 2024,
<https://www.rfc-editor.org/rfc/rfc9530>.

[STRUCTURED-FIELDS]
Nottingham, M. and P. Kamp, "Structured Field Values for
HTTP", RFC 8941, DOI 10.17487/RFC8941, February 2021,
<https://www.rfc-editor.org/rfc/rfc8941>.

Acknowledgments

TODO acknowledge.
Expand Down

0 comments on commit be042ee

Please sign in to comment.