@credo-ts/anoncreds 0.6.1-pr-2091-20241119140918 → 0.6.2-alpha-20251210145840
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/AnonCredsApi.d.mts +113 -0
- package/build/AnonCredsApi.d.mts.map +1 -0
- package/build/AnonCredsApi.mjs +439 -0
- package/build/AnonCredsApi.mjs.map +1 -0
- package/build/AnonCredsApiOptions.d.mts +28 -0
- package/build/AnonCredsApiOptions.d.mts.map +1 -0
- package/build/AnonCredsModule.d.mts +29 -0
- package/build/AnonCredsModule.d.mts.map +1 -0
- package/build/AnonCredsModule.mjs +62 -0
- package/build/AnonCredsModule.mjs.map +1 -0
- package/build/AnonCredsModuleConfig.d.mts +79 -0
- package/build/AnonCredsModuleConfig.d.mts.map +1 -0
- package/build/AnonCredsModuleConfig.mjs +31 -0
- package/build/AnonCredsModuleConfig.mjs.map +1 -0
- package/build/_virtual/_@oxc-project_runtime@0.99.0/helpers/decorate.mjs +10 -0
- package/build/_virtual/_@oxc-project_runtime@0.99.0/helpers/decorateMetadata.mjs +7 -0
- package/build/_virtual/_@oxc-project_runtime@0.99.0/helpers/decorateParam.mjs +9 -0
- package/build/anoncreds-rs/AnonCredsDataIntegrityService.mjs +203 -0
- package/build/anoncreds-rs/AnonCredsDataIntegrityService.mjs.map +1 -0
- package/build/anoncreds-rs/AnonCredsRsHolderService.mjs +488 -0
- package/build/anoncreds-rs/AnonCredsRsHolderService.mjs.map +1 -0
- package/build/anoncreds-rs/AnonCredsRsIssuerService.mjs +213 -0
- package/build/anoncreds-rs/AnonCredsRsIssuerService.mjs.map +1 -0
- package/build/anoncreds-rs/AnonCredsRsVerifierService.mjs +122 -0
- package/build/anoncreds-rs/AnonCredsRsVerifierService.mjs.map +1 -0
- package/build/anoncreds-rs/index.mjs +3 -0
- package/build/anoncreds-rs/utils.mjs +60 -0
- package/build/anoncreds-rs/utils.mjs.map +1 -0
- package/build/error/AnonCredsError.d.mts +13 -0
- package/build/error/AnonCredsError.d.mts.map +1 -0
- package/build/error/AnonCredsError.mjs +12 -0
- package/build/error/AnonCredsError.mjs.map +1 -0
- package/build/error/AnonCredsRsError.d.mts +13 -0
- package/build/error/AnonCredsRsError.d.mts.map +1 -0
- package/build/error/AnonCredsRsError.mjs +12 -0
- package/build/error/AnonCredsRsError.mjs.map +1 -0
- package/build/error/AnonCredsStoreRecordError.d.mts +13 -0
- package/build/error/AnonCredsStoreRecordError.d.mts.map +1 -0
- package/build/error/AnonCredsStoreRecordError.mjs +12 -0
- package/build/error/AnonCredsStoreRecordError.mjs.map +1 -0
- package/build/error/index.d.mts +3 -0
- package/build/error/index.mjs +3 -0
- package/build/formats/AnonCredsDidCommCredentialFormat.d.mts +82 -0
- package/build/formats/AnonCredsDidCommCredentialFormat.d.mts.map +1 -0
- package/build/formats/AnonCredsDidCommCredentialFormatService.d.mts +120 -0
- package/build/formats/AnonCredsDidCommCredentialFormatService.d.mts.map +1 -0
- package/build/formats/AnonCredsDidCommCredentialFormatService.mjs +331 -0
- package/build/formats/AnonCredsDidCommCredentialFormatService.mjs.map +1 -0
- package/build/formats/AnonCredsDidCommProofFormat.d.mts +77 -0
- package/build/formats/AnonCredsDidCommProofFormat.d.mts.map +1 -0
- package/build/formats/AnonCredsDidCommProofFormatService.d.mts +93 -0
- package/build/formats/AnonCredsDidCommProofFormatService.d.mts.map +1 -0
- package/build/formats/AnonCredsDidCommProofFormatService.mjs +250 -0
- package/build/formats/AnonCredsDidCommProofFormatService.mjs.map +1 -0
- package/build/formats/DataIntegrityDidCommCredentialFormatService.d.mts +118 -0
- package/build/formats/DataIntegrityDidCommCredentialFormatService.d.mts.map +1 -0
- package/build/formats/DataIntegrityDidCommCredentialFormatService.mjs +587 -0
- package/build/formats/DataIntegrityDidCommCredentialFormatService.mjs.map +1 -0
- package/build/formats/LegacyIndyDidCommCredentialFormat.d.mts +38 -0
- package/build/formats/LegacyIndyDidCommCredentialFormat.d.mts.map +1 -0
- package/build/formats/LegacyIndyDidCommCredentialFormatService.d.mts +122 -0
- package/build/formats/LegacyIndyDidCommCredentialFormatService.d.mts.map +1 -0
- package/build/formats/LegacyIndyDidCommCredentialFormatService.mjs +309 -0
- package/build/formats/LegacyIndyDidCommCredentialFormatService.mjs.map +1 -0
- package/build/formats/LegacyIndyDidCommProofFormat.d.mts +36 -0
- package/build/formats/LegacyIndyDidCommProofFormat.d.mts.map +1 -0
- package/build/formats/LegacyIndyDidCommProofFormatService.d.mts +98 -0
- package/build/formats/LegacyIndyDidCommProofFormatService.d.mts.map +1 -0
- package/build/formats/LegacyIndyDidCommProofFormatService.mjs +322 -0
- package/build/formats/LegacyIndyDidCommProofFormatService.mjs.map +1 -0
- package/build/formats/index.d.mts +9 -0
- package/build/formats/index.mjs +5 -0
- package/build/index.d.mts +86 -0
- package/build/index.mjs +69 -0
- package/build/models/AnonCredsCredentialProposal.mjs +75 -0
- package/build/models/AnonCredsCredentialProposal.mjs.map +1 -0
- package/build/models/AnonCredsProofRequest.mjs +62 -0
- package/build/models/AnonCredsProofRequest.mjs.map +1 -0
- package/build/models/AnonCredsRequestedAttribute.mjs +50 -0
- package/build/models/AnonCredsRequestedAttribute.mjs.map +1 -0
- package/build/models/AnonCredsRequestedPredicate.mjs +53 -0
- package/build/models/AnonCredsRequestedPredicate.mjs.map +1 -0
- package/build/models/AnonCredsRestriction.d.mts +29 -0
- package/build/models/AnonCredsRestriction.d.mts.map +1 -0
- package/build/models/AnonCredsRestriction.mjs +137 -0
- package/build/models/AnonCredsRestriction.mjs.map +1 -0
- package/build/models/AnonCredsRestrictionWrapper.d.mts +9 -0
- package/build/models/AnonCredsRestrictionWrapper.d.mts.map +1 -0
- package/build/models/AnonCredsRestrictionWrapper.mjs +18 -0
- package/build/models/AnonCredsRestrictionWrapper.mjs.map +1 -0
- package/build/models/AnonCredsRevocationInterval.mjs +27 -0
- package/build/models/AnonCredsRevocationInterval.mjs.map +1 -0
- package/build/models/exchange.d.mts +104 -0
- package/build/models/exchange.d.mts.map +1 -0
- package/build/models/exchange.mjs +11 -0
- package/build/models/exchange.mjs.map +1 -0
- package/build/models/index.d.mts +4 -0
- package/build/models/index.mjs +2 -0
- package/build/models/internal.d.mts +40 -0
- package/build/models/internal.d.mts.map +1 -0
- package/build/models/registry.d.mts +44 -0
- package/build/models/registry.d.mts.map +1 -0
- package/build/models/utils.d.mts +27 -0
- package/build/models/utils.d.mts.map +1 -0
- package/build/protocols/credentials/v1/DidCommCredentialV1Protocol.d.mts +215 -0
- package/build/protocols/credentials/v1/DidCommCredentialV1Protocol.d.mts.map +1 -0
- package/build/protocols/credentials/v1/DidCommCredentialV1Protocol.mjs +827 -0
- package/build/protocols/credentials/v1/DidCommCredentialV1Protocol.mjs.map +1 -0
- package/build/protocols/credentials/v1/handlers/DidCommCredentialV1AckHandler.mjs +17 -0
- package/build/protocols/credentials/v1/handlers/DidCommCredentialV1AckHandler.mjs.map +1 -0
- package/build/protocols/credentials/v1/handlers/DidCommCredentialV1ProblemReportHandler.mjs +17 -0
- package/build/protocols/credentials/v1/handlers/DidCommCredentialV1ProblemReportHandler.mjs.map +1 -0
- package/build/protocols/credentials/v1/handlers/DidCommIssueCredentialV1Handler.mjs +36 -0
- package/build/protocols/credentials/v1/handlers/DidCommIssueCredentialV1Handler.mjs.map +1 -0
- package/build/protocols/credentials/v1/handlers/DidCommOfferCredentialV1Handler.mjs +32 -0
- package/build/protocols/credentials/v1/handlers/DidCommOfferCredentialV1Handler.mjs.map +1 -0
- package/build/protocols/credentials/v1/handlers/DidCommProposeCredentialV1Handler.mjs +35 -0
- package/build/protocols/credentials/v1/handlers/DidCommProposeCredentialV1Handler.mjs.map +1 -0
- package/build/protocols/credentials/v1/handlers/DidCommRequestCredentialV1Handler.mjs +36 -0
- package/build/protocols/credentials/v1/handlers/DidCommRequestCredentialV1Handler.mjs.map +1 -0
- package/build/protocols/credentials/v1/handlers/index.mjs +6 -0
- package/build/protocols/credentials/v1/index.d.mts +9 -0
- package/build/protocols/credentials/v1/index.mjs +9 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1AckMessage.d.mts +16 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1AckMessage.d.mts.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1AckMessage.mjs +21 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1AckMessage.mjs.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1Preview.d.mts +32 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1Preview.d.mts.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1Preview.mjs +57 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1Preview.mjs.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1ProblemReportMessage.d.mts +16 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1ProblemReportMessage.d.mts.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1ProblemReportMessage.mjs +21 -0
- package/build/protocols/credentials/v1/messages/DidCommCredentialV1ProblemReportMessage.mjs.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommIssueCredentialV1Message.d.mts +26 -0
- package/build/protocols/credentials/v1/messages/DidCommIssueCredentialV1Message.d.mts.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommIssueCredentialV1Message.mjs +46 -0
- package/build/protocols/credentials/v1/messages/DidCommIssueCredentialV1Message.mjs.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommOfferCredentialV1Message.d.mts +34 -0
- package/build/protocols/credentials/v1/messages/DidCommOfferCredentialV1Message.d.mts.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommOfferCredentialV1Message.mjs +61 -0
- package/build/protocols/credentials/v1/messages/DidCommOfferCredentialV1Message.mjs.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommProposeCredentialV1Message.d.mts +64 -0
- package/build/protocols/credentials/v1/messages/DidCommProposeCredentialV1Message.d.mts.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommProposeCredentialV1Message.mjs +95 -0
- package/build/protocols/credentials/v1/messages/DidCommProposeCredentialV1Message.mjs.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommRequestCredentialV1Message.d.mts +26 -0
- package/build/protocols/credentials/v1/messages/DidCommRequestCredentialV1Message.d.mts.map +1 -0
- package/build/protocols/credentials/v1/messages/DidCommRequestCredentialV1Message.mjs +46 -0
- package/build/protocols/credentials/v1/messages/DidCommRequestCredentialV1Message.mjs.map +1 -0
- package/build/protocols/credentials/v1/messages/index.d.mts +7 -0
- package/build/protocols/credentials/v1/messages/index.mjs +7 -0
- package/build/protocols/index.d.mts +18 -0
- package/build/protocols/index.mjs +18 -0
- package/build/protocols/proofs/v1/DidCommProofV1Protocol.d.mts +105 -0
- package/build/protocols/proofs/v1/DidCommProofV1Protocol.d.mts.map +1 -0
- package/build/protocols/proofs/v1/DidCommProofV1Protocol.mjs +723 -0
- package/build/protocols/proofs/v1/DidCommProofV1Protocol.mjs.map +1 -0
- package/build/protocols/proofs/v1/errors/DidCommPresentationV1ProblemReportError.d.mts +18 -0
- package/build/protocols/proofs/v1/errors/DidCommPresentationV1ProblemReportError.d.mts.map +1 -0
- package/build/protocols/proofs/v1/errors/DidCommPresentationV1ProblemReportError.mjs +19 -0
- package/build/protocols/proofs/v1/errors/DidCommPresentationV1ProblemReportError.mjs.map +1 -0
- package/build/protocols/proofs/v1/errors/index.d.mts +1 -0
- package/build/protocols/proofs/v1/errors/index.mjs +1 -0
- package/build/protocols/proofs/v1/handlers/DidCommPresentationV1AckHandler.mjs +17 -0
- package/build/protocols/proofs/v1/handlers/DidCommPresentationV1AckHandler.mjs.map +1 -0
- package/build/protocols/proofs/v1/handlers/DidCommPresentationV1Handler.mjs +36 -0
- package/build/protocols/proofs/v1/handlers/DidCommPresentationV1Handler.mjs.map +1 -0
- package/build/protocols/proofs/v1/handlers/DidCommPresentationV1ProblemReportHandler.mjs +16 -0
- package/build/protocols/proofs/v1/handlers/DidCommPresentationV1ProblemReportHandler.mjs.map +1 -0
- package/build/protocols/proofs/v1/handlers/DidCommProposePresentationV1Handler.mjs +35 -0
- package/build/protocols/proofs/v1/handlers/DidCommProposePresentationV1Handler.mjs.map +1 -0
- package/build/protocols/proofs/v1/handlers/DidCommRequestPresentationV1Handler.mjs +32 -0
- package/build/protocols/proofs/v1/handlers/DidCommRequestPresentationV1Handler.mjs.map +1 -0
- package/build/protocols/proofs/v1/handlers/index.mjs +5 -0
- package/build/protocols/proofs/v1/index.d.mts +11 -0
- package/build/protocols/proofs/v1/index.mjs +11 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1AckMessage.d.mts +12 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1AckMessage.d.mts.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1AckMessage.mjs +18 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1AckMessage.mjs.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1Message.d.mts +38 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1Message.d.mts.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1Message.mjs +52 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1Message.mjs.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1ProblemReportMessage.d.mts +16 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1ProblemReportMessage.d.mts.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1ProblemReportMessage.mjs +21 -0
- package/build/protocols/proofs/v1/messages/DidCommPresentationV1ProblemReportMessage.mjs.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommProposePresentationV1Message.d.mts +32 -0
- package/build/protocols/proofs/v1/messages/DidCommProposePresentationV1Message.d.mts.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommProposePresentationV1Message.mjs +44 -0
- package/build/protocols/proofs/v1/messages/DidCommProposePresentationV1Message.mjs.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommRequestPresentationV1Message.d.mts +36 -0
- package/build/protocols/proofs/v1/messages/DidCommRequestPresentationV1Message.d.mts.map +1 -0
- package/build/protocols/proofs/v1/messages/DidCommRequestPresentationV1Message.mjs +50 -0
- package/build/protocols/proofs/v1/messages/DidCommRequestPresentationV1Message.mjs.map +1 -0
- package/build/protocols/proofs/v1/messages/index.d.mts +5 -0
- package/build/protocols/proofs/v1/messages/index.mjs +5 -0
- package/build/protocols/proofs/v1/models/DidCommPresentationV1Preview.d.mts +57 -0
- package/build/protocols/proofs/v1/models/DidCommPresentationV1Preview.d.mts.map +1 -0
- package/build/protocols/proofs/v1/models/DidCommPresentationV1Preview.mjs +113 -0
- package/build/protocols/proofs/v1/models/DidCommPresentationV1Preview.mjs.map +1 -0
- package/build/protocols/proofs/v1/models/index.d.mts +1 -0
- package/build/protocols/proofs/v1/models/index.mjs +1 -0
- package/build/repository/AnonCredsCredentialDefinitionPrivateRecord.d.mts +25 -0
- package/build/repository/AnonCredsCredentialDefinitionPrivateRecord.d.mts.map +1 -0
- package/build/repository/AnonCredsCredentialDefinitionPrivateRecord.mjs +26 -0
- package/build/repository/AnonCredsCredentialDefinitionPrivateRecord.mjs.map +1 -0
- package/build/repository/AnonCredsCredentialDefinitionPrivateRepository.d.mts +12 -0
- package/build/repository/AnonCredsCredentialDefinitionPrivateRepository.d.mts.map +1 -0
- package/build/repository/AnonCredsCredentialDefinitionPrivateRepository.mjs +28 -0
- package/build/repository/AnonCredsCredentialDefinitionPrivateRepository.mjs.map +1 -0
- package/build/repository/AnonCredsCredentialDefinitionRecord.d.mts +44 -0
- package/build/repository/AnonCredsCredentialDefinitionRecord.d.mts.map +1 -0
- package/build/repository/AnonCredsCredentialDefinitionRecord.mjs +38 -0
- package/build/repository/AnonCredsCredentialDefinitionRecord.mjs.map +1 -0
- package/build/repository/AnonCredsCredentialDefinitionRepository.d.mts +12 -0
- package/build/repository/AnonCredsCredentialDefinitionRepository.d.mts.map +1 -0
- package/build/repository/AnonCredsCredentialDefinitionRepository.mjs +28 -0
- package/build/repository/AnonCredsCredentialDefinitionRepository.mjs.map +1 -0
- package/build/repository/AnonCredsCredentialRecord.d.mts +53 -0
- package/build/repository/AnonCredsCredentialRecord.d.mts.map +1 -0
- package/build/repository/AnonCredsCredentialRecord.mjs +46 -0
- package/build/repository/AnonCredsCredentialRecord.mjs.map +1 -0
- package/build/repository/AnonCredsCredentialRepository.d.mts +14 -0
- package/build/repository/AnonCredsCredentialRepository.d.mts.map +1 -0
- package/build/repository/AnonCredsCredentialRepository.mjs +34 -0
- package/build/repository/AnonCredsCredentialRepository.mjs.map +1 -0
- package/build/repository/AnonCredsKeyCorrectnessProofRecord.d.mts +25 -0
- package/build/repository/AnonCredsKeyCorrectnessProofRecord.d.mts.map +1 -0
- package/build/repository/AnonCredsKeyCorrectnessProofRecord.mjs +26 -0
- package/build/repository/AnonCredsKeyCorrectnessProofRecord.mjs.map +1 -0
- package/build/repository/AnonCredsKeyCorrectnessProofRepository.d.mts +12 -0
- package/build/repository/AnonCredsKeyCorrectnessProofRepository.d.mts.map +1 -0
- package/build/repository/AnonCredsKeyCorrectnessProofRepository.mjs +28 -0
- package/build/repository/AnonCredsKeyCorrectnessProofRepository.mjs.map +1 -0
- package/build/repository/AnonCredsLinkSecretRecord.d.mts +28 -0
- package/build/repository/AnonCredsLinkSecretRecord.d.mts.map +1 -0
- package/build/repository/AnonCredsLinkSecretRecord.mjs +25 -0
- package/build/repository/AnonCredsLinkSecretRecord.mjs.map +1 -0
- package/build/repository/AnonCredsLinkSecretRepository.d.mts +14 -0
- package/build/repository/AnonCredsLinkSecretRepository.d.mts.map +1 -0
- package/build/repository/AnonCredsLinkSecretRepository.mjs +34 -0
- package/build/repository/AnonCredsLinkSecretRepository.mjs.map +1 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRecord.d.mts +37 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRecord.d.mts.map +1 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRecord.mjs +35 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRecord.mjs.map +1 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRepository.d.mts +13 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRepository.d.mts.map +1 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRepository.mjs +34 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRepository.mjs.map +1 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionRecord.d.mts +30 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionRecord.d.mts.map +1 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionRecord.mjs +27 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionRecord.mjs.map +1 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionRepository.d.mts +13 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionRepository.d.mts.map +1 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionRepository.mjs +31 -0
- package/build/repository/AnonCredsRevocationRegistryDefinitionRepository.mjs.map +1 -0
- package/build/repository/AnonCredsSchemaRecord.d.mts +44 -0
- package/build/repository/AnonCredsSchemaRecord.d.mts.map +1 -0
- package/build/repository/AnonCredsSchemaRecord.mjs +38 -0
- package/build/repository/AnonCredsSchemaRecord.mjs.map +1 -0
- package/build/repository/AnonCredsSchemaRepository.d.mts +12 -0
- package/build/repository/AnonCredsSchemaRepository.d.mts.map +1 -0
- package/build/repository/AnonCredsSchemaRepository.mjs +28 -0
- package/build/repository/AnonCredsSchemaRepository.mjs.map +1 -0
- package/build/repository/anonCredsCredentialDefinitionRecordMetadataTypes.d.mts +14 -0
- package/build/repository/anonCredsCredentialDefinitionRecordMetadataTypes.d.mts.map +1 -0
- package/build/repository/anonCredsCredentialDefinitionRecordMetadataTypes.mjs +10 -0
- package/build/repository/anonCredsCredentialDefinitionRecordMetadataTypes.mjs.map +1 -0
- package/build/repository/anonCredsRevocationRegistryDefinitionRecordMetadataTypes.d.mts +14 -0
- package/build/repository/anonCredsRevocationRegistryDefinitionRecordMetadataTypes.d.mts.map +1 -0
- package/build/repository/anonCredsRevocationRegistryDefinitionRecordMetadataTypes.mjs +10 -0
- package/build/repository/anonCredsRevocationRegistryDefinitionRecordMetadataTypes.mjs.map +1 -0
- package/build/repository/anonCredsSchemaRecordMetadataTypes.d.mts +14 -0
- package/build/repository/anonCredsSchemaRecordMetadataTypes.d.mts.map +1 -0
- package/build/repository/index.d.mts +16 -0
- package/build/repository/index.mjs +16 -0
- package/build/services/AnonCredsHolderService.d.mts +28 -0
- package/build/services/AnonCredsHolderService.d.mts.map +1 -0
- package/build/services/AnonCredsHolderService.mjs +6 -0
- package/build/services/AnonCredsHolderService.mjs.map +1 -0
- package/build/services/AnonCredsHolderServiceOptions.d.mts +107 -0
- package/build/services/AnonCredsHolderServiceOptions.d.mts.map +1 -0
- package/build/services/AnonCredsIssuerService.d.mts +19 -0
- package/build/services/AnonCredsIssuerService.d.mts.map +1 -0
- package/build/services/AnonCredsIssuerService.mjs +6 -0
- package/build/services/AnonCredsIssuerService.mjs.map +1 -0
- package/build/services/AnonCredsIssuerServiceOptions.d.mts +66 -0
- package/build/services/AnonCredsIssuerServiceOptions.d.mts.map +1 -0
- package/build/services/AnonCredsVerifierService.d.mts +12 -0
- package/build/services/AnonCredsVerifierService.d.mts.map +1 -0
- package/build/services/AnonCredsVerifierService.mjs +6 -0
- package/build/services/AnonCredsVerifierService.mjs.map +1 -0
- package/build/services/AnonCredsVerifierServiceOptions.d.mts +30 -0
- package/build/services/AnonCredsVerifierServiceOptions.d.mts.map +1 -0
- package/build/services/index.d.mts +17 -0
- package/build/services/index.mjs +7 -0
- package/build/services/registry/AnonCredsRegistry.d.mts +43 -0
- package/build/services/registry/AnonCredsRegistry.d.mts.map +1 -0
- package/build/services/registry/AnonCredsRegistryService.d.mts +27 -0
- package/build/services/registry/AnonCredsRegistryService.d.mts.map +1 -0
- package/build/services/registry/AnonCredsRegistryService.mjs +226 -0
- package/build/services/registry/AnonCredsRegistryService.mjs.map +1 -0
- package/build/services/registry/CredentialDefinitionOptions.d.mts +39 -0
- package/build/services/registry/CredentialDefinitionOptions.d.mts.map +1 -0
- package/build/services/registry/RevocationRegistryDefinitionOptions.d.mts +39 -0
- package/build/services/registry/RevocationRegistryDefinitionOptions.d.mts.map +1 -0
- package/build/services/registry/RevocationStatusListOptions.d.mts +37 -0
- package/build/services/registry/RevocationStatusListOptions.d.mts.map +1 -0
- package/build/services/registry/SchemaOptions.d.mts +39 -0
- package/build/services/registry/SchemaOptions.d.mts.map +1 -0
- package/build/services/registry/base.d.mts +65 -0
- package/build/services/registry/base.d.mts.map +1 -0
- package/build/services/registry/index.d.mts +7 -0
- package/build/services/registry/index.mjs +1 -0
- package/build/services/tails/BasicTailsFileService.d.mts +29 -0
- package/build/services/tails/BasicTailsFileService.d.mts.map +1 -0
- package/build/services/tails/BasicTailsFileService.mjs +52 -0
- package/build/services/tails/BasicTailsFileService.mjs.map +1 -0
- package/build/services/tails/TailsFileService.d.mts +48 -0
- package/build/services/tails/TailsFileService.d.mts.map +1 -0
- package/build/services/tails/index.d.mts +2 -0
- package/build/services/tails/index.mjs +1 -0
- package/build/updates/0.3.1-0.4/credentialDefinition.mjs +49 -0
- package/build/updates/0.3.1-0.4/credentialDefinition.mjs.map +1 -0
- package/build/updates/0.3.1-0.4/credentialExchangeRecord.mjs +118 -0
- package/build/updates/0.3.1-0.4/credentialExchangeRecord.mjs.map +1 -0
- package/build/updates/0.3.1-0.4/index.d.mts +7 -0
- package/build/updates/0.3.1-0.4/index.d.mts.map +1 -0
- package/build/updates/0.3.1-0.4/index.mjs +16 -0
- package/build/updates/0.3.1-0.4/index.mjs.map +1 -0
- package/build/updates/0.3.1-0.4/linkSecret.mjs +21 -0
- package/build/updates/0.3.1-0.4/linkSecret.mjs.map +1 -0
- package/build/updates/0.3.1-0.4/schema.mjs +39 -0
- package/build/updates/0.3.1-0.4/schema.mjs.map +1 -0
- package/build/updates/0.4-0.5/anonCredsCredentialRecord.mjs +126 -0
- package/build/updates/0.4-0.5/anonCredsCredentialRecord.mjs.map +1 -0
- package/build/updates/0.4-0.5/index.d.mts +7 -0
- package/build/updates/0.4-0.5/index.d.mts.map +1 -0
- package/build/updates/0.4-0.5/index.mjs +10 -0
- package/build/updates/0.4-0.5/index.mjs.map +1 -0
- package/build/utils/anonCredsObjects.d.mts +27 -0
- package/build/utils/anonCredsObjects.d.mts.map +1 -0
- package/build/utils/anonCredsObjects.mjs +57 -0
- package/build/utils/anonCredsObjects.mjs.map +1 -0
- package/build/utils/areRequestsEqual.d.mts +1 -0
- package/build/utils/areRequestsEqual.mjs +86 -0
- package/build/utils/areRequestsEqual.mjs.map +1 -0
- package/build/utils/bytesToBigint.mjs +11 -0
- package/build/utils/bytesToBigint.mjs.map +1 -0
- package/build/utils/composeAutoAccept.d.mts +1 -0
- package/build/utils/composeAutoAccept.mjs +25 -0
- package/build/utils/composeAutoAccept.mjs.map +1 -0
- package/build/utils/createRequestFromPreview.d.mts +2 -0
- package/build/utils/createRequestFromPreview.mjs +50 -0
- package/build/utils/createRequestFromPreview.mjs.map +1 -0
- package/build/utils/credential.d.mts +12 -0
- package/build/utils/credential.d.mts.map +1 -0
- package/build/utils/credential.mjs +119 -0
- package/build/utils/credential.mjs.map +1 -0
- package/build/utils/credentialPreviewAttributes.d.mts +1 -0
- package/build/utils/credentialPreviewAttributes.mjs +21 -0
- package/build/utils/credentialPreviewAttributes.mjs.map +1 -0
- package/build/utils/getCredentialsForAnonCredsRequest.d.mts +11 -0
- package/build/utils/getCredentialsForAnonCredsRequest.d.mts.map +1 -0
- package/build/utils/getCredentialsForAnonCredsRequest.mjs +70 -0
- package/build/utils/getCredentialsForAnonCredsRequest.mjs.map +1 -0
- package/build/utils/getRevocationRegistries.d.mts +4 -0
- package/build/utils/getRevocationRegistries.mjs +121 -0
- package/build/utils/getRevocationRegistries.mjs.map +1 -0
- package/build/utils/hasDuplicateGroupNames.d.mts +1 -0
- package/build/utils/hasDuplicateGroupNames.mjs +22 -0
- package/build/utils/hasDuplicateGroupNames.mjs.map +1 -0
- package/build/utils/index.d.mts +17 -0
- package/build/utils/index.mjs +17 -0
- package/build/utils/indyIdentifiers.d.mts +71 -0
- package/build/utils/indyIdentifiers.d.mts.map +1 -0
- package/build/utils/indyIdentifiers.mjs +249 -0
- package/build/utils/indyIdentifiers.mjs.map +1 -0
- package/build/utils/isMap.d.mts +1 -0
- package/build/utils/isMap.mjs +19 -0
- package/build/utils/isMap.mjs.map +1 -0
- package/build/utils/linkSecret.d.mts +13 -0
- package/build/utils/linkSecret.d.mts.map +1 -0
- package/build/utils/linkSecret.mjs +35 -0
- package/build/utils/linkSecret.mjs.map +1 -0
- package/build/utils/metadata.d.mts +30 -0
- package/build/utils/metadata.d.mts.map +1 -0
- package/build/utils/metadata.mjs +23 -0
- package/build/utils/metadata.mjs.map +1 -0
- package/build/utils/proofRequest.mjs +10 -0
- package/build/utils/proofRequest.mjs.map +1 -0
- package/build/utils/proverDid.d.mts +12 -0
- package/build/utils/proverDid.d.mts.map +1 -0
- package/build/utils/proverDid.mjs +17 -0
- package/build/utils/proverDid.mjs.map +1 -0
- package/build/utils/revocationInterval.d.mts +12 -0
- package/build/utils/revocationInterval.d.mts.map +1 -0
- package/build/utils/revocationInterval.mjs +11 -0
- package/build/utils/revocationInterval.mjs.map +1 -0
- package/build/utils/sortRequestedCredentialsMatches.d.mts +1 -0
- package/build/utils/sortRequestedCredentialsMatches.mjs +22 -0
- package/build/utils/sortRequestedCredentialsMatches.mjs.map +1 -0
- package/build/utils/timestamp.d.mts +5 -0
- package/build/utils/timestamp.d.mts.map +1 -0
- package/build/utils/timestamp.mjs +6 -0
- package/build/utils/timestamp.mjs.map +1 -0
- package/build/utils/w3cAnonCredsUtils.d.mts +28 -0
- package/build/utils/w3cAnonCredsUtils.d.mts.map +1 -0
- package/build/utils/w3cAnonCredsUtils.mjs +101 -0
- package/build/utils/w3cAnonCredsUtils.mjs.map +1 -0
- package/package.json +20 -21
- package/build/AnonCredsApi.d.ts +0 -97
- package/build/AnonCredsApi.js +0 -582
- package/build/AnonCredsApi.js.map +0 -1
- package/build/AnonCredsApiOptions.d.ts +0 -24
- package/build/AnonCredsApiOptions.js +0 -3
- package/build/AnonCredsApiOptions.js.map +0 -1
- package/build/AnonCredsModule.d.ts +0 -24
- package/build/AnonCredsModule.js +0 -56
- package/build/AnonCredsModule.js.map +0 -1
- package/build/AnonCredsModuleConfig.d.ts +0 -72
- package/build/AnonCredsModuleConfig.js +0 -31
- package/build/AnonCredsModuleConfig.js.map +0 -1
- package/build/anoncreds-rs/AnonCredsDataIntegrityService.d.ts +0 -27
- package/build/anoncreds-rs/AnonCredsDataIntegrityService.js +0 -241
- package/build/anoncreds-rs/AnonCredsDataIntegrityService.js.map +0 -1
- package/build/anoncreds-rs/AnonCredsRsHolderService.d.ts +0 -38
- package/build/anoncreds-rs/AnonCredsRsHolderService.js +0 -622
- package/build/anoncreds-rs/AnonCredsRsHolderService.js.map +0 -1
- package/build/anoncreds-rs/AnonCredsRsIssuerService.d.ts +0 -12
- package/build/anoncreds-rs/AnonCredsRsIssuerService.js +0 -253
- package/build/anoncreds-rs/AnonCredsRsIssuerService.js.map +0 -1
- package/build/anoncreds-rs/AnonCredsRsVerifierService.d.ts +0 -8
- package/build/anoncreds-rs/AnonCredsRsVerifierService.js +0 -157
- package/build/anoncreds-rs/AnonCredsRsVerifierService.js.map +0 -1
- package/build/anoncreds-rs/index.d.ts +0 -3
- package/build/anoncreds-rs/index.js +0 -10
- package/build/anoncreds-rs/index.js.map +0 -1
- package/build/anoncreds-rs/utils.d.ts +0 -23
- package/build/anoncreds-rs/utils.js +0 -71
- package/build/anoncreds-rs/utils.js.map +0 -1
- package/build/error/AnonCredsError.d.ts +0 -6
- package/build/error/AnonCredsError.js +0 -11
- package/build/error/AnonCredsError.js.map +0 -1
- package/build/error/AnonCredsRsError.d.ts +0 -6
- package/build/error/AnonCredsRsError.js +0 -11
- package/build/error/AnonCredsRsError.js.map +0 -1
- package/build/error/AnonCredsStoreRecordError.d.ts +0 -6
- package/build/error/AnonCredsStoreRecordError.js +0 -11
- package/build/error/AnonCredsStoreRecordError.js.map +0 -1
- package/build/error/index.d.ts +0 -3
- package/build/error/index.js +0 -20
- package/build/error/index.js.map +0 -1
- package/build/formats/AnonCredsCredentialFormat.d.ts +0 -79
- package/build/formats/AnonCredsCredentialFormat.js +0 -3
- package/build/formats/AnonCredsCredentialFormat.js.map +0 -1
- package/build/formats/AnonCredsCredentialFormatService.d.ts +0 -80
- package/build/formats/AnonCredsCredentialFormatService.js +0 -433
- package/build/formats/AnonCredsCredentialFormatService.js.map +0 -1
- package/build/formats/AnonCredsProofFormat.d.ts +0 -70
- package/build/formats/AnonCredsProofFormat.js +0 -3
- package/build/formats/AnonCredsProofFormat.js.map +0 -1
- package/build/formats/AnonCredsProofFormatService.d.ts +0 -55
- package/build/formats/AnonCredsProofFormatService.js +0 -289
- package/build/formats/AnonCredsProofFormatService.js.map +0 -1
- package/build/formats/DataIntegrityCredentialFormatService.d.ts +0 -89
- package/build/formats/DataIntegrityCredentialFormatService.js +0 -773
- package/build/formats/DataIntegrityCredentialFormatService.js.map +0 -1
- package/build/formats/LegacyIndyCredentialFormat.d.ts +0 -32
- package/build/formats/LegacyIndyCredentialFormat.js +0 -3
- package/build/formats/LegacyIndyCredentialFormat.js.map +0 -1
- package/build/formats/LegacyIndyCredentialFormatService.d.ts +0 -80
- package/build/formats/LegacyIndyCredentialFormatService.js +0 -379
- package/build/formats/LegacyIndyCredentialFormatService.js.map +0 -1
- package/build/formats/LegacyIndyProofFormat.d.ts +0 -29
- package/build/formats/LegacyIndyProofFormat.js +0 -3
- package/build/formats/LegacyIndyProofFormat.js.map +0 -1
- package/build/formats/LegacyIndyProofFormatService.d.ts +0 -58
- package/build/formats/LegacyIndyProofFormatService.js +0 -374
- package/build/formats/LegacyIndyProofFormatService.js.map +0 -1
- package/build/formats/index.d.ts +0 -9
- package/build/formats/index.js +0 -32
- package/build/formats/index.js.map +0 -1
- package/build/index.d.ts +0 -21
- package/build/index.js +0 -54
- package/build/index.js.map +0 -1
- package/build/models/AnonCredsCredentialProposal.d.ts +0 -62
- package/build/models/AnonCredsCredentialProposal.js +0 -81
- package/build/models/AnonCredsCredentialProposal.js.map +0 -1
- package/build/models/AnonCredsProofRequest.d.ts +0 -27
- package/build/models/AnonCredsProofRequest.js +0 -82
- package/build/models/AnonCredsProofRequest.js.map +0 -1
- package/build/models/AnonCredsRequestedAttribute.d.ts +0 -16
- package/build/models/AnonCredsRequestedAttribute.js +0 -56
- package/build/models/AnonCredsRequestedAttribute.js.map +0 -1
- package/build/models/AnonCredsRequestedPredicate.d.ts +0 -19
- package/build/models/AnonCredsRequestedPredicate.js +0 -61
- package/build/models/AnonCredsRequestedPredicate.js.map +0 -1
- package/build/models/AnonCredsRestriction.d.ts +0 -55
- package/build/models/AnonCredsRestriction.js +0 -160
- package/build/models/AnonCredsRestriction.js.map +0 -1
- package/build/models/AnonCredsRestrictionWrapper.d.ts +0 -4
- package/build/models/AnonCredsRestrictionWrapper.js +0 -25
- package/build/models/AnonCredsRestrictionWrapper.js.map +0 -1
- package/build/models/AnonCredsRevocationInterval.d.ts +0 -5
- package/build/models/AnonCredsRevocationInterval.js +0 -33
- package/build/models/AnonCredsRevocationInterval.js.map +0 -1
- package/build/models/exchange.d.ts +0 -99
- package/build/models/exchange.js +0 -5
- package/build/models/exchange.js.map +0 -1
- package/build/models/index.d.ts +0 -4
- package/build/models/index.js +0 -21
- package/build/models/index.js.map +0 -1
- package/build/models/internal.d.ts +0 -35
- package/build/models/internal.js +0 -3
- package/build/models/internal.js.map +0 -1
- package/build/models/registry.d.ts +0 -39
- package/build/models/registry.js +0 -3
- package/build/models/registry.js.map +0 -1
- package/build/models/utils.d.ts +0 -22
- package/build/models/utils.js +0 -3
- package/build/models/utils.js.map +0 -1
- package/build/protocols/credentials/v1/V1CredentialProtocol.d.ts +0 -162
- package/build/protocols/credentials/v1/V1CredentialProtocol.js +0 -948
- package/build/protocols/credentials/v1/V1CredentialProtocol.js.map +0 -1
- package/build/protocols/credentials/v1/errors/V1CredentialProblemReportError.d.ts +0 -10
- package/build/protocols/credentials/v1/errors/V1CredentialProblemReportError.js +0 -18
- package/build/protocols/credentials/v1/errors/V1CredentialProblemReportError.js.map +0 -1
- package/build/protocols/credentials/v1/errors/index.d.ts +0 -1
- package/build/protocols/credentials/v1/errors/index.js +0 -6
- package/build/protocols/credentials/v1/errors/index.js.map +0 -1
- package/build/protocols/credentials/v1/handlers/V1CredentialAckHandler.d.ts +0 -9
- package/build/protocols/credentials/v1/handlers/V1CredentialAckHandler.js +0 -15
- package/build/protocols/credentials/v1/handlers/V1CredentialAckHandler.js.map +0 -1
- package/build/protocols/credentials/v1/handlers/V1CredentialProblemReportHandler.d.ts +0 -9
- package/build/protocols/credentials/v1/handlers/V1CredentialProblemReportHandler.js +0 -15
- package/build/protocols/credentials/v1/handlers/V1CredentialProblemReportHandler.js.map +0 -1
- package/build/protocols/credentials/v1/handlers/V1IssueCredentialHandler.d.ts +0 -10
- package/build/protocols/credentials/v1/handlers/V1IssueCredentialHandler.js +0 -40
- package/build/protocols/credentials/v1/handlers/V1IssueCredentialHandler.js.map +0 -1
- package/build/protocols/credentials/v1/handlers/V1OfferCredentialHandler.d.ts +0 -10
- package/build/protocols/credentials/v1/handlers/V1OfferCredentialHandler.js +0 -33
- package/build/protocols/credentials/v1/handlers/V1OfferCredentialHandler.js.map +0 -1
- package/build/protocols/credentials/v1/handlers/V1ProposeCredentialHandler.d.ts +0 -10
- package/build/protocols/credentials/v1/handlers/V1ProposeCredentialHandler.js +0 -38
- package/build/protocols/credentials/v1/handlers/V1ProposeCredentialHandler.js.map +0 -1
- package/build/protocols/credentials/v1/handlers/V1RequestCredentialHandler.d.ts +0 -10
- package/build/protocols/credentials/v1/handlers/V1RequestCredentialHandler.js +0 -40
- package/build/protocols/credentials/v1/handlers/V1RequestCredentialHandler.js.map +0 -1
- package/build/protocols/credentials/v1/handlers/index.d.ts +0 -6
- package/build/protocols/credentials/v1/handlers/index.js +0 -23
- package/build/protocols/credentials/v1/handlers/index.js.map +0 -1
- package/build/protocols/credentials/v1/index.d.ts +0 -2
- package/build/protocols/credentials/v1/index.js +0 -19
- package/build/protocols/credentials/v1/index.js.map +0 -1
- package/build/protocols/credentials/v1/messages/V1CredentialAckMessage.d.ts +0 -16
- package/build/protocols/credentials/v1/messages/V1CredentialAckMessage.js +0 -34
- package/build/protocols/credentials/v1/messages/V1CredentialAckMessage.js.map +0 -1
- package/build/protocols/credentials/v1/messages/V1CredentialPreview.d.ts +0 -26
- package/build/protocols/credentials/v1/messages/V1CredentialPreview.js +0 -69
- package/build/protocols/credentials/v1/messages/V1CredentialPreview.js.map +0 -1
- package/build/protocols/credentials/v1/messages/V1CredentialProblemReportMessage.d.ts +0 -16
- package/build/protocols/credentials/v1/messages/V1CredentialProblemReportMessage.js +0 -34
- package/build/protocols/credentials/v1/messages/V1CredentialProblemReportMessage.js.map +0 -1
- package/build/protocols/credentials/v1/messages/V1IssueCredentialMessage.d.ts +0 -19
- package/build/protocols/credentials/v1/messages/V1IssueCredentialMessage.js +0 -62
- package/build/protocols/credentials/v1/messages/V1IssueCredentialMessage.js.map +0 -1
- package/build/protocols/credentials/v1/messages/V1OfferCredentialMessage.d.ts +0 -27
- package/build/protocols/credentials/v1/messages/V1OfferCredentialMessage.js +0 -75
- package/build/protocols/credentials/v1/messages/V1OfferCredentialMessage.js.map +0 -1
- package/build/protocols/credentials/v1/messages/V1ProposeCredentialMessage.d.ts +0 -59
- package/build/protocols/credentials/v1/messages/V1ProposeCredentialMessage.js +0 -109
- package/build/protocols/credentials/v1/messages/V1ProposeCredentialMessage.js.map +0 -1
- package/build/protocols/credentials/v1/messages/V1RequestCredentialMessage.d.ts +0 -19
- package/build/protocols/credentials/v1/messages/V1RequestCredentialMessage.js +0 -61
- package/build/protocols/credentials/v1/messages/V1RequestCredentialMessage.js.map +0 -1
- package/build/protocols/credentials/v1/messages/index.d.ts +0 -7
- package/build/protocols/credentials/v1/messages/index.js +0 -24
- package/build/protocols/credentials/v1/messages/index.js.map +0 -1
- package/build/protocols/index.d.ts +0 -2
- package/build/protocols/index.js +0 -19
- package/build/protocols/index.js.map +0 -1
- package/build/protocols/proofs/v1/V1ProofProtocol.d.ts +0 -50
- package/build/protocols/proofs/v1/V1ProofProtocol.js +0 -864
- package/build/protocols/proofs/v1/V1ProofProtocol.js.map +0 -1
- package/build/protocols/proofs/v1/errors/V1PresentationProblemReportError.d.ts +0 -12
- package/build/protocols/proofs/v1/errors/V1PresentationProblemReportError.js +0 -19
- package/build/protocols/proofs/v1/errors/V1PresentationProblemReportError.js.map +0 -1
- package/build/protocols/proofs/v1/errors/index.d.ts +0 -1
- package/build/protocols/proofs/v1/errors/index.js +0 -18
- package/build/protocols/proofs/v1/errors/index.js.map +0 -1
- package/build/protocols/proofs/v1/handlers/V1PresentationAckHandler.d.ts +0 -9
- package/build/protocols/proofs/v1/handlers/V1PresentationAckHandler.js +0 -15
- package/build/protocols/proofs/v1/handlers/V1PresentationAckHandler.js.map +0 -1
- package/build/protocols/proofs/v1/handlers/V1PresentationHandler.d.ts +0 -10
- package/build/protocols/proofs/v1/handlers/V1PresentationHandler.js +0 -40
- package/build/protocols/proofs/v1/handlers/V1PresentationHandler.js.map +0 -1
- package/build/protocols/proofs/v1/handlers/V1PresentationProblemReportHandler.d.ts +0 -9
- package/build/protocols/proofs/v1/handlers/V1PresentationProblemReportHandler.js +0 -15
- package/build/protocols/proofs/v1/handlers/V1PresentationProblemReportHandler.js.map +0 -1
- package/build/protocols/proofs/v1/handlers/V1ProposePresentationHandler.d.ts +0 -11
- package/build/protocols/proofs/v1/handlers/V1ProposePresentationHandler.js +0 -38
- package/build/protocols/proofs/v1/handlers/V1ProposePresentationHandler.js.map +0 -1
- package/build/protocols/proofs/v1/handlers/V1RequestPresentationHandler.d.ts +0 -10
- package/build/protocols/proofs/v1/handlers/V1RequestPresentationHandler.js +0 -35
- package/build/protocols/proofs/v1/handlers/V1RequestPresentationHandler.js.map +0 -1
- package/build/protocols/proofs/v1/handlers/index.d.ts +0 -5
- package/build/protocols/proofs/v1/handlers/index.js +0 -22
- package/build/protocols/proofs/v1/handlers/index.js.map +0 -1
- package/build/protocols/proofs/v1/index.d.ts +0 -4
- package/build/protocols/proofs/v1/index.js +0 -21
- package/build/protocols/proofs/v1/index.js.map +0 -1
- package/build/protocols/proofs/v1/messages/V1PresentationAckMessage.d.ts +0 -8
- package/build/protocols/proofs/v1/messages/V1PresentationAckMessage.js +0 -27
- package/build/protocols/proofs/v1/messages/V1PresentationAckMessage.js.map +0 -1
- package/build/protocols/proofs/v1/messages/V1PresentationMessage.d.ts +0 -31
- package/build/protocols/proofs/v1/messages/V1PresentationMessage.js +0 -67
- package/build/protocols/proofs/v1/messages/V1PresentationMessage.js.map +0 -1
- package/build/protocols/proofs/v1/messages/V1PresentationProblemReportMessage.d.ts +0 -16
- package/build/protocols/proofs/v1/messages/V1PresentationProblemReportMessage.js +0 -34
- package/build/protocols/proofs/v1/messages/V1PresentationProblemReportMessage.js.map +0 -1
- package/build/protocols/proofs/v1/messages/V1ProposePresentationMessage.d.ts +0 -26
- package/build/protocols/proofs/v1/messages/V1ProposePresentationMessage.js +0 -53
- package/build/protocols/proofs/v1/messages/V1ProposePresentationMessage.js.map +0 -1
- package/build/protocols/proofs/v1/messages/V1RequestPresentationMessage.d.ts +0 -29
- package/build/protocols/proofs/v1/messages/V1RequestPresentationMessage.js +0 -65
- package/build/protocols/proofs/v1/messages/V1RequestPresentationMessage.js.map +0 -1
- package/build/protocols/proofs/v1/messages/index.d.ts +0 -5
- package/build/protocols/proofs/v1/messages/index.js +0 -22
- package/build/protocols/proofs/v1/messages/index.js.map +0 -1
- package/build/protocols/proofs/v1/models/V1PresentationPreview.d.ts +0 -50
- package/build/protocols/proofs/v1/models/V1PresentationPreview.js +0 -130
- package/build/protocols/proofs/v1/models/V1PresentationPreview.js.map +0 -1
- package/build/protocols/proofs/v1/models/index.d.ts +0 -1
- package/build/protocols/proofs/v1/models/index.js +0 -18
- package/build/protocols/proofs/v1/models/index.js.map +0 -1
- package/build/repository/AnonCredsCredentialDefinitionPrivateRecord.d.ts +0 -21
- package/build/repository/AnonCredsCredentialDefinitionPrivateRecord.js +0 -23
- package/build/repository/AnonCredsCredentialDefinitionPrivateRecord.js.map +0 -1
- package/build/repository/AnonCredsCredentialDefinitionPrivateRepository.d.ts +0 -8
- package/build/repository/AnonCredsCredentialDefinitionPrivateRepository.js +0 -35
- package/build/repository/AnonCredsCredentialDefinitionPrivateRepository.js.map +0 -1
- package/build/repository/AnonCredsCredentialDefinitionRecord.d.ts +0 -39
- package/build/repository/AnonCredsCredentialDefinitionRecord.js +0 -30
- package/build/repository/AnonCredsCredentialDefinitionRecord.js.map +0 -1
- package/build/repository/AnonCredsCredentialDefinitionRepository.d.ts +0 -8
- package/build/repository/AnonCredsCredentialDefinitionRepository.js +0 -53
- package/build/repository/AnonCredsCredentialDefinitionRepository.js.map +0 -1
- package/build/repository/AnonCredsCredentialRecord.d.ts +0 -48
- package/build/repository/AnonCredsCredentialRecord.js +0 -37
- package/build/repository/AnonCredsCredentialRecord.js.map +0 -1
- package/build/repository/AnonCredsCredentialRepository.d.ts +0 -10
- package/build/repository/AnonCredsCredentialRepository.js +0 -41
- package/build/repository/AnonCredsCredentialRepository.js.map +0 -1
- package/build/repository/AnonCredsKeyCorrectnessProofRecord.d.ts +0 -21
- package/build/repository/AnonCredsKeyCorrectnessProofRecord.js +0 -23
- package/build/repository/AnonCredsKeyCorrectnessProofRecord.js.map +0 -1
- package/build/repository/AnonCredsKeyCorrectnessProofRepository.d.ts +0 -8
- package/build/repository/AnonCredsKeyCorrectnessProofRepository.js +0 -35
- package/build/repository/AnonCredsKeyCorrectnessProofRepository.js.map +0 -1
- package/build/repository/AnonCredsLinkSecretRecord.d.ts +0 -23
- package/build/repository/AnonCredsLinkSecretRecord.js +0 -22
- package/build/repository/AnonCredsLinkSecretRecord.js.map +0 -1
- package/build/repository/AnonCredsLinkSecretRepository.d.ts +0 -10
- package/build/repository/AnonCredsLinkSecretRepository.js +0 -41
- package/build/repository/AnonCredsLinkSecretRepository.js.map +0 -1
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRecord.d.ts +0 -34
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRecord.js +0 -30
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRecord.js.map +0 -1
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRepository.d.ts +0 -10
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRepository.js +0 -38
- package/build/repository/AnonCredsRevocationRegistryDefinitionPrivateRepository.js.map +0 -1
- package/build/repository/AnonCredsRevocationRegistryDefinitionRecord.d.ts +0 -25
- package/build/repository/AnonCredsRevocationRegistryDefinitionRecord.js +0 -23
- package/build/repository/AnonCredsRevocationRegistryDefinitionRecord.js.map +0 -1
- package/build/repository/AnonCredsRevocationRegistryDefinitionRepository.d.ts +0 -9
- package/build/repository/AnonCredsRevocationRegistryDefinitionRepository.js +0 -38
- package/build/repository/AnonCredsRevocationRegistryDefinitionRepository.js.map +0 -1
- package/build/repository/AnonCredsSchemaRecord.d.ts +0 -39
- package/build/repository/AnonCredsSchemaRecord.js +0 -30
- package/build/repository/AnonCredsSchemaRecord.js.map +0 -1
- package/build/repository/AnonCredsSchemaRepository.d.ts +0 -8
- package/build/repository/AnonCredsSchemaRepository.js +0 -53
- package/build/repository/AnonCredsSchemaRepository.js.map +0 -1
- package/build/repository/anonCredsCredentialDefinitionRecordMetadataTypes.d.ts +0 -9
- package/build/repository/anonCredsCredentialDefinitionRecordMetadataTypes.js +0 -9
- package/build/repository/anonCredsCredentialDefinitionRecordMetadataTypes.js.map +0 -1
- package/build/repository/anonCredsRevocationRegistryDefinitionRecordMetadataTypes.d.ts +0 -9
- package/build/repository/anonCredsRevocationRegistryDefinitionRecordMetadataTypes.js +0 -9
- package/build/repository/anonCredsRevocationRegistryDefinitionRecordMetadataTypes.js.map +0 -1
- package/build/repository/anonCredsSchemaRecordMetadataTypes.d.ts +0 -9
- package/build/repository/anonCredsSchemaRecordMetadataTypes.js +0 -9
- package/build/repository/anonCredsSchemaRecordMetadataTypes.js.map +0 -1
- package/build/repository/index.d.ts +0 -16
- package/build/repository/index.js +0 -33
- package/build/repository/index.js.map +0 -1
- package/build/services/AnonCredsHolderService.d.ts +0 -18
- package/build/services/AnonCredsHolderService.js +0 -5
- package/build/services/AnonCredsHolderService.js.map +0 -1
- package/build/services/AnonCredsHolderServiceOptions.d.ts +0 -101
- package/build/services/AnonCredsHolderServiceOptions.js +0 -3
- package/build/services/AnonCredsHolderServiceOptions.js.map +0 -1
- package/build/services/AnonCredsIssuerService.d.ts +0 -14
- package/build/services/AnonCredsIssuerService.js +0 -5
- package/build/services/AnonCredsIssuerService.js.map +0 -1
- package/build/services/AnonCredsIssuerServiceOptions.d.ts +0 -61
- package/build/services/AnonCredsIssuerServiceOptions.js +0 -3
- package/build/services/AnonCredsIssuerServiceOptions.js.map +0 -1
- package/build/services/AnonCredsVerifierService.d.ts +0 -7
- package/build/services/AnonCredsVerifierService.js +0 -5
- package/build/services/AnonCredsVerifierService.js.map +0 -1
- package/build/services/AnonCredsVerifierServiceOptions.d.ts +0 -25
- package/build/services/AnonCredsVerifierServiceOptions.js +0 -3
- package/build/services/AnonCredsVerifierServiceOptions.js.map +0 -1
- package/build/services/index.d.ts +0 -8
- package/build/services/index.js +0 -27
- package/build/services/index.js.map +0 -1
- package/build/services/registry/AnonCredsRegistry.d.ts +0 -25
- package/build/services/registry/AnonCredsRegistry.js +0 -3
- package/build/services/registry/AnonCredsRegistry.js.map +0 -1
- package/build/services/registry/AnonCredsRegistryService.d.ts +0 -10
- package/build/services/registry/AnonCredsRegistryService.js +0 -33
- package/build/services/registry/AnonCredsRegistryService.js.map +0 -1
- package/build/services/registry/CredentialDefinitionOptions.d.ts +0 -34
- package/build/services/registry/CredentialDefinitionOptions.js +0 -3
- package/build/services/registry/CredentialDefinitionOptions.js.map +0 -1
- package/build/services/registry/RevocationRegistryDefinitionOptions.d.ts +0 -34
- package/build/services/registry/RevocationRegistryDefinitionOptions.js +0 -3
- package/build/services/registry/RevocationRegistryDefinitionOptions.js.map +0 -1
- package/build/services/registry/RevocationStatusListOptions.d.ts +0 -32
- package/build/services/registry/RevocationStatusListOptions.js +0 -3
- package/build/services/registry/RevocationStatusListOptions.js.map +0 -1
- package/build/services/registry/SchemaOptions.d.ts +0 -34
- package/build/services/registry/SchemaOptions.js +0 -3
- package/build/services/registry/SchemaOptions.js.map +0 -1
- package/build/services/registry/base.d.ts +0 -19
- package/build/services/registry/base.js +0 -3
- package/build/services/registry/base.js.map +0 -1
- package/build/services/registry/index.d.ts +0 -7
- package/build/services/registry/index.js +0 -23
- package/build/services/registry/index.js.map +0 -1
- package/build/services/tails/BasicTailsFileService.d.ts +0 -23
- package/build/services/tails/BasicTailsFileService.js +0 -65
- package/build/services/tails/BasicTailsFileService.js.map +0 -1
- package/build/services/tails/TailsFileService.d.ts +0 -42
- package/build/services/tails/TailsFileService.js +0 -3
- package/build/services/tails/TailsFileService.js.map +0 -1
- package/build/services/tails/index.d.ts +0 -2
- package/build/services/tails/index.js +0 -19
- package/build/services/tails/index.js.map +0 -1
- package/build/updates/0.3.1-0.4/credentialDefinition.d.ts +0 -18
- package/build/updates/0.3.1-0.4/credentialDefinition.js +0 -56
- package/build/updates/0.3.1-0.4/credentialDefinition.js.map +0 -1
- package/build/updates/0.3.1-0.4/credentialExchangeRecord.d.ts +0 -69
- package/build/updates/0.3.1-0.4/credentialExchangeRecord.js +0 -121
- package/build/updates/0.3.1-0.4/credentialExchangeRecord.js.map +0 -1
- package/build/updates/0.3.1-0.4/index.d.ts +0 -2
- package/build/updates/0.3.1-0.4/index.js +0 -14
- package/build/updates/0.3.1-0.4/index.js.map +0 -1
- package/build/updates/0.3.1-0.4/linkSecret.d.ts +0 -6
- package/build/updates/0.3.1-0.4/linkSecret.js +0 -35
- package/build/updates/0.3.1-0.4/linkSecret.js.map +0 -1
- package/build/updates/0.3.1-0.4/schema.d.ts +0 -15
- package/build/updates/0.3.1-0.4/schema.js +0 -41
- package/build/updates/0.3.1-0.4/schema.js.map +0 -1
- package/build/updates/0.4-0.5/anonCredsCredentialRecord.d.ts +0 -5
- package/build/updates/0.4-0.5/anonCredsCredentialRecord.js +0 -149
- package/build/updates/0.4-0.5/anonCredsCredentialRecord.js.map +0 -1
- package/build/updates/0.4-0.5/index.d.ts +0 -2
- package/build/updates/0.4-0.5/index.js +0 -8
- package/build/updates/0.4-0.5/index.js.map +0 -1
- package/build/utils/anonCredsObjects.d.ts +0 -26
- package/build/utils/anonCredsObjects.js +0 -81
- package/build/utils/anonCredsObjects.js.map +0 -1
- package/build/utils/areRequestsEqual.d.ts +0 -6
- package/build/utils/areRequestsEqual.js +0 -135
- package/build/utils/areRequestsEqual.js.map +0 -1
- package/build/utils/composeAutoAccept.d.ts +0 -15
- package/build/utils/composeAutoAccept.js +0 -26
- package/build/utils/composeAutoAccept.js.map +0 -1
- package/build/utils/createRequestFromPreview.d.ts +0 -10
- package/build/utils/createRequestFromPreview.js +0 -71
- package/build/utils/createRequestFromPreview.js.map +0 -1
- package/build/utils/credential.d.ts +0 -68
- package/build/utils/credential.js +0 -188
- package/build/utils/credential.js.map +0 -1
- package/build/utils/credentialPreviewAttributes.d.ts +0 -2
- package/build/utils/credentialPreviewAttributes.js +0 -24
- package/build/utils/credentialPreviewAttributes.js.map +0 -1
- package/build/utils/getCredentialsForAnonCredsRequest.d.ts +0 -4
- package/build/utils/getCredentialsForAnonCredsRequest.js +0 -81
- package/build/utils/getCredentialsForAnonCredsRequest.js.map +0 -1
- package/build/utils/getRevocationRegistries.d.ts +0 -14
- package/build/utils/getRevocationRegistries.js +0 -151
- package/build/utils/getRevocationRegistries.js.map +0 -1
- package/build/utils/hasDuplicateGroupNames.d.ts +0 -2
- package/build/utils/hasDuplicateGroupNames.js +0 -22
- package/build/utils/hasDuplicateGroupNames.js.map +0 -1
- package/build/utils/index.d.ts +0 -17
- package/build/utils/index.js +0 -48
- package/build/utils/index.js.map +0 -1
- package/build/utils/indyIdentifiers.d.ts +0 -66
- package/build/utils/indyIdentifiers.js +0 -298
- package/build/utils/indyIdentifiers.js.map +0 -1
- package/build/utils/isMap.d.ts +0 -5
- package/build/utils/isMap.js +0 -17
- package/build/utils/isMap.js.map +0 -1
- package/build/utils/linkSecret.d.ts +0 -9
- package/build/utils/linkSecret.js +0 -43
- package/build/utils/linkSecret.js.map +0 -1
- package/build/utils/metadata.d.ts +0 -35
- package/build/utils/metadata.js +0 -24
- package/build/utils/metadata.js.map +0 -1
- package/build/utils/proofRequest.d.ts +0 -2
- package/build/utils/proofRequest.js +0 -21
- package/build/utils/proofRequest.js.map +0 -1
- package/build/utils/proverDid.d.ts +0 -8
- package/build/utils/proverDid.js +0 -15
- package/build/utils/proverDid.js.map +0 -1
- package/build/utils/revocationInterval.d.ts +0 -7
- package/build/utils/revocationInterval.js +0 -14
- package/build/utils/revocationInterval.js.map +0 -1
- package/build/utils/sortRequestedCredentialsMatches.d.ts +0 -8
- package/build/utils/sortRequestedCredentialsMatches.js +0 -31
- package/build/utils/sortRequestedCredentialsMatches.js.map +0 -1
- package/build/utils/timestamp.d.ts +0 -1
- package/build/utils/timestamp.js +0 -7
- package/build/utils/timestamp.js.map +0 -1
- package/build/utils/w3cAnonCredsUtils.d.ts +0 -37
- package/build/utils/w3cAnonCredsUtils.js +0 -132
- package/build/utils/w3cAnonCredsUtils.js.map +0 -1
|
@@ -1,433 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
-
var t = {};
|
|
4
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
-
t[p] = s[p];
|
|
6
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
-
t[p[i]] = s[p[i]];
|
|
10
|
-
}
|
|
11
|
-
return t;
|
|
12
|
-
};
|
|
13
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
-
exports.AnonCredsCredentialFormatService = void 0;
|
|
15
|
-
const core_1 = require("@credo-ts/core");
|
|
16
|
-
const AnonCredsCredentialProposal_1 = require("../models/AnonCredsCredentialProposal");
|
|
17
|
-
const repository_1 = require("../repository");
|
|
18
|
-
const services_1 = require("../services");
|
|
19
|
-
const utils_1 = require("../utils");
|
|
20
|
-
const credential_1 = require("../utils/credential");
|
|
21
|
-
const metadata_1 = require("../utils/metadata");
|
|
22
|
-
const w3cAnonCredsUtils_1 = require("../utils/w3cAnonCredsUtils");
|
|
23
|
-
const ANONCREDS_CREDENTIAL_OFFER = 'anoncreds/credential-offer@v1.0';
|
|
24
|
-
const ANONCREDS_CREDENTIAL_REQUEST = 'anoncreds/credential-request@v1.0';
|
|
25
|
-
const ANONCREDS_CREDENTIAL_FILTER = 'anoncreds/credential-filter@v1.0';
|
|
26
|
-
const ANONCREDS_CREDENTIAL = 'anoncreds/credential@v1.0';
|
|
27
|
-
class AnonCredsCredentialFormatService {
|
|
28
|
-
constructor() {
|
|
29
|
-
/** formatKey is the key used when calling agent.credentials.xxx with credentialFormats.anoncreds */
|
|
30
|
-
this.formatKey = 'anoncreds';
|
|
31
|
-
/**
|
|
32
|
-
* credentialRecordType is the type of record that stores the credential. It is stored in the credential
|
|
33
|
-
* record binding in the credential exchange record.
|
|
34
|
-
*/
|
|
35
|
-
this.credentialRecordType = 'w3c';
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Create a {@link AttachmentFormats} object dependent on the message type.
|
|
39
|
-
*
|
|
40
|
-
* @param options The object containing all the options for the proposed credential
|
|
41
|
-
* @returns object containing associated attachment, format and optionally the credential preview
|
|
42
|
-
*
|
|
43
|
-
*/
|
|
44
|
-
async createProposal(agentContext, { credentialFormats, credentialRecord }) {
|
|
45
|
-
const format = new core_1.CredentialFormatSpec({
|
|
46
|
-
format: ANONCREDS_CREDENTIAL_FILTER,
|
|
47
|
-
});
|
|
48
|
-
const anoncredsFormat = credentialFormats.anoncreds;
|
|
49
|
-
if (!anoncredsFormat) {
|
|
50
|
-
throw new core_1.CredoError('Missing anoncreds payload in createProposal');
|
|
51
|
-
}
|
|
52
|
-
// We want all properties except for `attributes` and `linkedAttachments` attributes.
|
|
53
|
-
// The easiest way is to destructure and use the spread operator. But that leaves the other properties unused
|
|
54
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
55
|
-
const { attributes, linkedAttachments } = anoncredsFormat, anoncredsCredentialProposal = __rest(anoncredsFormat, ["attributes", "linkedAttachments"]);
|
|
56
|
-
const proposal = new AnonCredsCredentialProposal_1.AnonCredsCredentialProposal(anoncredsCredentialProposal);
|
|
57
|
-
try {
|
|
58
|
-
core_1.MessageValidator.validateSync(proposal);
|
|
59
|
-
}
|
|
60
|
-
catch (error) {
|
|
61
|
-
throw new core_1.CredoError(`Invalid proposal supplied: ${anoncredsCredentialProposal} in AnonCredsFormatService`);
|
|
62
|
-
}
|
|
63
|
-
const attachment = this.getFormatData(core_1.JsonTransformer.toJSON(proposal), format.attachmentId);
|
|
64
|
-
const { previewAttributes } = this.getCredentialLinkedAttachments(anoncredsFormat.attributes, anoncredsFormat.linkedAttachments);
|
|
65
|
-
// Set the metadata
|
|
66
|
-
credentialRecord.metadata.set(metadata_1.AnonCredsCredentialMetadataKey, {
|
|
67
|
-
schemaId: proposal.schemaId,
|
|
68
|
-
credentialDefinitionId: proposal.credentialDefinitionId,
|
|
69
|
-
});
|
|
70
|
-
return { format, attachment, previewAttributes };
|
|
71
|
-
}
|
|
72
|
-
async processProposal(agentContext, { attachment }) {
|
|
73
|
-
const proposalJson = attachment.getDataAsJson();
|
|
74
|
-
core_1.JsonTransformer.fromJSON(proposalJson, AnonCredsCredentialProposal_1.AnonCredsCredentialProposal);
|
|
75
|
-
}
|
|
76
|
-
async acceptProposal(agentContext, { attachmentId, credentialFormats, credentialRecord, proposalAttachment, }) {
|
|
77
|
-
var _a, _b;
|
|
78
|
-
const anoncredsFormat = credentialFormats === null || credentialFormats === void 0 ? void 0 : credentialFormats.anoncreds;
|
|
79
|
-
const proposalJson = proposalAttachment.getDataAsJson();
|
|
80
|
-
const credentialDefinitionId = (_a = anoncredsFormat === null || anoncredsFormat === void 0 ? void 0 : anoncredsFormat.credentialDefinitionId) !== null && _a !== void 0 ? _a : proposalJson.cred_def_id;
|
|
81
|
-
const attributes = (_b = anoncredsFormat === null || anoncredsFormat === void 0 ? void 0 : anoncredsFormat.attributes) !== null && _b !== void 0 ? _b : credentialRecord.credentialAttributes;
|
|
82
|
-
if (!credentialDefinitionId) {
|
|
83
|
-
throw new core_1.CredoError('No credential definition id in proposal or provided as input to accept proposal method.');
|
|
84
|
-
}
|
|
85
|
-
if (!attributes) {
|
|
86
|
-
throw new core_1.CredoError('No attributes in proposal or provided as input to accept proposal method.');
|
|
87
|
-
}
|
|
88
|
-
const { format, attachment, previewAttributes } = await this.createAnonCredsOffer(agentContext, {
|
|
89
|
-
credentialRecord,
|
|
90
|
-
attachmentId,
|
|
91
|
-
attributes,
|
|
92
|
-
credentialDefinitionId,
|
|
93
|
-
revocationRegistryDefinitionId: anoncredsFormat === null || anoncredsFormat === void 0 ? void 0 : anoncredsFormat.revocationRegistryDefinitionId,
|
|
94
|
-
revocationRegistryIndex: anoncredsFormat === null || anoncredsFormat === void 0 ? void 0 : anoncredsFormat.revocationRegistryIndex,
|
|
95
|
-
linkedAttachments: anoncredsFormat === null || anoncredsFormat === void 0 ? void 0 : anoncredsFormat.linkedAttachments,
|
|
96
|
-
});
|
|
97
|
-
return { format, attachment, previewAttributes };
|
|
98
|
-
}
|
|
99
|
-
/**
|
|
100
|
-
* Create a credential attachment format for a credential request.
|
|
101
|
-
*
|
|
102
|
-
* @param options The object containing all the options for the credential offer
|
|
103
|
-
* @returns object containing associated attachment, formats and offersAttach elements
|
|
104
|
-
*
|
|
105
|
-
*/
|
|
106
|
-
async createOffer(agentContext, { credentialFormats, credentialRecord, attachmentId }) {
|
|
107
|
-
const anoncredsFormat = credentialFormats.anoncreds;
|
|
108
|
-
if (!anoncredsFormat) {
|
|
109
|
-
throw new core_1.CredoError('Missing anoncreds credential format data');
|
|
110
|
-
}
|
|
111
|
-
const { format, attachment, previewAttributes } = await this.createAnonCredsOffer(agentContext, {
|
|
112
|
-
credentialRecord,
|
|
113
|
-
attachmentId,
|
|
114
|
-
attributes: anoncredsFormat.attributes,
|
|
115
|
-
credentialDefinitionId: anoncredsFormat.credentialDefinitionId,
|
|
116
|
-
revocationRegistryDefinitionId: anoncredsFormat.revocationRegistryDefinitionId,
|
|
117
|
-
revocationRegistryIndex: anoncredsFormat.revocationRegistryIndex,
|
|
118
|
-
linkedAttachments: anoncredsFormat.linkedAttachments,
|
|
119
|
-
});
|
|
120
|
-
return { format, attachment, previewAttributes };
|
|
121
|
-
}
|
|
122
|
-
async processOffer(agentContext, { attachment, credentialRecord }) {
|
|
123
|
-
agentContext.config.logger.debug(`Processing anoncreds credential offer for credential record ${credentialRecord.id}`);
|
|
124
|
-
const credOffer = attachment.getDataAsJson();
|
|
125
|
-
if (!credOffer.schema_id || !credOffer.cred_def_id) {
|
|
126
|
-
throw new core_1.ProblemReportError('Invalid credential offer', {
|
|
127
|
-
problemCode: core_1.CredentialProblemReportReason.IssuanceAbandoned,
|
|
128
|
-
});
|
|
129
|
-
}
|
|
130
|
-
}
|
|
131
|
-
async acceptOffer(agentContext, { credentialRecord, attachmentId, offerAttachment, credentialFormats, }) {
|
|
132
|
-
var _a;
|
|
133
|
-
const holderService = agentContext.dependencyManager.resolve(services_1.AnonCredsHolderServiceSymbol);
|
|
134
|
-
const credentialOffer = offerAttachment.getDataAsJson();
|
|
135
|
-
// Get credential definition
|
|
136
|
-
const { credentialDefinition } = await (0, utils_1.fetchCredentialDefinition)(agentContext, credentialOffer.cred_def_id);
|
|
137
|
-
const { credentialRequest, credentialRequestMetadata } = await holderService.createCredentialRequest(agentContext, {
|
|
138
|
-
credentialOffer,
|
|
139
|
-
credentialDefinition,
|
|
140
|
-
linkSecretId: (_a = credentialFormats === null || credentialFormats === void 0 ? void 0 : credentialFormats.anoncreds) === null || _a === void 0 ? void 0 : _a.linkSecretId,
|
|
141
|
-
});
|
|
142
|
-
credentialRecord.metadata.set(metadata_1.AnonCredsCredentialRequestMetadataKey, credentialRequestMetadata);
|
|
143
|
-
credentialRecord.metadata.set(metadata_1.AnonCredsCredentialMetadataKey, {
|
|
144
|
-
credentialDefinitionId: credentialOffer.cred_def_id,
|
|
145
|
-
schemaId: credentialOffer.schema_id,
|
|
146
|
-
});
|
|
147
|
-
const format = new core_1.CredentialFormatSpec({
|
|
148
|
-
attachmentId,
|
|
149
|
-
format: ANONCREDS_CREDENTIAL_REQUEST,
|
|
150
|
-
});
|
|
151
|
-
const attachment = this.getFormatData(credentialRequest, format.attachmentId);
|
|
152
|
-
return { format, attachment };
|
|
153
|
-
}
|
|
154
|
-
/**
|
|
155
|
-
* Starting from a request is not supported for anoncreds credentials, this method only throws an error.
|
|
156
|
-
*/
|
|
157
|
-
async createRequest() {
|
|
158
|
-
throw new core_1.CredoError('Starting from a request is not supported for anoncreds credentials');
|
|
159
|
-
}
|
|
160
|
-
/**
|
|
161
|
-
* We don't have any models to validate an anoncreds request object, for now this method does nothing
|
|
162
|
-
*/
|
|
163
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
164
|
-
async processRequest(agentContext, options) {
|
|
165
|
-
// not needed for anoncreds
|
|
166
|
-
}
|
|
167
|
-
async acceptRequest(agentContext, { credentialRecord, attachmentId, offerAttachment, requestAttachment, }) {
|
|
168
|
-
// Assert credential attributes
|
|
169
|
-
const credentialAttributes = credentialRecord.credentialAttributes;
|
|
170
|
-
if (!credentialAttributes) {
|
|
171
|
-
throw new core_1.CredoError(`Missing required credential attribute values on credential record with id ${credentialRecord.id}`);
|
|
172
|
-
}
|
|
173
|
-
const anonCredsIssuerService = agentContext.dependencyManager.resolve(services_1.AnonCredsIssuerServiceSymbol);
|
|
174
|
-
const credentialOffer = offerAttachment === null || offerAttachment === void 0 ? void 0 : offerAttachment.getDataAsJson();
|
|
175
|
-
if (!credentialOffer)
|
|
176
|
-
throw new core_1.CredoError('Missing anoncreds credential offer in createCredential');
|
|
177
|
-
const credentialRequest = requestAttachment.getDataAsJson();
|
|
178
|
-
if (!credentialRequest)
|
|
179
|
-
throw new core_1.CredoError('Missing anoncreds credential request in createCredential');
|
|
180
|
-
// We check locally for credential definition info. If it supports revocation, we need to search locally for
|
|
181
|
-
// an active revocation registry
|
|
182
|
-
const credentialDefinition = (await agentContext.dependencyManager
|
|
183
|
-
.resolve(repository_1.AnonCredsCredentialDefinitionRepository)
|
|
184
|
-
.getByCredentialDefinitionId(agentContext, credentialRequest.cred_def_id)).credentialDefinition.value;
|
|
185
|
-
let revocationRegistryDefinitionId;
|
|
186
|
-
let revocationRegistryIndex;
|
|
187
|
-
let revocationStatusList;
|
|
188
|
-
if (credentialDefinition.revocation) {
|
|
189
|
-
const credentialMetadata = credentialRecord.metadata.get(metadata_1.AnonCredsCredentialMetadataKey);
|
|
190
|
-
revocationRegistryDefinitionId = credentialMetadata === null || credentialMetadata === void 0 ? void 0 : credentialMetadata.revocationRegistryId;
|
|
191
|
-
if (credentialMetadata === null || credentialMetadata === void 0 ? void 0 : credentialMetadata.credentialRevocationId) {
|
|
192
|
-
revocationRegistryIndex = Number(credentialMetadata.credentialRevocationId);
|
|
193
|
-
}
|
|
194
|
-
if (!revocationRegistryDefinitionId || revocationRegistryIndex === undefined) {
|
|
195
|
-
throw new core_1.CredoError('Revocation registry definition id and revocation index are mandatory to issue AnonCreds revocable credentials');
|
|
196
|
-
}
|
|
197
|
-
const revocationRegistryDefinitionPrivateRecord = await agentContext.dependencyManager
|
|
198
|
-
.resolve(repository_1.AnonCredsRevocationRegistryDefinitionPrivateRepository)
|
|
199
|
-
.getByRevocationRegistryDefinitionId(agentContext, revocationRegistryDefinitionId);
|
|
200
|
-
if (revocationRegistryDefinitionPrivateRecord.state !== repository_1.AnonCredsRevocationRegistryState.Active) {
|
|
201
|
-
throw new core_1.CredoError(`Revocation registry ${revocationRegistryDefinitionId} is in ${revocationRegistryDefinitionPrivateRecord.state} state`);
|
|
202
|
-
}
|
|
203
|
-
const revocationStatusListResult = await (0, utils_1.fetchRevocationStatusList)(agentContext, revocationRegistryDefinitionId, (0, utils_1.dateToTimestamp)(new Date()));
|
|
204
|
-
revocationStatusList = revocationStatusListResult.revocationStatusList;
|
|
205
|
-
}
|
|
206
|
-
const { credential, credentialRevocationId } = await anonCredsIssuerService.createCredential(agentContext, {
|
|
207
|
-
credentialOffer,
|
|
208
|
-
credentialRequest,
|
|
209
|
-
credentialValues: (0, credential_1.convertAttributesToCredentialValues)(credentialAttributes),
|
|
210
|
-
revocationRegistryDefinitionId,
|
|
211
|
-
revocationRegistryIndex,
|
|
212
|
-
revocationStatusList,
|
|
213
|
-
});
|
|
214
|
-
// If the credential is revocable, store the revocation identifiers in the credential record
|
|
215
|
-
if (credential.rev_reg_id) {
|
|
216
|
-
credentialRecord.metadata.add(metadata_1.AnonCredsCredentialMetadataKey, {
|
|
217
|
-
revocationRegistryId: revocationRegistryDefinitionId !== null && revocationRegistryDefinitionId !== void 0 ? revocationRegistryDefinitionId : undefined,
|
|
218
|
-
credentialRevocationId: credentialRevocationId !== null && credentialRevocationId !== void 0 ? credentialRevocationId : undefined,
|
|
219
|
-
});
|
|
220
|
-
credentialRecord.setTags({
|
|
221
|
-
anonCredsRevocationRegistryId: revocationRegistryDefinitionId,
|
|
222
|
-
anonCredsCredentialRevocationId: credentialRevocationId,
|
|
223
|
-
});
|
|
224
|
-
}
|
|
225
|
-
const format = new core_1.CredentialFormatSpec({
|
|
226
|
-
attachmentId,
|
|
227
|
-
format: ANONCREDS_CREDENTIAL,
|
|
228
|
-
});
|
|
229
|
-
const attachment = this.getFormatData(credential, format.attachmentId);
|
|
230
|
-
return { format, attachment };
|
|
231
|
-
}
|
|
232
|
-
/**
|
|
233
|
-
* Processes an incoming credential - retrieve metadata, retrieve payload and store it in wallet
|
|
234
|
-
* @param options the issue credential message wrapped inside this object
|
|
235
|
-
* @param credentialRecord the credential exchange record for this credential
|
|
236
|
-
*/
|
|
237
|
-
async processCredential(agentContext, { credentialRecord, attachment }) {
|
|
238
|
-
var _a, _b;
|
|
239
|
-
const credentialRequestMetadata = credentialRecord.metadata.get(metadata_1.AnonCredsCredentialRequestMetadataKey);
|
|
240
|
-
const anonCredsHolderService = agentContext.dependencyManager.resolve(services_1.AnonCredsHolderServiceSymbol);
|
|
241
|
-
if (!credentialRequestMetadata) {
|
|
242
|
-
throw new core_1.CredoError(`Missing required request metadata for credential exchange with thread id with id ${credentialRecord.id}`);
|
|
243
|
-
}
|
|
244
|
-
if (!credentialRecord.credentialAttributes) {
|
|
245
|
-
throw new core_1.CredoError('Missing credential attributes on credential record. Unable to check credential attributes');
|
|
246
|
-
}
|
|
247
|
-
const anonCredsCredential = attachment.getDataAsJson();
|
|
248
|
-
const { credentialDefinition, credentialDefinitionId } = await (0, utils_1.fetchCredentialDefinition)(agentContext, anonCredsCredential.cred_def_id);
|
|
249
|
-
const { schema, indyNamespace } = await (0, utils_1.fetchSchema)(agentContext, anonCredsCredential.schema_id);
|
|
250
|
-
// Resolve revocation registry if credential is revocable
|
|
251
|
-
const revocationRegistryResult = anonCredsCredential.rev_reg_id
|
|
252
|
-
? await (0, utils_1.fetchRevocationRegistryDefinition)(agentContext, anonCredsCredential.rev_reg_id)
|
|
253
|
-
: undefined;
|
|
254
|
-
// assert the credential values match the offer values
|
|
255
|
-
const recordCredentialValues = (0, credential_1.convertAttributesToCredentialValues)(credentialRecord.credentialAttributes);
|
|
256
|
-
(0, credential_1.assertCredentialValuesMatch)(anonCredsCredential.values, recordCredentialValues);
|
|
257
|
-
const storeCredentialOptions = (0, w3cAnonCredsUtils_1.getStoreCredentialOptions)({
|
|
258
|
-
credentialId: core_1.utils.uuid(),
|
|
259
|
-
credentialRequestMetadata,
|
|
260
|
-
credential: anonCredsCredential,
|
|
261
|
-
credentialDefinitionId,
|
|
262
|
-
credentialDefinition,
|
|
263
|
-
schema,
|
|
264
|
-
revocationRegistry: (revocationRegistryResult === null || revocationRegistryResult === void 0 ? void 0 : revocationRegistryResult.revocationRegistryDefinition)
|
|
265
|
-
? {
|
|
266
|
-
definition: revocationRegistryResult.revocationRegistryDefinition,
|
|
267
|
-
id: revocationRegistryResult.revocationRegistryDefinitionId,
|
|
268
|
-
}
|
|
269
|
-
: undefined,
|
|
270
|
-
}, indyNamespace);
|
|
271
|
-
const credentialId = await anonCredsHolderService.storeCredential(agentContext, storeCredentialOptions);
|
|
272
|
-
// If the credential is revocable, store the revocation identifiers in the credential record
|
|
273
|
-
if (anonCredsCredential.rev_reg_id) {
|
|
274
|
-
const credential = await anonCredsHolderService.getCredential(agentContext, { id: credentialId });
|
|
275
|
-
credentialRecord.metadata.add(metadata_1.AnonCredsCredentialMetadataKey, {
|
|
276
|
-
credentialRevocationId: (_a = credential.credentialRevocationId) !== null && _a !== void 0 ? _a : undefined,
|
|
277
|
-
revocationRegistryId: (_b = credential.revocationRegistryId) !== null && _b !== void 0 ? _b : undefined,
|
|
278
|
-
});
|
|
279
|
-
credentialRecord.setTags({
|
|
280
|
-
anonCredsRevocationRegistryId: credential.revocationRegistryId,
|
|
281
|
-
anonCredsCredentialRevocationId: credential.credentialRevocationId,
|
|
282
|
-
});
|
|
283
|
-
}
|
|
284
|
-
credentialRecord.credentials.push({
|
|
285
|
-
credentialRecordType: this.credentialRecordType,
|
|
286
|
-
credentialRecordId: credentialId,
|
|
287
|
-
});
|
|
288
|
-
}
|
|
289
|
-
supportsFormat(format) {
|
|
290
|
-
const supportedFormats = [
|
|
291
|
-
ANONCREDS_CREDENTIAL_REQUEST,
|
|
292
|
-
ANONCREDS_CREDENTIAL_OFFER,
|
|
293
|
-
ANONCREDS_CREDENTIAL_FILTER,
|
|
294
|
-
ANONCREDS_CREDENTIAL,
|
|
295
|
-
];
|
|
296
|
-
return supportedFormats.includes(format);
|
|
297
|
-
}
|
|
298
|
-
/**
|
|
299
|
-
* Gets the attachment object for a given attachmentId. We need to get out the correct attachmentId for
|
|
300
|
-
* anoncreds and then find the corresponding attachment (if there is one)
|
|
301
|
-
* @param formats the formats object containing the attachmentId
|
|
302
|
-
* @param messageAttachments the attachments containing the payload
|
|
303
|
-
* @returns The Attachment if found or undefined
|
|
304
|
-
*
|
|
305
|
-
*/
|
|
306
|
-
getAttachment(formats, messageAttachments) {
|
|
307
|
-
const supportedAttachmentIds = formats.filter((f) => this.supportsFormat(f.format)).map((f) => f.attachmentId);
|
|
308
|
-
const supportedAttachment = messageAttachments.find((attachment) => supportedAttachmentIds.includes(attachment.id));
|
|
309
|
-
return supportedAttachment;
|
|
310
|
-
}
|
|
311
|
-
async deleteCredentialById(agentContext, credentialRecordId) {
|
|
312
|
-
const anonCredsHolderService = agentContext.dependencyManager.resolve(services_1.AnonCredsHolderServiceSymbol);
|
|
313
|
-
await anonCredsHolderService.deleteCredential(agentContext, credentialRecordId);
|
|
314
|
-
}
|
|
315
|
-
async shouldAutoRespondToProposal(agentContext, { offerAttachment, proposalAttachment }) {
|
|
316
|
-
const proposalJson = proposalAttachment.getDataAsJson();
|
|
317
|
-
const offerJson = offerAttachment.getDataAsJson();
|
|
318
|
-
// We want to make sure the credential definition matches.
|
|
319
|
-
// TODO: If no credential definition is present on the proposal, we could check whether the other fields
|
|
320
|
-
// of the proposal match with the credential definition id.
|
|
321
|
-
return proposalJson.cred_def_id === offerJson.cred_def_id;
|
|
322
|
-
}
|
|
323
|
-
async shouldAutoRespondToOffer(agentContext, { offerAttachment, proposalAttachment }) {
|
|
324
|
-
const proposalJson = proposalAttachment.getDataAsJson();
|
|
325
|
-
const offerJson = offerAttachment.getDataAsJson();
|
|
326
|
-
// We want to make sure the credential definition matches.
|
|
327
|
-
// TODO: If no credential definition is present on the proposal, we could check whether the other fields
|
|
328
|
-
// of the proposal match with the credential definition id.
|
|
329
|
-
return proposalJson.cred_def_id === offerJson.cred_def_id;
|
|
330
|
-
}
|
|
331
|
-
async shouldAutoRespondToRequest(agentContext, { offerAttachment, requestAttachment }) {
|
|
332
|
-
const credentialOfferJson = offerAttachment.getDataAsJson();
|
|
333
|
-
const credentialRequestJson = requestAttachment.getDataAsJson();
|
|
334
|
-
return credentialOfferJson.cred_def_id === credentialRequestJson.cred_def_id;
|
|
335
|
-
}
|
|
336
|
-
async shouldAutoRespondToCredential(agentContext, { credentialRecord, requestAttachment, credentialAttachment }) {
|
|
337
|
-
const credentialJson = credentialAttachment.getDataAsJson();
|
|
338
|
-
const credentialRequestJson = requestAttachment.getDataAsJson();
|
|
339
|
-
// make sure the credential definition matches
|
|
340
|
-
if (credentialJson.cred_def_id !== credentialRequestJson.cred_def_id)
|
|
341
|
-
return false;
|
|
342
|
-
// If we don't have any attributes stored we can't compare so always return false.
|
|
343
|
-
if (!credentialRecord.credentialAttributes)
|
|
344
|
-
return false;
|
|
345
|
-
const attributeValues = (0, credential_1.convertAttributesToCredentialValues)(credentialRecord.credentialAttributes);
|
|
346
|
-
// check whether the values match the values in the record
|
|
347
|
-
return (0, credential_1.checkCredentialValuesMatch)(attributeValues, credentialJson.values);
|
|
348
|
-
}
|
|
349
|
-
async createAnonCredsOffer(agentContext, { credentialRecord, attachmentId, credentialDefinitionId, revocationRegistryDefinitionId, revocationRegistryIndex, attributes, linkedAttachments, }) {
|
|
350
|
-
const anonCredsIssuerService = agentContext.dependencyManager.resolve(services_1.AnonCredsIssuerServiceSymbol);
|
|
351
|
-
// if the proposal has an attachment Id use that, otherwise the generated id of the formats object
|
|
352
|
-
const format = new core_1.CredentialFormatSpec({
|
|
353
|
-
attachmentId: attachmentId,
|
|
354
|
-
format: ANONCREDS_CREDENTIAL,
|
|
355
|
-
});
|
|
356
|
-
const offer = await anonCredsIssuerService.createCredentialOffer(agentContext, {
|
|
357
|
-
credentialDefinitionId,
|
|
358
|
-
});
|
|
359
|
-
const { previewAttributes } = this.getCredentialLinkedAttachments(attributes, linkedAttachments);
|
|
360
|
-
if (!previewAttributes) {
|
|
361
|
-
throw new core_1.CredoError('Missing required preview attributes for anoncreds offer');
|
|
362
|
-
}
|
|
363
|
-
await this.assertPreviewAttributesMatchSchemaAttributes(agentContext, offer, previewAttributes);
|
|
364
|
-
// We check locally for credential definition info. If it supports revocation, revocationRegistryIndex
|
|
365
|
-
// and revocationRegistryDefinitionId are mandatory
|
|
366
|
-
const credentialDefinition = (await agentContext.dependencyManager
|
|
367
|
-
.resolve(repository_1.AnonCredsCredentialDefinitionRepository)
|
|
368
|
-
.getByCredentialDefinitionId(agentContext, offer.cred_def_id)).credentialDefinition.value;
|
|
369
|
-
if (credentialDefinition.revocation) {
|
|
370
|
-
if (!revocationRegistryDefinitionId || revocationRegistryIndex === undefined) {
|
|
371
|
-
throw new core_1.CredoError('AnonCreds revocable credentials require revocationRegistryDefinitionId and revocationRegistryIndex');
|
|
372
|
-
}
|
|
373
|
-
// Set revocation tags
|
|
374
|
-
credentialRecord.setTags({
|
|
375
|
-
anonCredsRevocationRegistryId: revocationRegistryDefinitionId,
|
|
376
|
-
anonCredsCredentialRevocationId: revocationRegistryIndex.toString(),
|
|
377
|
-
});
|
|
378
|
-
}
|
|
379
|
-
// Set the metadata
|
|
380
|
-
credentialRecord.metadata.set(metadata_1.AnonCredsCredentialMetadataKey, {
|
|
381
|
-
schemaId: offer.schema_id,
|
|
382
|
-
credentialDefinitionId: offer.cred_def_id,
|
|
383
|
-
credentialRevocationId: revocationRegistryIndex === null || revocationRegistryIndex === void 0 ? void 0 : revocationRegistryIndex.toString(),
|
|
384
|
-
revocationRegistryId: revocationRegistryDefinitionId,
|
|
385
|
-
});
|
|
386
|
-
const attachment = this.getFormatData(offer, format.attachmentId);
|
|
387
|
-
return { format, attachment, previewAttributes };
|
|
388
|
-
}
|
|
389
|
-
async assertPreviewAttributesMatchSchemaAttributes(agentContext, offer, attributes) {
|
|
390
|
-
const { schema } = await (0, utils_1.fetchSchema)(agentContext, offer.schema_id);
|
|
391
|
-
(0, credential_1.assertAttributesMatch)(schema, attributes);
|
|
392
|
-
}
|
|
393
|
-
/**
|
|
394
|
-
* Get linked attachments for anoncreds format from a proposal message. This allows attachments
|
|
395
|
-
* to be copied across to old style credential records
|
|
396
|
-
*
|
|
397
|
-
* @param options ProposeCredentialOptions object containing (optionally) the linked attachments
|
|
398
|
-
* @return array of linked attachments or undefined if none present
|
|
399
|
-
*/
|
|
400
|
-
getCredentialLinkedAttachments(attributes, linkedAttachments) {
|
|
401
|
-
if (!linkedAttachments && !attributes) {
|
|
402
|
-
return {};
|
|
403
|
-
}
|
|
404
|
-
let previewAttributes = attributes !== null && attributes !== void 0 ? attributes : [];
|
|
405
|
-
let attachments;
|
|
406
|
-
if (linkedAttachments) {
|
|
407
|
-
// there are linked attachments so transform into the attribute field of the CredentialPreview object for
|
|
408
|
-
// this proposal
|
|
409
|
-
previewAttributes = (0, credential_1.createAndLinkAttachmentsToPreview)(linkedAttachments, previewAttributes);
|
|
410
|
-
attachments = linkedAttachments.map((linkedAttachment) => linkedAttachment.attachment);
|
|
411
|
-
}
|
|
412
|
-
return { attachments, previewAttributes };
|
|
413
|
-
}
|
|
414
|
-
/**
|
|
415
|
-
* Returns an object of type {@link Attachment} for use in credential exchange messages.
|
|
416
|
-
* It looks up the correct format identifier and encodes the data as a base64 attachment.
|
|
417
|
-
*
|
|
418
|
-
* @param data The data to include in the attach object
|
|
419
|
-
* @param id the attach id from the formats component of the message
|
|
420
|
-
*/
|
|
421
|
-
getFormatData(data, id) {
|
|
422
|
-
const attachment = new core_1.Attachment({
|
|
423
|
-
id,
|
|
424
|
-
mimeType: 'application/json',
|
|
425
|
-
data: {
|
|
426
|
-
base64: core_1.JsonEncoder.toBase64(data),
|
|
427
|
-
},
|
|
428
|
-
});
|
|
429
|
-
return attachment;
|
|
430
|
-
}
|
|
431
|
-
}
|
|
432
|
-
exports.AnonCredsCredentialFormatService = AnonCredsCredentialFormatService;
|
|
433
|
-
//# sourceMappingURL=AnonCredsCredentialFormatService.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AnonCredsCredentialFormatService.js","sourceRoot":"","sources":["../../src/formats/AnonCredsCredentialFormatService.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AA0BA,yCAUuB;AAEvB,uFAAmF;AACnF,8CAIsB;AACtB,0CAAwF;AACxF,oCAMiB;AACjB,oDAM4B;AAC5B,gDAAyG;AACzG,kEAAsE;AAEtE,MAAM,0BAA0B,GAAG,iCAAiC,CAAA;AACpE,MAAM,4BAA4B,GAAG,mCAAmC,CAAA;AACxE,MAAM,2BAA2B,GAAG,kCAAkC,CAAA;AACtE,MAAM,oBAAoB,GAAG,2BAA2B,CAAA;AAExD,MAAa,gCAAgC;IAA7C;QACE,oGAAoG;QACpF,cAAS,GAAG,WAAoB,CAAA;QAEhD;;;WAGG;QACa,yBAAoB,GAAG,KAAc,CAAA;IA0lBvD,CAAC;IAxlBC;;;;;;OAMG;IACI,KAAK,CAAC,cAAc,CACzB,YAA0B,EAC1B,EAAE,iBAAiB,EAAE,gBAAgB,EAAoE;QAEzG,MAAM,MAAM,GAAG,IAAI,2BAAoB,CAAC;YACtC,MAAM,EAAE,2BAA2B;SACpC,CAAC,CAAA;QAEF,MAAM,eAAe,GAAG,iBAAiB,CAAC,SAAS,CAAA;QAEnD,IAAI,CAAC,eAAe,EAAE,CAAC;YACrB,MAAM,IAAI,iBAAU,CAAC,6CAA6C,CAAC,CAAA;QACrE,CAAC;QAED,qFAAqF;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WAAW,EAAE,iBAAiB,EAAE,CAAA;IAC3C,CAAC;IAED;;;;;;OAMG;IACI,aAAa,CAAC,IAAa,EAAE,EAAU;QAC5C,MAAM,UAAU,GAAG,IAAI,iBAAU,CAAC;YAChC,EAAE;YACF,QAAQ,EAAE,kBAAkB;YAC5B,IAAI,EAAE;gBACJ,MAAM,EAAE,kBAAW,CAAC,QAAQ,CAAC,IAAI,CAAC;aACnC;SACF,CAAC,CAAA;QAEF,OAAO,UAAU,CAAA;IACnB,CAAC;CACF;AAlmBD,4EAkmBC"}
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import type { AnonCredsNonRevokedInterval, AnonCredsPredicateType, AnonCredsProof, AnonCredsProofRequest, AnonCredsRequestedAttribute, AnonCredsRequestedAttributeMatch, AnonCredsRequestedPredicate, AnonCredsRequestedPredicateMatch, AnonCredsSelectedCredentials } from '../models';
|
|
2
|
-
import type { ProofFormat } from '@credo-ts/core';
|
|
3
|
-
export interface AnonCredsPresentationPreviewAttribute {
|
|
4
|
-
name: string;
|
|
5
|
-
credentialDefinitionId?: string;
|
|
6
|
-
mimeType?: string;
|
|
7
|
-
value?: string;
|
|
8
|
-
referent?: string;
|
|
9
|
-
}
|
|
10
|
-
export interface AnonCredsPresentationPreviewPredicate {
|
|
11
|
-
name: string;
|
|
12
|
-
credentialDefinitionId: string;
|
|
13
|
-
predicate: AnonCredsPredicateType;
|
|
14
|
-
threshold: number;
|
|
15
|
-
}
|
|
16
|
-
/**
|
|
17
|
-
* Interface for creating an anoncreds proof proposal.
|
|
18
|
-
*/
|
|
19
|
-
export interface AnonCredsProposeProofFormat {
|
|
20
|
-
name?: string;
|
|
21
|
-
version?: string;
|
|
22
|
-
attributes?: AnonCredsPresentationPreviewAttribute[];
|
|
23
|
-
predicates?: AnonCredsPresentationPreviewPredicate[];
|
|
24
|
-
nonRevokedInterval?: AnonCredsNonRevokedInterval;
|
|
25
|
-
}
|
|
26
|
-
/**
|
|
27
|
-
* Interface for creating an anoncreds proof request.
|
|
28
|
-
*/
|
|
29
|
-
export interface AnonCredsRequestProofFormat {
|
|
30
|
-
name: string;
|
|
31
|
-
version: string;
|
|
32
|
-
non_revoked?: AnonCredsNonRevokedInterval;
|
|
33
|
-
requested_attributes?: Record<string, AnonCredsRequestedAttribute>;
|
|
34
|
-
requested_predicates?: Record<string, AnonCredsRequestedPredicate>;
|
|
35
|
-
}
|
|
36
|
-
/**
|
|
37
|
-
* Interface for getting credentials for an indy proof request.
|
|
38
|
-
*/
|
|
39
|
-
export interface AnonCredsCredentialsForProofRequest {
|
|
40
|
-
attributes: Record<string, AnonCredsRequestedAttributeMatch[]>;
|
|
41
|
-
predicates: Record<string, AnonCredsRequestedPredicateMatch[]>;
|
|
42
|
-
}
|
|
43
|
-
export interface AnonCredsGetCredentialsForProofRequestOptions {
|
|
44
|
-
filterByNonRevocationRequirements?: boolean;
|
|
45
|
-
}
|
|
46
|
-
export interface AnonCredsProofFormat extends ProofFormat {
|
|
47
|
-
formatKey: 'anoncreds';
|
|
48
|
-
proofFormats: {
|
|
49
|
-
createProposal: AnonCredsProposeProofFormat;
|
|
50
|
-
acceptProposal: {
|
|
51
|
-
name?: string;
|
|
52
|
-
version?: string;
|
|
53
|
-
};
|
|
54
|
-
createRequest: AnonCredsRequestProofFormat;
|
|
55
|
-
acceptRequest: AnonCredsSelectedCredentials;
|
|
56
|
-
getCredentialsForRequest: {
|
|
57
|
-
input: AnonCredsGetCredentialsForProofRequestOptions;
|
|
58
|
-
output: AnonCredsCredentialsForProofRequest;
|
|
59
|
-
};
|
|
60
|
-
selectCredentialsForRequest: {
|
|
61
|
-
input: AnonCredsGetCredentialsForProofRequestOptions;
|
|
62
|
-
output: AnonCredsSelectedCredentials;
|
|
63
|
-
};
|
|
64
|
-
};
|
|
65
|
-
formatData: {
|
|
66
|
-
proposal: AnonCredsProofRequest;
|
|
67
|
-
request: AnonCredsProofRequest;
|
|
68
|
-
presentation: AnonCredsProof;
|
|
69
|
-
};
|
|
70
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AnonCredsProofFormat.js","sourceRoot":"","sources":["../../src/formats/AnonCredsProofFormat.ts"],"names":[],"mappings":""}
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import type { AnonCredsProofFormat } from './AnonCredsProofFormat';
|
|
2
|
-
import type { ProofFormatService, AgentContext, ProofFormatCreateReturn, FormatCreateRequestOptions, ProofFormatCreateProposalOptions, ProofFormatProcessOptions, ProofFormatAcceptProposalOptions, ProofFormatAcceptRequestOptions, ProofFormatProcessPresentationOptions, ProofFormatGetCredentialsForRequestOptions, ProofFormatGetCredentialsForRequestReturn, ProofFormatSelectCredentialsForRequestOptions, ProofFormatSelectCredentialsForRequestReturn, ProofFormatAutoRespondProposalOptions, ProofFormatAutoRespondRequestOptions, ProofFormatAutoRespondPresentationOptions } from '@credo-ts/core';
|
|
3
|
-
export declare class AnonCredsProofFormatService implements ProofFormatService<AnonCredsProofFormat> {
|
|
4
|
-
readonly formatKey: "anoncreds";
|
|
5
|
-
createProposal(agentContext: AgentContext, { attachmentId, proofFormats }: ProofFormatCreateProposalOptions<AnonCredsProofFormat>): Promise<ProofFormatCreateReturn>;
|
|
6
|
-
processProposal(agentContext: AgentContext, { attachment }: ProofFormatProcessOptions): Promise<void>;
|
|
7
|
-
acceptProposal(agentContext: AgentContext, { proposalAttachment, attachmentId }: ProofFormatAcceptProposalOptions<AnonCredsProofFormat>): Promise<ProofFormatCreateReturn>;
|
|
8
|
-
createRequest(agentContext: AgentContext, { attachmentId, proofFormats }: FormatCreateRequestOptions<AnonCredsProofFormat>): Promise<ProofFormatCreateReturn>;
|
|
9
|
-
processRequest(agentContext: AgentContext, { attachment }: ProofFormatProcessOptions): Promise<void>;
|
|
10
|
-
acceptRequest(agentContext: AgentContext, { proofFormats, requestAttachment, attachmentId }: ProofFormatAcceptRequestOptions<AnonCredsProofFormat>): Promise<ProofFormatCreateReturn>;
|
|
11
|
-
processPresentation(agentContext: AgentContext, { requestAttachment, attachment }: ProofFormatProcessPresentationOptions): Promise<boolean>;
|
|
12
|
-
getCredentialsForRequest(agentContext: AgentContext, { requestAttachment, proofFormats }: ProofFormatGetCredentialsForRequestOptions<AnonCredsProofFormat>): Promise<ProofFormatGetCredentialsForRequestReturn<AnonCredsProofFormat>>;
|
|
13
|
-
selectCredentialsForRequest(agentContext: AgentContext, { requestAttachment, proofFormats }: ProofFormatSelectCredentialsForRequestOptions<AnonCredsProofFormat>): Promise<ProofFormatSelectCredentialsForRequestReturn<AnonCredsProofFormat>>;
|
|
14
|
-
shouldAutoRespondToProposal(agentContext: AgentContext, { proposalAttachment, requestAttachment }: ProofFormatAutoRespondProposalOptions): Promise<boolean>;
|
|
15
|
-
shouldAutoRespondToRequest(agentContext: AgentContext, { proposalAttachment, requestAttachment }: ProofFormatAutoRespondRequestOptions): Promise<boolean>;
|
|
16
|
-
shouldAutoRespondToPresentation(_agentContext: AgentContext, _options: ProofFormatAutoRespondPresentationOptions): Promise<boolean>;
|
|
17
|
-
supportsFormat(formatIdentifier: string): boolean;
|
|
18
|
-
private _selectCredentialsForRequest;
|
|
19
|
-
/**
|
|
20
|
-
* Build schemas object needed to create and verify proof objects.
|
|
21
|
-
*
|
|
22
|
-
* Creates object with `{ schemaId: AnonCredsSchema }` mapping
|
|
23
|
-
*
|
|
24
|
-
* @param schemaIds List of schema ids
|
|
25
|
-
* @returns Object containing schemas for specified schema ids
|
|
26
|
-
*
|
|
27
|
-
*/
|
|
28
|
-
private getSchemas;
|
|
29
|
-
/**
|
|
30
|
-
* Build credential definitions object needed to create and verify proof objects.
|
|
31
|
-
*
|
|
32
|
-
* Creates object with `{ credentialDefinitionId: AnonCredsCredentialDefinition }` mapping
|
|
33
|
-
*
|
|
34
|
-
* @param credentialDefinitionIds List of credential definition ids
|
|
35
|
-
* @returns Object containing credential definitions for specified credential definition ids
|
|
36
|
-
*
|
|
37
|
-
*/
|
|
38
|
-
private getCredentialDefinitions;
|
|
39
|
-
/**
|
|
40
|
-
* Create anoncreds proof from a given proof request and requested credential object.
|
|
41
|
-
*
|
|
42
|
-
* @param proofRequest The proof request to create the proof for
|
|
43
|
-
* @param requestedCredentials The requested credentials object specifying which credentials to use for the proof
|
|
44
|
-
* @returns anoncreds proof object
|
|
45
|
-
*/
|
|
46
|
-
private createProof;
|
|
47
|
-
/**
|
|
48
|
-
* Returns an object of type {@link Attachment} for use in credential exchange messages.
|
|
49
|
-
* It looks up the correct format identifier and encodes the data as a base64 attachment.
|
|
50
|
-
*
|
|
51
|
-
* @param data The data to include in the attach object
|
|
52
|
-
* @param id the attach id from the formats component of the message
|
|
53
|
-
*/
|
|
54
|
-
private getFormatData;
|
|
55
|
-
}
|