eclipse-tractusx / managed-identity-wallet

Apache License 2.0
7 stars 20 forks source link

feat: support for different key storages and signature services #276

Closed PManaras closed 2 months ago

PManaras commented 3 months ago

Description

This PR introduces support for implementing different types of keystorages via the newly KeyProvider interface. This interface can be used to retrieve keys from different types of storages, i.e. remote vaults, file-system, database.

The newly created SigningService can be used to implement different types of signature processes. The standard signature process is "LOCAL" meaning the MIW will use keys provided by the keyprovider to sign VP/VC locally.

This PR also adds to new properties to application.yaml (authoritySigningServiceType (defaults to "LOCAL), localSigningKeyStorageType (defaults to DB). These additions are also reflected in the corresponding env-files.

The database entity Wallet was updated and now contains a new field signingServiceType that reflects which wallet uses which signatureServices. The new field is introduced via a new database migration (v3) and sets the signing_service_type to "LOCAL" for all existing wallets. This means: with the standard configuration the MIW will act as before.

Pre-review checks

Please ensure to do as many of the following checks as possible, before asking for committer review:

sonarcloud[bot] commented 3 months ago

Quality Gate Passed Quality Gate passed

Issues
1 New issue
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

hkny commented 2 months ago

@borisrizov-zf is there any update on this PR?

borisrizov-zf commented 2 months ago

@PManaras please change the merge branch to develop and rebase accordingly.

borisrizov-zf commented 2 months ago

Superseded by #285