Skip to content

Commit 6e0faa5

Browse files
sraptis-scyvkanellopoulos
authored andcommitted
Update Documentation Files
1 parent 8c46052 commit 6e0faa5

15 files changed

Lines changed: 118 additions & 33 deletions

File tree

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,12 +221,29 @@ val customWallet = EudiWallet(context, config) {
221221
withTransactionLogger(myTransactionLogger)
222222
// custom document status resolver
223223
withDocumentStatusResolver(myDocumentStatusResolver)
224+
// custom wallet key manager
225+
withWalletKeyManager(myWalletKeyManager)
224226
}
225227
```
226228

227229
See the [CustomizeSecureArea.md](CustomizeSecureArea.md) for more information on how to use the
228230
wallet-core library with custom SecureArea implementations.
229231

232+
233+
#### WalletKeyManager Configuration
234+
This interface is responsible for managing Attestation Keys used during Attestation Based Client Authentication with OpenId4Vci.
235+
The library provides `SecureAreaWalletKeyManager`, an extensible SecureArea based implementation of this interface.
236+
If no configuration is provided for a custom `WalletKeyManager` the default implementation of the library will be used based on `AndroidKeystoreSecureArea`.
237+
You can provide your custom `WalletKeyManager` by configuring the `EudiWallet` instance:
238+
```kotlin
239+
val customWallet = EudiWallet(context, config) {
240+
// rest of configurations
241+
// ......................
242+
// custom wallet key manager
243+
withWalletKeyManager(myWalletKeyManager)
244+
}
245+
```
246+
230247
#### Configure EudiWallet for Attestation Based Client Authentication(WIA) and Wallet Unit Attestation(WUA) with a Wallet Provider
231248
The wallet-core supports Wallet Instance Attestation (WIA) that attests the integrity of the app & Wallet Unit Attestation (WUA) that attests the security of keys stored in the Wallet Unit.
232249
You can optionally configure your wallet with this capability by implementing the core's `WalletAttestationsProvider` interface which bridges your wallet-specific Wallet Provider to the core.
@@ -259,6 +276,7 @@ val walletAttestationsProvider = object : WalletAttestationsProvider {
259276
}
260277
}
261278
```
279+
262280
So the configuration of the EudiWallet documented in the above section would now be:
263281
```kotlin
264282
val wallet = EudiWallet(
@@ -270,6 +288,7 @@ val wallet = EudiWallet(
270288

271289
**NOTE:** When Attestation Based Client Authentication is configured for OpendId4Vci, the `EudiWallet` must also be instantiated with a WalletProvider
272290

291+
273292
### Manage documents
274293

275294
The library provides a set of methods to work with documents.

docs/wallet-core/eu.europa.ec.eudi.wallet.issue.openid4vci/-deferred-issuance-stored-context-t-o/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,4 @@ data class [DeferredIssuanceStoredContextTO](index.md)(val credentialIssuerId: [
4444

4545
| Name | Summary |
4646
|---|---|
47-
| [toDeferredIssuanceStoredContext](to-deferred-issuance-stored-context.md) | [androidJvm]<br>fun [toDeferredIssuanceStoredContext](to-deferred-issuance-stored-context.md)(clock: [Clock](https://developer.android.com/reference/kotlin/java/time/Clock.html), recreatePopSigner: ([String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)) -&gt; Signer&lt;JWK&gt;?, recreateClientAttestationPodSigner: ([String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)) -&gt; Signer&lt;JWK&gt;?): DeferredIssuanceContext |
47+
| [toDeferredIssuanceStoredContext](to-deferred-issuance-stored-context.md) | [androidJvm]<br>fun [toDeferredIssuanceStoredContext](to-deferred-issuance-stored-context.md)(clock: [Clock](https://developer.android.com/reference/kotlin/java/time/Clock.html), recreatePopSigner: ([String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)) -&gt; Signer&lt;JWK&gt;?, walletKeyManager: [WalletKeyManager](../../eu.europa.ec.eudi.wallet.provider/-wallet-key-manager/index.md)): DeferredIssuanceContext |

docs/wallet-core/eu.europa.ec.eudi.wallet.issue.openid4vci/-deferred-issuance-stored-context-t-o/to-deferred-issuance-stored-context.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@
33
# toDeferredIssuanceStoredContext
44

55
[androidJvm]\
6-
fun [toDeferredIssuanceStoredContext](to-deferred-issuance-stored-context.md)(clock: [Clock](https://developer.android.com/reference/kotlin/java/time/Clock.html), recreatePopSigner: ([String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)) -&gt; Signer&lt;JWK&gt;?, recreateClientAttestationPodSigner: ([String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)) -&gt; Signer&lt;JWK&gt;?): DeferredIssuanceContext
6+
fun [toDeferredIssuanceStoredContext](to-deferred-issuance-stored-context.md)(clock: [Clock](https://developer.android.com/reference/kotlin/java/time/Clock.html), recreatePopSigner: ([String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)) -&gt; Signer&lt;JWK&gt;?, walletKeyManager: [WalletKeyManager](../../eu.europa.ec.eudi.wallet.provider/-wallet-key-manager/index.md)): DeferredIssuanceContext
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
//[wallet-core](../../../index.md)/[eu.europa.ec.eudi.wallet.provider](../index.md)/[DefaultWalletKeyManager](index.md)/[getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md)
2+
3+
# getOrCreateWalletAttestationKey
4+
5+
[androidJvm]\
6+
open suspend override fun [getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;
7+
8+
Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server
9+
10+
The implementation should ensure that the returned key is compatible with one of the [supportedAlgorithms](get-or-create-wallet-attestation-key.md) required by the Authorization Server.
11+
12+
#### Return
13+
14+
A [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html) containing the [WalletAttestationKey](../-wallet-attestation-key/index.md), which includes the public key info and a mechanism to sign data.
15+
16+
#### Parameters
17+
18+
androidJvm
19+
20+
| | |
21+
|---|---|
22+
| authorizationServerUrl | The URL of the Authorization Server. |
23+
| supportedAlgorithms | A list of cryptographic algorithms supported by the Authorization Server. The returned key must use one of these algorithms. |

docs/wallet-core/eu.europa.ec.eudi.wallet.provider/-default-wallet-key-manager/get-wallet-attestation-key.md

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,18 @@
33
# getWalletAttestationKey
44

55
[androidJvm]\
6-
open suspend override fun [getWalletAttestationKey](get-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;
6+
open suspend override fun [getWalletAttestationKey](get-wallet-attestation-key.md)(keyAlias: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)): [WalletAttestationKey](../-wallet-attestation-key/index.md)?
77

8-
Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server
9-
10-
The implementation should ensure that the returned key is compatible with one of the [supportedAlgorithms](get-wallet-attestation-key.md) required by the Authorization Server.
8+
Retrieves the existing Wallet Attestation Key for the specified Authorization Server URL. If no key exists for the given Authorization Server, it returns null.
119

1210
#### Return
1311

14-
A [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html) containing the [WalletAttestationKey](../-wallet-attestation-key/index.md), which includes the public key info and a mechanism to sign data.
12+
The existing [WalletAttestationKey](../-wallet-attestation-key/index.md) or null if not found.
1513

1614
#### Parameters
1715

1816
androidJvm
1917

2018
| | |
2119
|---|---|
22-
| authorizationServerUrl | The URL of the Authorization Server. |
23-
| supportedAlgorithms | A list of cryptographic algorithms supported by the Authorization Server. The returned key must use one of these algorithms. |
20+
| keyAlias | The URL of the Authorization Server. |

docs/wallet-core/eu.europa.ec.eudi.wallet.provider/-default-wallet-key-manager/index.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,5 @@ androidJvm
2626

2727
| Name | Summary |
2828
|---|---|
29-
| [getWalletAttestationKey](get-wallet-attestation-key.md) | [androidJvm]<br>open suspend override fun [getWalletAttestationKey](get-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;<br>Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server |
29+
| [getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md) | [androidJvm]<br>open suspend override fun [getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;<br>Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server |
30+
| [getWalletAttestationKey](get-wallet-attestation-key.md) | [androidJvm]<br>open suspend override fun [getWalletAttestationKey](get-wallet-attestation-key.md)(keyAlias: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)): [WalletAttestationKey](../-wallet-attestation-key/index.md)?<br>Retrieves the existing Wallet Attestation Key for the specified Authorization Server URL. If no key exists for the given Authorization Server, it returns null. |
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
//[wallet-core](../../../index.md)/[eu.europa.ec.eudi.wallet.provider](../index.md)/[SecureAreaWalletKeyManager](index.md)/[getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md)
2+
3+
# getOrCreateWalletAttestationKey
4+
5+
[androidJvm]\
6+
open suspend override fun [getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;
7+
8+
Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server
9+
10+
The implementation should ensure that the returned key is compatible with one of the [supportedAlgorithms](get-or-create-wallet-attestation-key.md) required by the Authorization Server.
11+
12+
#### Return
13+
14+
A [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html) containing the [WalletAttestationKey](../-wallet-attestation-key/index.md), which includes the public key info and a mechanism to sign data.
15+
16+
#### Parameters
17+
18+
androidJvm
19+
20+
| | |
21+
|---|---|
22+
| authorizationServerUrl | The URL of the Authorization Server. |
23+
| supportedAlgorithms | A list of cryptographic algorithms supported by the Authorization Server. The returned key must use one of these algorithms. |

docs/wallet-core/eu.europa.ec.eudi.wallet.provider/-secure-area-wallet-key-manager/get-wallet-attestation-key.md

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,18 @@
33
# getWalletAttestationKey
44

55
[androidJvm]\
6-
open suspend override fun [getWalletAttestationKey](get-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;
6+
open suspend override fun [getWalletAttestationKey](get-wallet-attestation-key.md)(keyAlias: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)): [WalletAttestationKey](../-wallet-attestation-key/index.md)?
77

8-
Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server
9-
10-
The implementation should ensure that the returned key is compatible with one of the [supportedAlgorithms](get-wallet-attestation-key.md) required by the Authorization Server.
8+
Retrieves the existing Wallet Attestation Key for the specified Authorization Server URL. If no key exists for the given Authorization Server, it returns null.
119

1210
#### Return
1311

14-
A [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html) containing the [WalletAttestationKey](../-wallet-attestation-key/index.md), which includes the public key info and a mechanism to sign data.
12+
The existing [WalletAttestationKey](../-wallet-attestation-key/index.md) or null if not found.
1513

1614
#### Parameters
1715

1816
androidJvm
1917

2018
| | |
2119
|---|---|
22-
| authorizationServerUrl | The URL of the Authorization Server. |
23-
| supportedAlgorithms | A list of cryptographic algorithms supported by the Authorization Server. The returned key must use one of these algorithms. |
20+
| keyAlias | The URL of the Authorization Server. |

docs/wallet-core/eu.europa.ec.eudi.wallet.provider/-secure-area-wallet-key-manager/index.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,5 @@ androidJvm
2828

2929
| Name | Summary |
3030
|---|---|
31-
| [getWalletAttestationKey](get-wallet-attestation-key.md) | [androidJvm]<br>open suspend override fun [getWalletAttestationKey](get-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;<br>Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server |
31+
| [getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md) | [androidJvm]<br>open suspend override fun [getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;<br>Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server |
32+
| [getWalletAttestationKey](get-wallet-attestation-key.md) | [androidJvm]<br>open suspend override fun [getWalletAttestationKey](get-wallet-attestation-key.md)(keyAlias: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html)): [WalletAttestationKey](../-wallet-attestation-key/index.md)?<br>Retrieves the existing Wallet Attestation Key for the specified Authorization Server URL. If no key exists for the given Authorization Server, it returns null. |
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
//[wallet-core](../../../index.md)/[eu.europa.ec.eudi.wallet.provider](../index.md)/[WalletKeyManager](index.md)/[getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md)
2+
3+
# getOrCreateWalletAttestationKey
4+
5+
[androidJvm]\
6+
abstract suspend fun [getOrCreateWalletAttestationKey](get-or-create-wallet-attestation-key.md)(authorizationServerUrl: [String](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-string/index.html), supportedAlgorithms: [List](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin.collections/-list/index.html)&lt;Algorithm&gt;): [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html)&lt;[WalletAttestationKey](../-wallet-attestation-key/index.md)&gt;
7+
8+
Retrieves or creates a signing key to be used for Wallet Attestation (Client Authentication). The Wallet Attestation Keys must be distinct for different Authorization Servers but unique for a specific one, and should be stored for subsequent use with the same Authorization Server
9+
10+
The implementation should ensure that the returned key is compatible with one of the [supportedAlgorithms](get-or-create-wallet-attestation-key.md) required by the Authorization Server.
11+
12+
#### Return
13+
14+
A [Result](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin-stdlib/kotlin/-result/index.html) containing the [WalletAttestationKey](../-wallet-attestation-key/index.md), which includes the public key info and a mechanism to sign data.
15+
16+
#### Parameters
17+
18+
androidJvm
19+
20+
| | |
21+
|---|---|
22+
| authorizationServerUrl | The URL of the Authorization Server. |
23+
| supportedAlgorithms | A list of cryptographic algorithms supported by the Authorization Server. The returned key must use one of these algorithms. |

0 commit comments

Comments
 (0)