Skip to content

Add updates after PR 1000 #10

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
81 changes: 2 additions & 79 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ <h2>Producing</h2>
<li>
<p>
<a data-cite="RFC9052#section-3.1">content type (ctyp)</a> MUST be present in <a data-cite="RFC9052#name-common-cose-header-paramete">COSE Headers</a>,
and MUST be <code>application/credential+json</code>.
and MUST be <code>application/credential+ld+json</code>.
</p>
</li>

Expand Down Expand Up @@ -237,7 +237,7 @@ <h2>Example</h2>
class="example"
title="A credential for a University Degree"
>
<p>An <code>application/credential+json</code> example that will have an external proof.</p>
<p>An <code>application/credential+ld+json</code> example that will have an external proof.</p>
<pre data-include="./credential.json" data-include-format="json"></pre>
</aside>

Expand All @@ -249,83 +249,6 @@ <h2>Example</h2>
<pre data-include="./verifiable-credential.cose.json" data-include-format="json"></pre>
</aside>
</section>

<section id="iana">

<h2>IANA Considerations</h2>
<section id="media-type">


<h2>The <code>application/credential+json</code> Media Type</h2>
<p>
This specification registers the <code>application/credential+json</code> MIME Media Type specifically for identifying documents
conforming to the Verifiable Credentials format.
</p>
<table>
<tr>
<td>Type name: </td>
<td>application</td>
</tr>
<tr>
<td>Subtype name: </td>
<td>credential+json</td>
</tr>
<tr>
<td>Required parameters: </td>
<td>None</td>
</tr>
<tr>
<td>Optional parameters: </td>
<td>
profile: The profile parameter for the application/credential+json
media type allows one or more profile URIs to be specified. These
profile URIs have the identifier semantics defined in [[!RFC6906]].
The "profile" media type parameter MUST be quoted. It contains a
non-empty list of space-separated URIs (the profile URIs).
<pre>profile-param = "profile=" profile-value
profile-value = <"> profile-URI 0*( 1*SP profile-URI ) <">
profile-URI = URI</"></"></pre>
The "URI" in the above grammar refers to the "URI" as defined in
Section 3 of [[!RFC3986]].
</td>
</tr>
<tr>
<td>Encoding considerations: </td>
<td>
Resources that use the "<code>application/credential+json</code>"
Media Type are required to conform to all of the requirements
for the "<code>application/json</code>" Media Type and are
therefore subject to the same encoding considerations specified
in Section 11 of [[!RFC7159]].
</td>
</tr>
<tr>
<td>Security considerations: </td>
<td>As defined in this specification.</td>
</tr>
<tr>
<td>Contact: </td>
<td>
Orie Steele &lt;<a href="mailto:[email protected]">[email protected]</a>&gt;
</td>
</tr>
</table>

<p>
Note that while the Verifiable Credentials format uses JSON-LD
conventions, there are a number of constraints and additional
requirements for Verifiable Credential implementations that justify
the use of a specific media type.
</p>

<p>
Because Verifiable Credentials can be considered a restricted profile
of JSON-LD, Implementations SHOULD consider the
`application/ld+json; profile="https://www.w3.org/ns/credentials"`
media type as being equivalent to `application/credential+json`.
</p>
</section>
</section>

<section id="conformance">
<p>
Expand Down
2 changes: 1 addition & 1 deletion test-vectors/generate.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const privateKeyJwk = {

(async ()=>{

const protectedHeader = { kid: credential.issuer + '#key-0', alg: 'ES256', ctyp: 'application/credential+json' }
const protectedHeader = { kid: credential.issuer + '#key-0', alg: 'ES256', ctyp: 'application/credential+ld+json' }
const headers = {
p: protectedHeader,
};
Expand Down
Binary file modified verifiable-credential.cose
Binary file not shown.
4 changes: 2 additions & 2 deletions verifiable-credential.cose.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"protected": {
"kid": "https://example.edu/issuers/14#key-0",
"alg": "ES256",
"ctyp": "application/credential+json"
"ctyp": "application/credential+ld+json"
},
"alg": "ES256"
},
Expand All @@ -26,6 +26,6 @@
},
"output": {
"cbor_diag": null,
"cbor": "d2845848a304582468747470733a2f2f6578616d706c652e6564752f697373756572732f3134236b65792d30012603781b6170706c69636174696f6e2f63726564656e7469616c2b6a736f6ea0d8405901977b2240636f6e74657874223a5b2268747470733a2f2f7777772e77332e6f72672f323031382f63726564656e7469616c732f7631222c2268747470733a2f2f7777772e77332e6f72672f323031382f63726564656e7469616c732f6578616d706c65732f7631225d2c226964223a22687474703a2f2f6578616d706c652e6564752f63726564656e7469616c732f33373332222c2274797065223a5b2256657269666961626c6543726564656e7469616c222c22556e697665727369747944656772656543726564656e7469616c225d2c22697373756572223a2268747470733a2f2f6578616d706c652e6564752f697373756572732f3134222c2269737375616e636544617465223a22323031302d30312d30315431393a32333a32345a222c2263726564656e7469616c5375626a656374223a7b226964223a226469643a6578616d706c653a313233222c22646567726565223a7b2274797065223a2242616368656c6f72446567726565222c226e616d65223a2242616368656c6f72206f6620536369656e636520616e642041727473227d7d7d584069871f491223451e903c1cba1c47db57690856f2c1a1ba2639025fca0664af6530874fa0dab4b81970b63682d94d540bf770e4784698013b59312f51d06461c4"
"cbor": "d284584ba304582468747470733a2f2f6578616d706c652e6564752f697373756572732f3134236b65792d30012603781e6170706c69636174696f6e2f63726564656e7469616c2b6c642b6a736f6ea0d8405901977b2240636f6e74657874223a5b2268747470733a2f2f7777772e77332e6f72672f323031382f63726564656e7469616c732f7631222c2268747470733a2f2f7777772e77332e6f72672f323031382f63726564656e7469616c732f6578616d706c65732f7631225d2c226964223a22687474703a2f2f6578616d706c652e6564752f63726564656e7469616c732f33373332222c2274797065223a5b2256657269666961626c6543726564656e7469616c222c22556e697665727369747944656772656543726564656e7469616c225d2c22697373756572223a2268747470733a2f2f6578616d706c652e6564752f697373756572732f3134222c2269737375616e636544617465223a22323031302d30312d30315431393a32333a32345a222c2263726564656e7469616c5375626a656374223a7b226964223a226469643a6578616d706c653a313233222c22646567726565223a7b2274797065223a2242616368656c6f72446567726565222c226e616d65223a2242616368656c6f72206f6620536369656e636520616e642041727473227d7d7d5840502d0343f3ace13e2cf2d0d1daedca7ab14af468826df544b2ec8689d28f810a37d4b28fb6207b5ead59772f456700f703ee800462d73c51f62c6e7da16a4460"
}
}