Skip to content

Commit

Permalink
chore: verify credential status
Browse files Browse the repository at this point in the history
Signed-off-by: Krishna Waske <krishna.waske@ayanworks.com>
  • Loading branch information
GHkrishna committed Oct 29, 2024
1 parent d671988 commit d3692f0
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -259,14 +259,15 @@ export class W3cJsonLdCredentialService {
)
const allSuites = presentationSuites.concat(...credentialSuites)

const verifyCredentialStatus = options.verifyCredentialStatus ?? true
const verifyOptions: Record<string, unknown> = {
presentation: JsonTransformer.toJSON(options.presentation),
suite: allSuites,
challenge: options.challenge,
domain: options.domain,
documentLoader: this.w3cCredentialsModuleConfig.documentLoader(agentContext),
checkStatus: async ({ credential }: { credential: W3cJsonCredential }) => {
if ('credentialStatus' in credential) {
if (verifyCredentialStatus && 'credentialStatus' in credential) {
await verifyBitStringCredentialStatus(credential, agentContext)
}
return {
Expand Down

0 comments on commit d3692f0

Please sign in to comment.