-
Notifications
You must be signed in to change notification settings - Fork 0
/
PublicKeyCredentialCreationOptions.cljs
252 lines (179 loc) · 9.08 KB
/
PublicKeyCredentialCreationOptions.cljs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
(ns web.auth.PublicKeyCredentialCreationOptions
"The PublicKeyCredentialCreationOptions dictionary of the Web
API holds options passed to `navigators.credentials.create()`
order to create a `web.auth.PublicKeyCredential`."
(:refer-clojure :exclude []))
(defn rp
"Property.
The rp property of the `web.auth.PublicKeyCredentialCreationOptions`
is an object describing the relying party which requested the
creation (via `navigator.credentials.create()`).
`relyingPartyObj = publicKeyCredentialCreationOptions.rp`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/rp`"
[this]
(-> this (.-rp)))
(defn set-rp!
"Property.
The rp property of the `web.auth.PublicKeyCredentialCreationOptions`
is an object describing the relying party which requested the
creation (via `navigator.credentials.create()`).
`relyingPartyObj = publicKeyCredentialCreationOptions.rp`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/rp`"
[this val]
(aset this "rp" val))
(defn user
"Property.
The user property of the `web.auth.PublicKeyCredentialCreationOptions`
is an object describing the user account for which the credentials
generated (via `navigator.credentials.create()`).
`userAccount = publicKeyCredentialCreationOptions.user`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/user`"
[this]
(-> this (.-user)))
(defn set-user!
"Property.
The user property of the `web.auth.PublicKeyCredentialCreationOptions`
is an object describing the user account for which the credentials
generated (via `navigator.credentials.create()`).
`userAccount = publicKeyCredentialCreationOptions.user`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/user`"
[this val]
(aset this "user" val))
(defn challenge
"Property.
The challenge property of the `web.auth.PublicKeyCredentialCreationOptions`
is a `web.typed.BufferSource` used as a cryptographic challenge.
is randomly generated then sent from the relying party's server.
value (among other client data) will be signed by the authenticator,
its private key, and must be sent back for verification to the
as part of `AuthenticatorAttestationResponse.attestationObject`.
`challenge = publicKeyCredentialCreationOptions.challenge`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/challenge`"
[this]
(-> this (.-challenge)))
(defn set-challenge!
"Property.
The challenge property of the `web.auth.PublicKeyCredentialCreationOptions`
is a `web.typed.BufferSource` used as a cryptographic challenge.
is randomly generated then sent from the relying party's server.
value (among other client data) will be signed by the authenticator,
its private key, and must be sent back for verification to the
as part of `AuthenticatorAttestationResponse.attestationObject`.
`challenge = publicKeyCredentialCreationOptions.challenge`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/challenge`"
[this val]
(aset this "challenge" val))
(defn pub-key-cred-params
"Property.
The pubKeyCredParams property of the `web.auth.PublicKeyCredentialCreationOptions`
is an `js.Array` whose elements are objects describing the desired
of the credential to be created. These objects define the type
public-key and the algorithm used for cryptographic signature
`pubKeyCredParams = publicKeyCredentialCreationOptions.pubKeyCredParams`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/pubKeyCredParams`"
[this]
(-> this (.-pubKeyCredParams)))
(defn set-pub-key-cred-params!
"Property.
The pubKeyCredParams property of the `web.auth.PublicKeyCredentialCreationOptions`
is an `js.Array` whose elements are objects describing the desired
of the credential to be created. These objects define the type
public-key and the algorithm used for cryptographic signature
`pubKeyCredParams = publicKeyCredentialCreationOptions.pubKeyCredParams`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/pubKeyCredParams`"
[this val]
(aset this "pubKeyCredParams" val))
(defn timeout
"Property.
The timeout property, of the `web.auth.PublicKeyCredentialCreationOptions`
represents an hint, given in milliseconds, for the time the script
willing to wait for the completion of the creation operation.
`timeout = publicKeyCredentialCreationOptions.timeout`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/timeout`"
[this]
(-> this (.-timeout)))
(defn set-timeout!
"Property.
The timeout property, of the `web.auth.PublicKeyCredentialCreationOptions`
represents an hint, given in milliseconds, for the time the script
willing to wait for the completion of the creation operation.
`timeout = publicKeyCredentialCreationOptions.timeout`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/timeout`"
[this val]
(aset this "timeout" val))
(defn exclude-credentials
"Property.
excludeCredentials, an optional property of the `web.auth.PublicKeyCredentialCreationOptions`
is an `js.Array` whose elements are descriptors for the public
already existing for a given user. This is provided by the relying
server if it wants to prevent creation of new credentials for
existing user.
`excludeCredentials = publicKeyCredentialCreationOptions.excludeCredentials`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/excludeCredentials`"
[this]
(-> this (.-excludeCredentials)))
(defn set-exclude-credentials!
"Property.
excludeCredentials, an optional property of the `web.auth.PublicKeyCredentialCreationOptions`
is an `js.Array` whose elements are descriptors for the public
already existing for a given user. This is provided by the relying
server if it wants to prevent creation of new credentials for
existing user.
`excludeCredentials = publicKeyCredentialCreationOptions.excludeCredentials`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/excludeCredentials`"
[this val]
(aset this "excludeCredentials" val))
(defn authenticator-selection
"Property.
authenticatorSelection, an optional property of the `web.auth.PublicKeyCredentialCreationOptions`
is an object giving criteria to filter out the authenticators
be used for the creation operation.
`authenticatorSelection = publicKeyCredentialCreationOptions.authenticatorSelection`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/authenticatorSelection`"
[this]
(-> this (.-authenticatorSelection)))
(defn set-authenticator-selection!
"Property.
authenticatorSelection, an optional property of the `web.auth.PublicKeyCredentialCreationOptions`
is an object giving criteria to filter out the authenticators
be used for the creation operation.
`authenticatorSelection = publicKeyCredentialCreationOptions.authenticatorSelection`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/authenticatorSelection`"
[this val]
(aset this "authenticatorSelection" val))
(defn attestation
"Property.
attestation is an optional property of the `web.auth.PublicKeyCredentialCreationOptions`
This is a string whose value indicates the preference regarding
attestation transport, between the authenticator, the client
the relying party.
`attestation = publicKeyCredentialCreationOptions.attestation`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/attestation`"
[this]
(-> this (.-attestation)))
(defn set-attestation!
"Property.
attestation is an optional property of the `web.auth.PublicKeyCredentialCreationOptions`
This is a string whose value indicates the preference regarding
attestation transport, between the authenticator, the client
the relying party.
`attestation = publicKeyCredentialCreationOptions.attestation`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/attestation`"
[this val]
(aset this "attestation" val))
(defn extensions
"Property.
extensions, an optional property of the `web.auth.PublicKeyCredentialCreationOptions`
is an object providing the client extensions and their input
`extensions = publicKeyCredentialCreationOptions.extensions`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/extensions`"
[this]
(-> this (.-extensions)))
(defn set-extensions!
"Property.
extensions, an optional property of the `web.auth.PublicKeyCredentialCreationOptions`
is an object providing the client extensions and their input
`extensions = publicKeyCredentialCreationOptions.extensions`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/PublicKeyCredentialCreationOptions/extensions`"
[this val]
(aset this "extensions" val))