Skip to content

Commit 75423b0

Browse files
jann0kmir-jalal
authored andcommitted
RM-4032: update documentation
1 parent facc137 commit 75423b0

File tree

1 file changed

+26
-5
lines changed

1 file changed

+26
-5
lines changed

cdoc2-key-shares-openapi.yaml

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,26 @@ info:
44
url: http://ria.ee
55
title: cdoc2-key-shares
66
version: 1.0.1-draft
7-
description: API for exchanging CDOC2 key material shares
7+
description: |
8+
API for exchanging CDOC2 key material shares.
9+
10+
`KeyShare` objects defined here are created by splitting cryptographic material required for
11+
encrypting/decrypting CDOC2 document. `KeyShare` objects required for combining original cryptographic material
12+
are stored in CDOC2 header `KeySharesCapsule` [FBS](https://github.com/open-eid/cdoc2-java-ref-impl/blob/master/cdoc2-schema/src/main/fbs/recipients.fbs) object.
13+
14+
To access `KeyShare` objects, recipient must authenticate himself by including `x-cdoc2-auth-ticket`
15+
and `x-cdoc2-auth-x5c` headers for `getKeyShareByShareId` operation.
16+
17+
* `x-cdoc2-auth-ticket` is sd-jwt defined in WIP https://open-eid.github.io/CDOC2/2.0/ .
18+
Java implementation for `x-cdoc2-auth-ticket` can be found WIP https://github.com/open-eid/cdoc2-auth
19+
`x-cdoc2-auth-ticket` is signed by Smart-ID [authentication](https://github.com/SK-EID/smart-id-documentation?tab=readme-ov-file#2310-authentication-session)
20+
certificate or [Mobile-ID authentication](https://github.com/SK-EID/MID?tab=readme-ov-file#32-initiating-signing-and-authentication) certificate.
21+
* `x-cdoc2-auth-x5c` is PEM encoded X509 certificate (without newlines) that was used to sign x-cdoc2-auth-ticket.
22+
Certificate holders identify is specified in Subject "serialnumber" field. Example certificate subject:
23+
'serialNumber = PNOEE-30303039914, GN = OK, SN = TESTNUMBER, CN = "TESTNUMBER,OK", C = EE'
24+
Certificate full structure is defined in
25+
[Certificate and OCSP Profile for Smart-ID](https://www.skidsolutions.eu/wp-content/uploads/2024/10/SK-CPR-SMART-ID-EN-v4_7-20241127.pdf)
26+
827
servers:
928
- url: 'https://localhost:8443'
1029
description: Regular TLS (no mutual TLS required).
@@ -38,9 +57,8 @@ paths:
3857
type: string
3958
required: true
4059
description: |
41-
PEM encoded X509 certificate (without newlines) that was used to sign X-Cdoc2-Auth-Ticket.
42-
Certificate holders identify is specified in Subject "serialnumber" field. This must match to
43-
"kid" in "x-cdoc2-auth-ticket" header. Example certificate subject:
60+
PEM encoded X509 certificate (without newlines) that was used to sign x-cdoc2-auth-ticket.
61+
Certificate holders identify is specified in Subject "serialnumber" field. Example certificate subject:
4462
'serialNumber = PNOEE-30303039914, GN = OK, SN = TESTNUMBER, CN = "TESTNUMBER,OK", C = EE'
4563
Certificate full structure is defined in
4664
[Certificate and OCSP Profile for Smart-ID](https://www.skidsolutions.eu/wp-content/uploads/2024/10/SK-CPR-SMART-ID-EN-v4_7-20241127.pdf)
@@ -132,13 +150,16 @@ components:
132150
format: byte
133151
minLength: 32
134152
maxLength: 128
135-
description: Key Share. Binary format is yet to be defined [#RM-55912](https://rm-int.cyber.ee/ito/issues/55912)
153+
description: |
154+
Base64 encoded Key Share. Binary format.
155+
136156
recipient:
137157
type: string
138158
minLength: 12
139159
maxLength: 32
140160
description: |
141161
Recipient who can download this share. ETSI319412-1. Example "etsi/PNOEE-48010010101".
162+
Must match certificate subject serialnumber field (without "etsi/" prefix).
142163
In future might support other formats
143164
[etsi/:semantics-identifier](https://github.com/SK-EID/smart-id-documentation/blob/v2/README.md#2322-etsisemantics-identifier)
144165
required:

0 commit comments

Comments
 (0)