1.0.0-beta.7 • Published 1 year ago
@vckit/revocationlist v1.0.0-beta.7
Revocation list 2020
The revocation list 2020 plugin is used to revoke and verify the verify credential based on the revocation list 2020 https://w3c-ccg.github.io/vc-status-rl-2020/
Usage
Configuration
To use the plugin you need to add the following configuration to the agent.yml
- First, define the revocation list plugin:
dbConnectionRevocationList:
$require: typeorm#DataSource
$args:
- type: sqlite
database:
$ref: /constants/databaseFile
synchronize: true
migrationsRun: true
migrations:
$require: '@vckit/revocationlist?t=object#migrations'
logging: false
entities:
$require: '@vckit/revocationlist?t=object#Entities'
revocationList:
$require: '@vckit/revocationlist#RevocationStatus2020'
$args:
- dbConnection:
$ref: /dbConnectionRevocationList
revocationListPath: http://localhost:3332
bitStringLength: 8
- Second, add the plugin and credential status plugin to the agent plugins list:
agent:
$require: '@vckit/core#Agent'
$args:
- schemaValidation: false
plugins:
# Plugins
- $ref: /revocationList
- $require: '@veramo/credential-status#CredentialStatusPlugin'
$args:
- RevocationList2020Status:
$require: '@vckit/revocationlist?t=object#checkStatus'
- Then, set the revocation list middleware to inject the credential status to the credential when it is issued:
- $require: '@vckit/revocationlist?t=function#revocationList2020'
$args:
- apiRoutes:
- /routeCreationVerifiableCredential
supportedProofFormats:
- jwt
- lds
- After that, you need to expose the plugin functions:
- revokeCredential
- activateCredential
- checkStatus
Every time the credential is issued by API /routeCreationVerifiableCredential
, the middleware will inject the credential status to the credential.
1.0.0-next.99
1 year ago
1.0.0-next.164
1 year ago
1.0.0-next.98
1 year ago
1.0.0-beta.7
1 year ago
1.0.0-next.96
1 year ago
1.0.0-beta.6
1 year ago