Support configurable verifiers for VC and VP
Overview
The service will have new ENV variable containing a list of verifiers (array).
Initially there will be only one verifier named TRAIN
.
CREDENTIAL_VERIFIERS="TRAIN"
In case there will be more than one verifier, it will be comma separated strings
CREDENTIAL_VERIFIERS="TRAIN,TRAIN2"
Verifiers will implement a specific interface to handle verification, for example:
import "github.com/hyperledger/aries-framework-go/pkg/doc/verifiable"
type Verifier interface {
VerifyCredential(ctx context.Context, vc *verifiable.Credential) error
VerifyPresentation(ctx context.Context, vp *verifiable.Presentation) error
}
When the service starts all configured verifiers will be initialized and ready for use. When a VC or VP needs to be verified, the service will use the initialized verifiers to perform additional verification.
These functionalities will be developed in the Signer service, as all VC/VP verifications happen there.
Trusted Content Resolver
Here is the TCR service which implements the TRAIN validation details.
https://gitlab.eclipse.org/eclipse/xfsc/train/trusted-content-resolver