@ledgerhq/device-trusted-app-kit-ledger-keyring-protocol 0.0.0-legacy-speculos-datasource-20250821095840 → 0.0.0-lifi-with-logger-20251208144248
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/lib/cjs/api/LedgerKeyringProtocol.js +1 -1
- package/lib/cjs/api/LedgerKeyringProtocol.js.map +1 -1
- package/lib/cjs/api/LedgerKeyringProtocolBuilder.js +1 -1
- package/lib/cjs/api/LedgerKeyringProtocolBuilder.js.map +3 -3
- package/lib/cjs/api/app-binder/AddToTrustchainDeviceActionTypes.js +1 -1
- package/lib/cjs/api/app-binder/AddToTrustchainDeviceActionTypes.js.map +3 -3
- package/lib/cjs/api/app-binder/AuthenticateDeviceActionTypes.js +1 -1
- package/lib/cjs/api/app-binder/AuthenticateDeviceActionTypes.js.map +3 -3
- package/lib/cjs/api/app-binder/GetVersionCommandTypes.js +1 -1
- package/lib/cjs/api/app-binder/GetVersionCommandTypes.js.map +1 -1
- package/lib/cjs/api/crypto/CryptoService.js +2 -0
- package/lib/cjs/api/crypto/CryptoService.js.map +7 -0
- package/lib/cjs/api/crypto/Key.js +2 -0
- package/lib/cjs/api/crypto/Key.js.map +7 -0
- package/lib/cjs/api/crypto/KeyPair.js +2 -0
- package/lib/cjs/api/crypto/KeyPair.js.map +7 -0
- package/lib/cjs/api/crypto/noble/NobleCryptoService.js +2 -0
- package/lib/cjs/api/crypto/noble/NobleCryptoService.js.map +7 -0
- package/lib/cjs/api/crypto/noble/NobleCryptoService.test.js +2 -0
- package/lib/cjs/api/crypto/noble/NobleCryptoService.test.js.map +7 -0
- package/lib/cjs/api/crypto/noble/NobleKey.js +2 -0
- package/lib/cjs/api/crypto/noble/NobleKey.js.map +7 -0
- package/lib/cjs/api/crypto/noble/NobleKey.test.js +2 -0
- package/lib/cjs/api/crypto/noble/NobleKey.test.js.map +7 -0
- package/lib/cjs/api/crypto/noble/NobleKeyPair.js +2 -0
- package/lib/cjs/api/crypto/noble/NobleKeyPair.js.map +7 -0
- package/lib/cjs/api/crypto/noble/NobleKeyPair.test.js +2 -0
- package/lib/cjs/api/crypto/noble/NobleKeyPair.test.js.map +7 -0
- package/lib/cjs/api/index.js +1 -1
- package/lib/cjs/api/index.js.map +2 -2
- package/lib/cjs/api/model/Env.js +2 -0
- package/lib/cjs/api/model/Env.js.map +7 -0
- package/lib/cjs/api/model/Errors.js +2 -0
- package/lib/cjs/api/model/Errors.js.map +7 -0
- package/lib/cjs/api/model/JWT.js +2 -0
- package/lib/cjs/api/model/JWT.js.map +7 -0
- package/lib/cjs/api/model/Permissions.js +2 -0
- package/lib/cjs/api/model/Permissions.js.map +7 -0
- package/lib/cjs/internal/DefaultLedgerKeyringProtocol.js +1 -1
- package/lib/cjs/internal/DefaultLedgerKeyringProtocol.js.map +3 -3
- package/lib/cjs/internal/app-binder/LedgerKeyringProtocolBinder.js +1 -1
- package/lib/cjs/internal/app-binder/LedgerKeyringProtocolBinder.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/GetAppNameCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/GetAppNameCommand.js.map +2 -2
- package/lib/cjs/internal/app-binder/command/GetSeedIdCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/GetSeedIdCommand.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/GetSeedIdCommand.test.js +3 -3
- package/lib/cjs/internal/app-binder/command/GetSeedIdCommand.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/GetVersionCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/GetVersionCommand.js.map +2 -2
- package/lib/cjs/internal/app-binder/command/InitCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/InitCommand.js.map +2 -2
- package/lib/cjs/internal/app-binder/command/InitCommand.test.js +1 -1
- package/lib/cjs/internal/app-binder/command/InitCommand.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/ParseBlockSignatureCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/ParseBlockSignatureCommand.js.map +2 -2
- package/lib/cjs/internal/app-binder/command/ParseBlockSignatureCommand.test.js +1 -1
- package/lib/cjs/internal/app-binder/command/ParseBlockSignatureCommand.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/ParseStreamBlockCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/ParseStreamBlockCommand.js.map +2 -2
- package/lib/cjs/internal/app-binder/command/ParseStreamBlockCommand.test.js +1 -1
- package/lib/cjs/internal/app-binder/command/ParseStreamBlockCommand.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/ParseStreamBlockHeader.js +1 -1
- package/lib/cjs/internal/app-binder/command/ParseStreamBlockHeader.js.map +2 -2
- package/lib/cjs/internal/app-binder/command/ParseStreamBlockHeader.test.js +1 -1
- package/lib/cjs/internal/app-binder/command/ParseStreamBlockHeader.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/SetTrustedMemberCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/SetTrustedMemberCommand.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/SetTrustedMemberCommand.test.js +1 -1
- package/lib/cjs/internal/app-binder/command/SetTrustedMemberCommand.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/SignBlockHeader.js +1 -1
- package/lib/cjs/internal/app-binder/command/SignBlockHeader.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/SignBlockHeader.test.js +1 -1
- package/lib/cjs/internal/app-binder/command/SignBlockHeader.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/SignBlockSignatureCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/SignBlockSignatureCommand.js.map +2 -2
- package/lib/cjs/internal/app-binder/command/SignBlockSignatureCommand.test.js +1 -1
- package/lib/cjs/internal/app-binder/command/SignBlockSignatureCommand.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/command/SignBlockSingleCommand.js +1 -1
- package/lib/cjs/internal/app-binder/command/SignBlockSingleCommand.js.map +2 -2
- package/lib/cjs/internal/app-binder/command/SignBlockSingleCommand.test.js +1 -1
- package/lib/cjs/internal/app-binder/command/SignBlockSingleCommand.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/device-action/AddToTrustchainDeviceAction.js +1 -1
- package/lib/cjs/internal/app-binder/device-action/AddToTrustchainDeviceAction.js.map +3 -3
- package/lib/cjs/internal/app-binder/device-action/AuthenticateWithDeviceDeviceAction.js +2 -0
- package/lib/cjs/internal/app-binder/device-action/AuthenticateWithDeviceDeviceAction.js.map +7 -0
- package/lib/cjs/internal/app-binder/device-action/AuthenticateWithKeypairDeviceAction.js +2 -0
- package/lib/cjs/internal/app-binder/device-action/AuthenticateWithKeypairDeviceAction.js.map +7 -0
- package/lib/cjs/internal/app-binder/device-action/models/AuthenticateWithDeviceDeviceActionTypes.js +2 -0
- package/lib/cjs/internal/app-binder/device-action/models/AuthenticateWithDeviceDeviceActionTypes.js.map +7 -0
- package/lib/cjs/internal/app-binder/device-action/models/AuthenticateWithKeypairDeviceActionTypes.js +2 -0
- package/lib/cjs/internal/app-binder/device-action/models/AuthenticateWithKeypairDeviceActionTypes.js.map +7 -0
- package/lib/cjs/internal/app-binder/task/AuthenticateTask.js +2 -0
- package/lib/cjs/internal/app-binder/task/AuthenticateTask.js.map +7 -0
- package/lib/cjs/internal/app-binder/task/ExtractEncryptionKeyTask.js +2 -0
- package/lib/cjs/internal/app-binder/task/ExtractEncryptionKeyTask.js.map +7 -0
- package/lib/cjs/internal/app-binder/task/InitTask.js +1 -1
- package/lib/cjs/internal/app-binder/task/InitTask.js.map +3 -3
- package/lib/cjs/internal/app-binder/task/ParseStreamToDeviceTask.js +1 -1
- package/lib/cjs/internal/app-binder/task/ParseStreamToDeviceTask.js.map +3 -3
- package/lib/cjs/internal/app-binder/task/SignBlockTask.js +1 -1
- package/lib/cjs/internal/app-binder/task/SignBlockTask.js.map +3 -3
- package/lib/cjs/internal/app-binder/task/SignChallengeWithKeypairTask.js +1 -1
- package/lib/cjs/internal/app-binder/task/SignChallengeWithKeypairTask.js.map +3 -3
- package/lib/cjs/internal/app-binder/task/SignChallengeWithKeypairTask.test.js +1 -1
- package/lib/cjs/internal/app-binder/task/SignChallengeWithKeypairTask.test.js.map +3 -3
- package/lib/cjs/internal/app-binder/task/utils/TrustedProperties.js +1 -1
- package/lib/cjs/internal/app-binder/task/utils/TrustedProperties.js.map +3 -3
- package/lib/cjs/internal/di.js +1 -1
- package/lib/cjs/internal/di.js.map +3 -3
- package/lib/cjs/internal/externalTypes.js +1 -1
- package/lib/cjs/internal/externalTypes.js.map +2 -2
- package/lib/cjs/internal/lkrp-datasource/data/HttpLKRPDataSource.js +1 -1
- package/lib/cjs/internal/lkrp-datasource/data/HttpLKRPDataSource.js.map +3 -3
- package/lib/cjs/internal/lkrp-datasource/data/HttpLKRPDataSource.test.js +1 -1
- package/lib/cjs/internal/lkrp-datasource/data/HttpLKRPDataSource.test.js.map +3 -3
- package/lib/cjs/internal/lkrp-datasource/data/LKRPDataSource.js +1 -1
- package/lib/cjs/internal/lkrp-datasource/data/LKRPDataSource.js.map +1 -1
- package/lib/cjs/internal/models/LKRPBlockTypes.js +2 -0
- package/lib/cjs/internal/models/LKRPBlockTypes.js.map +7 -0
- package/lib/cjs/internal/models/LKRPCommandTypes.js +2 -0
- package/lib/cjs/internal/models/LKRPCommandTypes.js.map +7 -0
- package/lib/cjs/internal/{utils/TLVTags.js → models/Tags.js} +1 -1
- package/lib/cjs/internal/{utils/TLVTags.js.map → models/Tags.js.map} +2 -2
- package/lib/cjs/internal/models/Types.js +2 -0
- package/lib/cjs/internal/models/Types.js.map +7 -0
- package/lib/cjs/internal/use-cases/authentication/AuthenticateUseCase.js +1 -1
- package/lib/cjs/internal/use-cases/authentication/AuthenticateUseCase.js.map +3 -3
- package/lib/cjs/internal/use-cases/authentication/DecryptDataUseCase.js +2 -0
- package/lib/cjs/internal/use-cases/authentication/DecryptDataUseCase.js.map +7 -0
- package/lib/cjs/internal/use-cases/authentication/EncryptDataUseCase.js +2 -0
- package/lib/cjs/internal/use-cases/authentication/EncryptDataUseCase.js.map +7 -0
- package/lib/cjs/internal/use-cases/di/useCasesModule.js +1 -1
- package/lib/cjs/internal/use-cases/di/useCasesModule.js.map +3 -3
- package/lib/cjs/internal/use-cases/di/useCasesTypes.js +1 -1
- package/lib/cjs/internal/use-cases/di/useCasesTypes.js.map +2 -2
- package/lib/cjs/internal/utils/LKRPBlock.js +4 -4
- package/lib/cjs/internal/utils/LKRPBlock.js.map +3 -3
- package/lib/cjs/internal/utils/LKRPBlock.test.js +3 -3
- package/lib/cjs/internal/utils/LKRPBlock.test.js.map +3 -3
- package/lib/cjs/internal/utils/LKRPBlockStream.js +2 -2
- package/lib/cjs/internal/utils/LKRPBlockStream.js.map +3 -3
- package/lib/cjs/internal/utils/LKRPBlockStream.test.js +3 -3
- package/lib/cjs/internal/utils/LKRPBlockStream.test.js.map +3 -3
- package/lib/cjs/internal/utils/LKRPCommand.js +2 -2
- package/lib/cjs/internal/utils/LKRPCommand.js.map +3 -3
- package/lib/cjs/internal/utils/LKRPCommand.test.js +2 -2
- package/lib/cjs/internal/utils/LKRPCommand.test.js.map +3 -3
- package/lib/cjs/internal/utils/TLVParser.js +1 -1
- package/lib/cjs/internal/utils/TLVParser.js.map +3 -3
- package/lib/cjs/internal/utils/TLVParser.test.js +1 -1
- package/lib/cjs/internal/utils/TLVParser.test.js.map +3 -3
- package/lib/cjs/internal/utils/Trustchain.js +2 -0
- package/lib/cjs/internal/utils/Trustchain.js.map +7 -0
- package/lib/cjs/internal/utils/required.js +1 -1
- package/lib/cjs/internal/utils/required.js.map +2 -2
- package/lib/cjs/package.json +36 -31
- package/lib/esm/api/LedgerKeyringProtocolBuilder.js +1 -1
- package/lib/esm/api/LedgerKeyringProtocolBuilder.js.map +3 -3
- package/lib/esm/api/app-binder/AddToTrustchainDeviceActionTypes.js +1 -0
- package/lib/esm/api/app-binder/AddToTrustchainDeviceActionTypes.js.map +4 -4
- package/lib/esm/api/app-binder/AuthenticateDeviceActionTypes.js +1 -0
- package/lib/esm/api/app-binder/AuthenticateDeviceActionTypes.js.map +4 -4
- package/lib/esm/api/crypto/CryptoService.js +2 -0
- package/lib/esm/api/crypto/CryptoService.js.map +7 -0
- package/lib/esm/api/crypto/Key.js +2 -0
- package/lib/esm/api/crypto/Key.js.map +7 -0
- package/lib/esm/api/crypto/KeyPair.js +2 -0
- package/lib/esm/api/crypto/KeyPair.js.map +7 -0
- package/lib/esm/api/crypto/noble/NobleCryptoService.js +2 -0
- package/lib/esm/api/crypto/noble/NobleCryptoService.js.map +7 -0
- package/lib/esm/api/crypto/noble/NobleCryptoService.test.js +2 -0
- package/lib/esm/api/crypto/noble/NobleCryptoService.test.js.map +7 -0
- package/lib/esm/api/crypto/noble/NobleKey.js +2 -0
- package/lib/esm/api/crypto/noble/NobleKey.js.map +7 -0
- package/lib/esm/api/crypto/noble/NobleKey.test.js +2 -0
- package/lib/esm/api/crypto/noble/NobleKey.test.js.map +7 -0
- package/lib/esm/api/crypto/noble/NobleKeyPair.js +2 -0
- package/lib/esm/api/crypto/noble/NobleKeyPair.js.map +7 -0
- package/lib/esm/api/crypto/noble/NobleKeyPair.test.js +2 -0
- package/lib/esm/api/crypto/noble/NobleKeyPair.test.js.map +7 -0
- package/lib/esm/api/index.js +1 -1
- package/lib/esm/api/index.js.map +2 -2
- package/lib/esm/api/model/Env.js +2 -0
- package/lib/esm/api/model/Env.js.map +7 -0
- package/lib/esm/api/model/Errors.js +2 -0
- package/lib/esm/api/model/Errors.js.map +7 -0
- package/lib/esm/api/model/JWT.js +1 -0
- package/lib/esm/api/model/Permissions.js +2 -0
- package/lib/esm/api/model/Permissions.js.map +7 -0
- package/lib/esm/internal/DefaultLedgerKeyringProtocol.js +1 -1
- package/lib/esm/internal/DefaultLedgerKeyringProtocol.js.map +3 -3
- package/lib/esm/internal/app-binder/LedgerKeyringProtocolBinder.js +1 -1
- package/lib/esm/internal/app-binder/LedgerKeyringProtocolBinder.js.map +3 -3
- package/lib/esm/internal/app-binder/command/GetAppNameCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/GetAppNameCommand.js.map +2 -2
- package/lib/esm/internal/app-binder/command/GetSeedIdCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/GetSeedIdCommand.js.map +3 -3
- package/lib/esm/internal/app-binder/command/GetSeedIdCommand.test.js +3 -3
- package/lib/esm/internal/app-binder/command/GetSeedIdCommand.test.js.map +3 -3
- package/lib/esm/internal/app-binder/command/GetVersionCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/GetVersionCommand.js.map +2 -2
- package/lib/esm/internal/app-binder/command/InitCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/InitCommand.js.map +2 -2
- package/lib/esm/internal/app-binder/command/InitCommand.test.js +1 -1
- package/lib/esm/internal/app-binder/command/InitCommand.test.js.map +3 -3
- package/lib/esm/internal/app-binder/command/ParseBlockSignatureCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/ParseBlockSignatureCommand.js.map +2 -2
- package/lib/esm/internal/app-binder/command/ParseBlockSignatureCommand.test.js +1 -1
- package/lib/esm/internal/app-binder/command/ParseBlockSignatureCommand.test.js.map +3 -3
- package/lib/esm/internal/app-binder/command/ParseStreamBlockCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/ParseStreamBlockCommand.js.map +2 -2
- package/lib/esm/internal/app-binder/command/ParseStreamBlockCommand.test.js +1 -1
- package/lib/esm/internal/app-binder/command/ParseStreamBlockCommand.test.js.map +3 -3
- package/lib/esm/internal/app-binder/command/ParseStreamBlockHeader.js +1 -1
- package/lib/esm/internal/app-binder/command/ParseStreamBlockHeader.js.map +2 -2
- package/lib/esm/internal/app-binder/command/ParseStreamBlockHeader.test.js +1 -1
- package/lib/esm/internal/app-binder/command/ParseStreamBlockHeader.test.js.map +3 -3
- package/lib/esm/internal/app-binder/command/SetTrustedMemberCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/SetTrustedMemberCommand.js.map +2 -2
- package/lib/esm/internal/app-binder/command/SetTrustedMemberCommand.test.js +1 -1
- package/lib/esm/internal/app-binder/command/SetTrustedMemberCommand.test.js.map +3 -3
- package/lib/esm/internal/app-binder/command/SignBlockHeader.js +1 -1
- package/lib/esm/internal/app-binder/command/SignBlockHeader.js.map +3 -3
- package/lib/esm/internal/app-binder/command/SignBlockHeader.test.js +1 -1
- package/lib/esm/internal/app-binder/command/SignBlockHeader.test.js.map +3 -3
- package/lib/esm/internal/app-binder/command/SignBlockSignatureCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/SignBlockSignatureCommand.js.map +2 -2
- package/lib/esm/internal/app-binder/command/SignBlockSignatureCommand.test.js +1 -1
- package/lib/esm/internal/app-binder/command/SignBlockSignatureCommand.test.js.map +3 -3
- package/lib/esm/internal/app-binder/command/SignBlockSingleCommand.js +1 -1
- package/lib/esm/internal/app-binder/command/SignBlockSingleCommand.js.map +2 -2
- package/lib/esm/internal/app-binder/command/SignBlockSingleCommand.test.js +1 -1
- package/lib/esm/internal/app-binder/command/SignBlockSingleCommand.test.js.map +3 -3
- package/lib/esm/internal/app-binder/device-action/AddToTrustchainDeviceAction.js +1 -1
- package/lib/esm/internal/app-binder/device-action/AddToTrustchainDeviceAction.js.map +3 -3
- package/lib/esm/internal/app-binder/device-action/AuthenticateWithDeviceDeviceAction.js +2 -0
- package/lib/esm/internal/app-binder/device-action/AuthenticateWithDeviceDeviceAction.js.map +7 -0
- package/lib/esm/internal/app-binder/device-action/AuthenticateWithKeypairDeviceAction.js +2 -0
- package/lib/esm/internal/app-binder/device-action/AuthenticateWithKeypairDeviceAction.js.map +7 -0
- package/lib/esm/internal/app-binder/device-action/models/AuthenticateWithDeviceDeviceActionTypes.js +1 -0
- package/lib/esm/internal/app-binder/device-action/models/AuthenticateWithKeypairDeviceActionTypes.js +1 -0
- package/lib/esm/internal/app-binder/task/AuthenticateTask.js +2 -0
- package/lib/esm/internal/app-binder/task/AuthenticateTask.js.map +7 -0
- package/lib/esm/internal/app-binder/task/ExtractEncryptionKeyTask.js +2 -0
- package/lib/esm/internal/app-binder/task/ExtractEncryptionKeyTask.js.map +7 -0
- package/lib/esm/internal/app-binder/task/InitTask.js +1 -1
- package/lib/esm/internal/app-binder/task/InitTask.js.map +3 -3
- package/lib/esm/internal/app-binder/task/ParseStreamToDeviceTask.js +1 -1
- package/lib/esm/internal/app-binder/task/ParseStreamToDeviceTask.js.map +3 -3
- package/lib/esm/internal/app-binder/task/SignBlockTask.js +1 -1
- package/lib/esm/internal/app-binder/task/SignBlockTask.js.map +3 -3
- package/lib/esm/internal/app-binder/task/SignChallengeWithKeypairTask.js +1 -1
- package/lib/esm/internal/app-binder/task/SignChallengeWithKeypairTask.js.map +3 -3
- package/lib/esm/internal/app-binder/task/SignChallengeWithKeypairTask.test.js +1 -1
- package/lib/esm/internal/app-binder/task/SignChallengeWithKeypairTask.test.js.map +3 -3
- package/lib/esm/internal/app-binder/task/utils/TrustedProperties.js +1 -1
- package/lib/esm/internal/app-binder/task/utils/TrustedProperties.js.map +3 -3
- package/lib/esm/internal/di.js +1 -1
- package/lib/esm/internal/di.js.map +3 -3
- package/lib/esm/internal/externalTypes.js +1 -1
- package/lib/esm/internal/externalTypes.js.map +2 -2
- package/lib/esm/internal/lkrp-datasource/data/HttpLKRPDataSource.js +1 -1
- package/lib/esm/internal/lkrp-datasource/data/HttpLKRPDataSource.js.map +3 -3
- package/lib/esm/internal/lkrp-datasource/data/HttpLKRPDataSource.test.js +1 -1
- package/lib/esm/internal/lkrp-datasource/data/HttpLKRPDataSource.test.js.map +3 -3
- package/lib/esm/internal/models/LKRPBlockTypes.js +1 -0
- package/lib/esm/internal/models/LKRPCommandTypes.js +1 -0
- package/lib/esm/internal/{utils/TLVTags.js → models/Tags.js} +1 -1
- package/lib/esm/internal/{utils/TLVTags.js.map → models/Tags.js.map} +1 -1
- package/lib/esm/internal/models/Types.js +1 -0
- package/lib/esm/internal/use-cases/authentication/AuthenticateUseCase.js +1 -1
- package/lib/esm/internal/use-cases/authentication/AuthenticateUseCase.js.map +3 -3
- package/lib/esm/internal/use-cases/authentication/DecryptDataUseCase.js +2 -0
- package/lib/esm/internal/use-cases/authentication/DecryptDataUseCase.js.map +7 -0
- package/lib/esm/internal/use-cases/authentication/EncryptDataUseCase.js +2 -0
- package/lib/esm/internal/use-cases/authentication/EncryptDataUseCase.js.map +7 -0
- package/lib/esm/internal/use-cases/di/useCasesModule.js +1 -1
- package/lib/esm/internal/use-cases/di/useCasesModule.js.map +3 -3
- package/lib/esm/internal/use-cases/di/useCasesTypes.js +1 -1
- package/lib/esm/internal/use-cases/di/useCasesTypes.js.map +2 -2
- package/lib/esm/internal/utils/LKRPBlock.js +3 -3
- package/lib/esm/internal/utils/LKRPBlock.js.map +3 -3
- package/lib/esm/internal/utils/LKRPBlock.test.js +2 -2
- package/lib/esm/internal/utils/LKRPBlock.test.js.map +3 -3
- package/lib/esm/internal/utils/LKRPBlockStream.js +2 -2
- package/lib/esm/internal/utils/LKRPBlockStream.js.map +3 -3
- package/lib/esm/internal/utils/LKRPBlockStream.test.js +3 -3
- package/lib/esm/internal/utils/LKRPBlockStream.test.js.map +3 -3
- package/lib/esm/internal/utils/LKRPCommand.js +2 -2
- package/lib/esm/internal/utils/LKRPCommand.js.map +3 -3
- package/lib/esm/internal/utils/LKRPCommand.test.js +2 -2
- package/lib/esm/internal/utils/LKRPCommand.test.js.map +3 -3
- package/lib/esm/internal/utils/TLVParser.js +1 -1
- package/lib/esm/internal/utils/TLVParser.js.map +3 -3
- package/lib/esm/internal/utils/TLVParser.test.js +1 -1
- package/lib/esm/internal/utils/TLVParser.test.js.map +3 -3
- package/lib/esm/internal/utils/Trustchain.js +2 -0
- package/lib/esm/internal/utils/Trustchain.js.map +7 -0
- package/lib/esm/internal/utils/required.js +1 -1
- package/lib/esm/internal/utils/required.js.map +2 -2
- package/lib/esm/package.json +36 -31
- package/lib/types/api/LedgerKeyringProtocol.d.ts +4 -5
- package/lib/types/api/LedgerKeyringProtocol.d.ts.map +1 -1
- package/lib/types/api/LedgerKeyringProtocolBuilder.d.ts +12 -6
- package/lib/types/api/LedgerKeyringProtocolBuilder.d.ts.map +1 -1
- package/lib/types/api/app-binder/AddToTrustchainDeviceActionTypes.d.ts +25 -11
- package/lib/types/api/app-binder/AddToTrustchainDeviceActionTypes.d.ts.map +1 -1
- package/lib/types/api/app-binder/AuthenticateDeviceActionTypes.d.ts +27 -31
- package/lib/types/api/app-binder/AuthenticateDeviceActionTypes.d.ts.map +1 -1
- package/lib/types/api/app-binder/GetVersionCommandTypes.d.ts +0 -1
- package/lib/types/api/app-binder/GetVersionCommandTypes.d.ts.map +1 -1
- package/lib/types/api/crypto/CryptoService.d.ts +22 -0
- package/lib/types/api/crypto/CryptoService.d.ts.map +1 -0
- package/lib/types/api/crypto/Key.d.ts +7 -0
- package/lib/types/api/crypto/Key.d.ts.map +1 -0
- package/lib/types/api/crypto/KeyPair.d.ts +13 -0
- package/lib/types/api/crypto/KeyPair.d.ts.map +1 -0
- package/lib/types/api/crypto/noble/NobleCryptoService.d.ts +13 -0
- package/lib/types/api/crypto/noble/NobleCryptoService.d.ts.map +1 -0
- package/lib/types/api/crypto/noble/NobleCryptoService.test.d.ts +2 -0
- package/lib/types/api/crypto/noble/NobleCryptoService.test.d.ts.map +1 -0
- package/lib/types/api/crypto/noble/NobleKey.d.ts +11 -0
- package/lib/types/api/crypto/noble/NobleKey.d.ts.map +1 -0
- package/lib/types/api/crypto/noble/NobleKey.test.d.ts +2 -0
- package/lib/types/api/crypto/noble/NobleKey.test.d.ts.map +1 -0
- package/lib/types/api/crypto/noble/NobleKeyPair.d.ts +18 -0
- package/lib/types/api/crypto/noble/NobleKeyPair.d.ts.map +1 -0
- package/lib/types/api/crypto/noble/NobleKeyPair.test.d.ts +2 -0
- package/lib/types/api/crypto/noble/NobleKeyPair.test.d.ts.map +1 -0
- package/lib/types/api/index.d.ts +10 -2
- package/lib/types/api/index.d.ts.map +1 -1
- package/lib/types/api/model/Env.d.ts +5 -0
- package/lib/types/api/model/Env.d.ts.map +1 -0
- package/lib/types/api/model/Errors.d.ts +53 -0
- package/lib/types/api/model/Errors.d.ts.map +1 -0
- package/lib/types/api/model/JWT.d.ts +9 -0
- package/lib/types/api/model/JWT.d.ts.map +1 -0
- package/lib/types/api/{app-binder/LKRPTypes.d.ts → model/Permissions.d.ts} +1 -15
- package/lib/types/api/model/Permissions.d.ts.map +1 -0
- package/lib/types/internal/DefaultLedgerKeyringProtocol.d.ts +12 -9
- package/lib/types/internal/DefaultLedgerKeyringProtocol.d.ts.map +1 -1
- package/lib/types/internal/app-binder/LedgerKeyringProtocolBinder.d.ts +14 -8
- package/lib/types/internal/app-binder/LedgerKeyringProtocolBinder.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/GetAppNameCommand.d.ts +5 -1
- package/lib/types/internal/app-binder/command/GetAppNameCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/GetSeedIdCommand.d.ts +14 -1
- package/lib/types/internal/app-binder/command/GetSeedIdCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/GetVersionCommand.d.ts +3 -1
- package/lib/types/internal/app-binder/command/GetVersionCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/InitCommand.d.ts +5 -1
- package/lib/types/internal/app-binder/command/InitCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/ParseBlockSignatureCommand.d.ts +5 -1
- package/lib/types/internal/app-binder/command/ParseBlockSignatureCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/ParseStreamBlockCommand.d.ts +6 -1
- package/lib/types/internal/app-binder/command/ParseStreamBlockCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/ParseStreamBlockHeader.d.ts +5 -1
- package/lib/types/internal/app-binder/command/ParseStreamBlockHeader.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/SetTrustedMemberCommand.d.ts +6 -1
- package/lib/types/internal/app-binder/command/SetTrustedMemberCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/SignBlockHeader.d.ts +7 -1
- package/lib/types/internal/app-binder/command/SignBlockHeader.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/SignBlockSignatureCommand.d.ts +6 -1
- package/lib/types/internal/app-binder/command/SignBlockSignatureCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/command/SignBlockSingleCommand.d.ts +5 -1
- package/lib/types/internal/app-binder/command/SignBlockSingleCommand.d.ts.map +1 -1
- package/lib/types/internal/app-binder/device-action/AddToTrustchainDeviceAction.d.ts +10 -6
- package/lib/types/internal/app-binder/device-action/AddToTrustchainDeviceAction.d.ts.map +1 -1
- package/lib/types/internal/app-binder/device-action/AuthenticateWithDeviceDeviceAction.d.ts +32 -0
- package/lib/types/internal/app-binder/device-action/AuthenticateWithDeviceDeviceAction.d.ts.map +1 -0
- package/lib/types/internal/app-binder/device-action/AuthenticateWithKeypairDeviceAction.d.ts +33 -0
- package/lib/types/internal/app-binder/device-action/AuthenticateWithKeypairDeviceAction.d.ts.map +1 -0
- package/lib/types/internal/app-binder/device-action/models/AuthenticateWithDeviceDeviceActionTypes.d.ts +22 -0
- package/lib/types/internal/app-binder/device-action/models/AuthenticateWithDeviceDeviceActionTypes.d.ts.map +1 -0
- package/lib/types/internal/app-binder/device-action/models/AuthenticateWithKeypairDeviceActionTypes.d.ts +19 -0
- package/lib/types/internal/app-binder/device-action/models/AuthenticateWithKeypairDeviceActionTypes.d.ts.map +1 -0
- package/lib/types/internal/app-binder/task/AuthenticateTask.d.ts +9 -0
- package/lib/types/internal/app-binder/task/AuthenticateTask.d.ts.map +1 -0
- package/lib/types/internal/app-binder/task/ExtractEncryptionKeyTask.d.ts +8 -0
- package/lib/types/internal/app-binder/task/ExtractEncryptionKeyTask.d.ts.map +1 -0
- package/lib/types/internal/app-binder/task/InitTask.d.ts +5 -3
- package/lib/types/internal/app-binder/task/InitTask.d.ts.map +1 -1
- package/lib/types/internal/app-binder/task/ParseStreamToDeviceTask.d.ts +3 -3
- package/lib/types/internal/app-binder/task/ParseStreamToDeviceTask.d.ts.map +1 -1
- package/lib/types/internal/app-binder/task/SignBlockTask.d.ts +15 -13
- package/lib/types/internal/app-binder/task/SignBlockTask.d.ts.map +1 -1
- package/lib/types/internal/app-binder/task/SignChallengeWithKeypairTask.d.ts +7 -6
- package/lib/types/internal/app-binder/task/SignChallengeWithKeypairTask.d.ts.map +1 -1
- package/lib/types/internal/app-binder/task/utils/TrustedProperties.d.ts +2 -2
- package/lib/types/internal/app-binder/task/utils/TrustedProperties.d.ts.map +1 -1
- package/lib/types/internal/di.d.ts +7 -3
- package/lib/types/internal/di.d.ts.map +1 -1
- package/lib/types/internal/externalTypes.d.ts +2 -1
- package/lib/types/internal/externalTypes.d.ts.map +1 -1
- package/lib/types/internal/lkrp-datasource/data/HttpLKRPDataSource.d.ts +8 -10
- package/lib/types/internal/lkrp-datasource/data/HttpLKRPDataSource.d.ts.map +1 -1
- package/lib/types/internal/lkrp-datasource/data/LKRPDataSource.d.ts +8 -8
- package/lib/types/internal/lkrp-datasource/data/LKRPDataSource.d.ts.map +1 -1
- package/lib/types/internal/models/LKRPBlockTypes.d.ts +11 -0
- package/lib/types/internal/models/LKRPBlockTypes.d.ts.map +1 -0
- package/lib/types/internal/{utils/types.d.ts → models/LKRPCommandTypes.d.ts} +6 -29
- package/lib/types/internal/models/LKRPCommandTypes.d.ts.map +1 -0
- package/lib/types/internal/{utils/TLVTags.d.ts → models/Tags.d.ts} +1 -1
- package/lib/types/internal/models/Tags.d.ts.map +1 -0
- package/lib/types/internal/models/Types.d.ts +10 -0
- package/lib/types/internal/models/Types.d.ts.map +1 -0
- package/lib/types/internal/use-cases/authentication/AuthenticateUseCase.d.ts +15 -2
- package/lib/types/internal/use-cases/authentication/AuthenticateUseCase.d.ts.map +1 -1
- package/lib/types/internal/use-cases/authentication/DecryptDataUseCase.d.ts +7 -0
- package/lib/types/internal/use-cases/authentication/DecryptDataUseCase.d.ts.map +1 -0
- package/lib/types/internal/use-cases/authentication/EncryptDataUseCase.d.ts +7 -0
- package/lib/types/internal/use-cases/authentication/EncryptDataUseCase.d.ts.map +1 -0
- package/lib/types/internal/use-cases/di/useCasesModule.d.ts.map +1 -1
- package/lib/types/internal/use-cases/di/useCasesTypes.d.ts +2 -0
- package/lib/types/internal/use-cases/di/useCasesTypes.d.ts.map +1 -1
- package/lib/types/internal/utils/LKRPBlock.d.ts +2 -2
- package/lib/types/internal/utils/LKRPBlock.d.ts.map +1 -1
- package/lib/types/internal/utils/LKRPBlockStream.d.ts +8 -8
- package/lib/types/internal/utils/LKRPBlockStream.d.ts.map +1 -1
- package/lib/types/internal/utils/LKRPCommand.d.ts +4 -3
- package/lib/types/internal/utils/LKRPCommand.d.ts.map +1 -1
- package/lib/types/internal/utils/TLVParser.d.ts +4 -3
- package/lib/types/internal/utils/TLVParser.d.ts.map +1 -1
- package/lib/types/internal/utils/Trustchain.d.ts +14 -0
- package/lib/types/internal/utils/Trustchain.d.ts.map +1 -0
- package/lib/types/internal/utils/required.d.ts +1 -1
- package/lib/types/internal/utils/required.d.ts.map +1 -1
- package/lib/types/tsconfig.prod.tsbuildinfo +1 -1
- package/package.json +35 -30
- package/lib/cjs/api/app-binder/Errors.js +0 -2
- package/lib/cjs/api/app-binder/Errors.js.map +0 -7
- package/lib/cjs/api/app-binder/GetAppNameCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/GetAppNameCommandTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/GetSeedIdCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/GetSeedIdCommandTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/InitCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/InitCommandTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/KeypairFromBytes.js +0 -2
- package/lib/cjs/api/app-binder/KeypairFromBytes.js.map +0 -7
- package/lib/cjs/api/app-binder/LKRPTypes.js +0 -2
- package/lib/cjs/api/app-binder/LKRPTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/ParseStreamBlockCommandCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/ParseStreamBlockCommandCommandTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/ParseStreamBlockHeaderCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/ParseStreamBlockHeaderCommandTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/ParseStreamBlockSignatureTypes.js +0 -2
- package/lib/cjs/api/app-binder/ParseStreamBlockSignatureTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/SetTrustedMemberTypes.js +0 -2
- package/lib/cjs/api/app-binder/SetTrustedMemberTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/SignBlockCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/SignBlockCommandTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/SignBlockHeaderCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/SignBlockHeaderCommandTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/SignBlockSignatureCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/SignBlockSignatureCommandTypes.js.map +0 -7
- package/lib/cjs/api/app-binder/SignBlockSingleCommandTypes.js +0 -2
- package/lib/cjs/api/app-binder/SignBlockSingleCommandTypes.js.map +0 -7
- package/lib/cjs/internal/app-binder/device-action/AuthenticateDeviceAction.js +0 -2
- package/lib/cjs/internal/app-binder/device-action/AuthenticateDeviceAction.js.map +0 -7
- package/lib/cjs/internal/utils/TLVBuilder.js +0 -2
- package/lib/cjs/internal/utils/TLVBuilder.js.map +0 -7
- package/lib/cjs/internal/utils/crypto.js +0 -2
- package/lib/cjs/internal/utils/crypto.js.map +0 -7
- package/lib/cjs/internal/utils/hex.js +0 -2
- package/lib/cjs/internal/utils/hex.js.map +0 -7
- package/lib/cjs/internal/utils/types.js +0 -2
- package/lib/cjs/internal/utils/types.js.map +0 -7
- package/lib/esm/api/app-binder/Errors.js +0 -2
- package/lib/esm/api/app-binder/Errors.js.map +0 -7
- package/lib/esm/api/app-binder/GetAppNameCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/GetSeedIdCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/InitCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/KeypairFromBytes.js +0 -2
- package/lib/esm/api/app-binder/KeypairFromBytes.js.map +0 -7
- package/lib/esm/api/app-binder/LKRPTypes.js +0 -2
- package/lib/esm/api/app-binder/LKRPTypes.js.map +0 -7
- package/lib/esm/api/app-binder/ParseStreamBlockCommandCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/ParseStreamBlockHeaderCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/ParseStreamBlockSignatureTypes.js +0 -1
- package/lib/esm/api/app-binder/SetTrustedMemberTypes.js +0 -1
- package/lib/esm/api/app-binder/SetTrustedMemberTypes.js.map +0 -7
- package/lib/esm/api/app-binder/SignBlockCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/SignBlockCommandTypes.js.map +0 -7
- package/lib/esm/api/app-binder/SignBlockHeaderCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/SignBlockHeaderCommandTypes.js.map +0 -7
- package/lib/esm/api/app-binder/SignBlockSignatureCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/SignBlockSignatureCommandTypes.js.map +0 -7
- package/lib/esm/api/app-binder/SignBlockSingleCommandTypes.js +0 -1
- package/lib/esm/api/app-binder/SignBlockSingleCommandTypes.js.map +0 -7
- package/lib/esm/internal/app-binder/device-action/AuthenticateDeviceAction.js +0 -2
- package/lib/esm/internal/app-binder/device-action/AuthenticateDeviceAction.js.map +0 -7
- package/lib/esm/internal/utils/TLVBuilder.js +0 -2
- package/lib/esm/internal/utils/TLVBuilder.js.map +0 -7
- package/lib/esm/internal/utils/crypto.js +0 -2
- package/lib/esm/internal/utils/crypto.js.map +0 -7
- package/lib/esm/internal/utils/hex.js +0 -2
- package/lib/esm/internal/utils/hex.js.map +0 -7
- package/lib/esm/internal/utils/types.js +0 -1
- package/lib/esm/internal/utils/types.js.map +0 -7
- package/lib/types/api/app-binder/Errors.d.ts +0 -27
- package/lib/types/api/app-binder/Errors.d.ts.map +0 -1
- package/lib/types/api/app-binder/GetAppNameCommandTypes.d.ts +0 -5
- package/lib/types/api/app-binder/GetAppNameCommandTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/GetSeedIdCommandTypes.d.ts +0 -14
- package/lib/types/api/app-binder/GetSeedIdCommandTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/InitCommandTypes.d.ts +0 -5
- package/lib/types/api/app-binder/InitCommandTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/KeypairFromBytes.d.ts +0 -11
- package/lib/types/api/app-binder/KeypairFromBytes.d.ts.map +0 -1
- package/lib/types/api/app-binder/LKRPTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/ParseStreamBlockCommandCommandTypes.d.ts +0 -6
- package/lib/types/api/app-binder/ParseStreamBlockCommandCommandTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/ParseStreamBlockHeaderCommandTypes.d.ts +0 -5
- package/lib/types/api/app-binder/ParseStreamBlockHeaderCommandTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/ParseStreamBlockSignatureTypes.d.ts +0 -5
- package/lib/types/api/app-binder/ParseStreamBlockSignatureTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/SetTrustedMemberTypes.d.ts +0 -6
- package/lib/types/api/app-binder/SetTrustedMemberTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/SignBlockCommandTypes.d.ts +0 -9
- package/lib/types/api/app-binder/SignBlockCommandTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/SignBlockHeaderCommandTypes.d.ts +0 -5
- package/lib/types/api/app-binder/SignBlockHeaderCommandTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/SignBlockSignatureCommandTypes.d.ts +0 -6
- package/lib/types/api/app-binder/SignBlockSignatureCommandTypes.d.ts.map +0 -1
- package/lib/types/api/app-binder/SignBlockSingleCommandTypes.d.ts +0 -5
- package/lib/types/api/app-binder/SignBlockSingleCommandTypes.d.ts.map +0 -1
- package/lib/types/internal/app-binder/device-action/AuthenticateDeviceAction.d.ts +0 -42
- package/lib/types/internal/app-binder/device-action/AuthenticateDeviceAction.d.ts.map +0 -1
- package/lib/types/internal/utils/TLVBuilder.d.ts +0 -15
- package/lib/types/internal/utils/TLVBuilder.d.ts.map +0 -1
- package/lib/types/internal/utils/TLVTags.d.ts.map +0 -1
- package/lib/types/internal/utils/crypto.d.ts +0 -19
- package/lib/types/internal/utils/crypto.d.ts.map +0 -1
- package/lib/types/internal/utils/hex.d.ts +0 -3
- package/lib/types/internal/utils/hex.d.ts.map +0 -1
- package/lib/types/internal/utils/types.d.ts.map +0 -1
- /package/lib/esm/api/{app-binder/GetAppNameCommandTypes.js.map → model/JWT.js.map} +0 -0
- /package/lib/esm/{api/app-binder/GetSeedIdCommandTypes.js.map → internal/app-binder/device-action/models/AuthenticateWithDeviceDeviceActionTypes.js.map} +0 -0
- /package/lib/esm/{api/app-binder/InitCommandTypes.js.map → internal/app-binder/device-action/models/AuthenticateWithKeypairDeviceActionTypes.js.map} +0 -0
- /package/lib/esm/{api/app-binder/ParseStreamBlockCommandCommandTypes.js.map → internal/models/LKRPBlockTypes.js.map} +0 -0
- /package/lib/esm/{api/app-binder/ParseStreamBlockHeaderCommandTypes.js.map → internal/models/LKRPCommandTypes.js.map} +0 -0
- /package/lib/esm/{api/app-binder/ParseStreamBlockSignatureTypes.js.map → internal/models/Types.js.map} +0 -0
|
@@ -1,14 +1,20 @@
|
|
|
1
|
-
import { type DeviceManagementKit
|
|
1
|
+
import { type DeviceManagementKit } from "@ledgerhq/device-management-kit";
|
|
2
|
+
import { type CryptoService } from "./crypto/CryptoService";
|
|
2
3
|
import { type LedgerKeyringProtocol } from "./LedgerKeyringProtocol";
|
|
4
|
+
import { type LKRPEnv } from "./model/Env";
|
|
3
5
|
export declare class LedgerKeyringProtocolBuilder {
|
|
4
6
|
private readonly dmk;
|
|
5
|
-
private readonly
|
|
6
|
-
private readonly
|
|
7
|
-
|
|
7
|
+
private readonly applicationId;
|
|
8
|
+
private readonly env?;
|
|
9
|
+
private readonly baseUrl?;
|
|
10
|
+
private cryptoService;
|
|
11
|
+
constructor(args: {
|
|
8
12
|
dmk: DeviceManagementKit;
|
|
9
|
-
|
|
10
|
-
|
|
13
|
+
applicationId: number;
|
|
14
|
+
env?: LKRPEnv;
|
|
15
|
+
baseUrl?: string;
|
|
11
16
|
});
|
|
17
|
+
withCryptoService(service: CryptoService): LedgerKeyringProtocolBuilder;
|
|
12
18
|
build(): LedgerKeyringProtocol;
|
|
13
19
|
}
|
|
14
20
|
//# sourceMappingURL=LedgerKeyringProtocolBuilder.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LedgerKeyringProtocolBuilder.d.ts","sourceRoot":"","sources":["../../../src/api/LedgerKeyringProtocolBuilder.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"LedgerKeyringProtocolBuilder.d.ts","sourceRoot":"","sources":["../../../src/api/LedgerKeyringProtocolBuilder.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AAE3E,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE/D,OAAO,EAAE,KAAK,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AACxE,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,qBAAa,4BAA4B;IACvC,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAsB;IAC1C,OAAO,CAAC,QAAQ,CAAC,aAAa,CAAS;IACvC,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAU;IAC/B,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAS;IAClC,OAAO,CAAC,aAAa,CAA2C;gBAEpD,IAAI,EAAE;QAChB,GAAG,EAAE,mBAAmB,CAAC;QACzB,aAAa,EAAE,MAAM,CAAC;QACtB,GAAG,CAAC,EAAE,OAAO,CAAC;QACd,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB;IAOD,iBAAiB,CAAC,OAAO,EAAE,aAAa,GAAG,4BAA4B;IAKvE,KAAK,IAAI,qBAAqB;CAS/B"}
|
|
@@ -1,27 +1,41 @@
|
|
|
1
|
-
import { type OpenAppDAError, type
|
|
1
|
+
import { type OpenAppDAError, type UserInteractionRequired } from "@ledgerhq/device-management-kit";
|
|
2
2
|
import { type Either } from "purify-ts";
|
|
3
|
+
import { type CryptoService } from "../crypto/CryptoService";
|
|
4
|
+
import { type KeyPair } from "../crypto/KeyPair";
|
|
5
|
+
import { type LKRPDataSourceError, type LKRPMissingDataError, type LKRPOutdatedTrustchainError, type LKRPParsingError, type LKRPTrustchainNotReady, type LKRPUnknownError } from "../model/Errors";
|
|
6
|
+
import { type JWT } from "../model/JWT";
|
|
7
|
+
import { type Permissions } from "../model/Permissions";
|
|
3
8
|
import { type LKRPDeviceCommandError } from "../../internal/app-binder/command/utils/ledgerKeyringProtocolErrors";
|
|
4
9
|
import { type LKRPDataSource } from "../../internal/lkrp-datasource/data/LKRPDataSource";
|
|
5
|
-
import { type
|
|
6
|
-
import { type Trustchain } from "../../internal/utils/types";
|
|
7
|
-
import { type LKRPHttpRequestError, type LKRPMissingDataError, type LKRPParsingError } from "./Errors";
|
|
8
|
-
import { type JWT, type Keypair, type Permissions } from "./LKRPTypes";
|
|
10
|
+
import { type Trustchain } from "../../internal/utils/Trustchain";
|
|
9
11
|
export type AddToTrustchainDAOutput = undefined;
|
|
10
12
|
export type AddToTrustchainDAInput = Either<LKRPMissingDataError, {
|
|
11
13
|
readonly lkrpDataSource: LKRPDataSource;
|
|
12
|
-
readonly
|
|
14
|
+
readonly cryptoService: CryptoService;
|
|
15
|
+
readonly keyPair: KeyPair;
|
|
13
16
|
readonly jwt: JWT;
|
|
14
|
-
readonly
|
|
17
|
+
readonly appId: number;
|
|
15
18
|
readonly trustchain: Trustchain;
|
|
16
|
-
readonly applicationStream: LKRPBlockStream;
|
|
17
19
|
readonly clientName: string;
|
|
18
20
|
readonly permissions: Permissions;
|
|
19
21
|
}>;
|
|
20
|
-
export type AddToTrustchainDAError = LKRPDeviceCommandError |
|
|
22
|
+
export type AddToTrustchainDAError = LKRPDeviceCommandError | LKRPDataSourceError | LKRPParsingError | LKRPMissingDataError | LKRPOutdatedTrustchainError | LKRPTrustchainNotReady | OpenAppDAError | LKRPUnknownError;
|
|
21
23
|
export type AddToTrustchainDAIntermediateValue = {
|
|
22
|
-
|
|
24
|
+
requiredUserInteraction: UserInteractionRequired.None;
|
|
25
|
+
step?: AddToTrustchaineDAStep.Initialize | AddToTrustchaineDAStep.ParseStream;
|
|
26
|
+
} | {
|
|
27
|
+
requiredUserInteraction: AddToTrustchainDAState.AddMember;
|
|
28
|
+
step: AddToTrustchaineDAStep.AddMember;
|
|
23
29
|
};
|
|
30
|
+
export declare enum AddToTrustchainDAState {
|
|
31
|
+
AddMember = "lkrp-add-member"
|
|
32
|
+
}
|
|
33
|
+
export declare enum AddToTrustchaineDAStep {
|
|
34
|
+
Initialize = "lkrp-init-transaction",
|
|
35
|
+
ParseStream = "lkrp-parse-stream",
|
|
36
|
+
AddMember = "lkrp-add-member"
|
|
37
|
+
}
|
|
24
38
|
export type AddToTrustchainDAInternalState = Either<AddToTrustchainDAError, {
|
|
25
|
-
readonly sessionKeypair:
|
|
39
|
+
readonly sessionKeypair: KeyPair | null;
|
|
26
40
|
}>;
|
|
27
41
|
//# sourceMappingURL=AddToTrustchainDeviceActionTypes.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AddToTrustchainDeviceActionTypes.d.ts","sourceRoot":"","sources":["../../../../src/api/app-binder/AddToTrustchainDeviceActionTypes.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,cAAc,EACnB,KAAK,
|
|
1
|
+
{"version":3,"file":"AddToTrustchainDeviceActionTypes.d.ts","sourceRoot":"","sources":["../../../../src/api/app-binder/AddToTrustchainDeviceActionTypes.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,cAAc,EACnB,KAAK,uBAAuB,EAC7B,MAAM,iCAAiC,CAAC;AACzC,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,WAAW,CAAC;AAExC,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EACL,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,KAAK,2BAA2B,EAChC,KAAK,gBAAgB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,gBAAgB,EACtB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,KAAK,GAAG,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,gEAAgE,CAAC;AAC7G,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,+CAA+C,CAAC;AACpF,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAE7D,MAAM,MAAM,uBAAuB,GAAG,SAAS,CAAC;AAEhD,MAAM,MAAM,sBAAsB,GAAG,MAAM,CACzC,oBAAoB,EACpB;IACE,QAAQ,CAAC,cAAc,EAAE,cAAc,CAAC;IACxC,QAAQ,CAAC,aAAa,EAAE,aAAa,CAAC;IACtC,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC;IAC1B,QAAQ,CAAC,GAAG,EAAE,GAAG,CAAC;IAClB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC;IAChC,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,WAAW,EAAE,WAAW,CAAC;CACnC,CACF,CAAC;AAEF,MAAM,MAAM,sBAAsB,GAC9B,sBAAsB,GACtB,mBAAmB,GACnB,gBAAgB,GAChB,oBAAoB,GACpB,2BAA2B,GAC3B,sBAAsB,GACtB,cAAc,GACd,gBAAgB,CAAC;AAErB,MAAM,MAAM,kCAAkC,GAC1C;IACE,uBAAuB,EAAE,uBAAuB,CAAC,IAAI,CAAC;IACtD,IAAI,CAAC,EACD,sBAAsB,CAAC,UAAU,GACjC,sBAAsB,CAAC,WAAW,CAAC;CACxC,GACD;IACE,uBAAuB,EAAE,sBAAsB,CAAC,SAAS,CAAC;IAC1D,IAAI,EAAE,sBAAsB,CAAC,SAAS,CAAC;CACxC,CAAC;AAEN,oBAAY,sBAAsB;IAChC,SAAS,oBAAoB;CAC9B;AAED,oBAAY,sBAAsB;IAChC,UAAU,0BAA0B;IACpC,WAAW,sBAAsB;IACjC,SAAS,oBAAoB;CAC9B;AAED,MAAM,MAAM,8BAA8B,GAAG,MAAM,CACjD,sBAAsB,EACtB;IACE,QAAQ,CAAC,cAAc,EAAE,OAAO,GAAG,IAAI,CAAC;CACzC,CACF,CAAC"}
|
|
@@ -1,37 +1,33 @@
|
|
|
1
|
-
import { type ExecuteDeviceActionReturnType, type OpenAppDAError, type
|
|
2
|
-
import { type
|
|
1
|
+
import { type ExecuteDeviceActionReturnType, type OpenAppDAError, type OpenAppDARequiredInteraction, type UserInteractionRequired } from "@ledgerhq/device-management-kit";
|
|
2
|
+
import { type LKRPDataSourceError, type LKRPMissingDataError, type LKRPParsingError, type LKRPTrustchainNotReady, type LKRPUnauthorizedError, type LKRPUnknownError } from "../model/Errors";
|
|
3
|
+
import { type JWT } from "../model/JWT";
|
|
3
4
|
import { type LKRPDeviceCommandError } from "../../internal/app-binder/command/utils/ledgerKeyringProtocolErrors";
|
|
4
|
-
import { type
|
|
5
|
-
import { type LKRPBlockStream } from "../../internal/utils/LKRPBlockStream";
|
|
6
|
-
import { type Trustchain } from "../../internal/utils/types";
|
|
7
|
-
import { type LKRPHttpRequestError, type LKRPMissingDataError, type LKRPParsingError, type LKRPUnhandledState } from "./Errors";
|
|
8
|
-
import { type JWT, type Keypair, type Permissions } from "./LKRPTypes";
|
|
5
|
+
import { type AddToTrustchainDAError, type AddToTrustchainDAIntermediateValue } from "./AddToTrustchainDeviceActionTypes";
|
|
9
6
|
export type AuthenticateDAReturnType = ExecuteDeviceActionReturnType<AuthenticateDAOutput, AuthenticateDAError, AuthenticateDAIntermediateValue>;
|
|
10
|
-
export type AuthenticateDAInput = {
|
|
11
|
-
readonly lkrpDataSource: LKRPDataSource;
|
|
12
|
-
readonly applicationId: number;
|
|
13
|
-
readonly keypair: Keypair;
|
|
14
|
-
readonly clientName: string;
|
|
15
|
-
readonly permissions: Permissions;
|
|
16
|
-
readonly trustchainId: string | null;
|
|
17
|
-
readonly jwt: JWT | null;
|
|
18
|
-
};
|
|
19
7
|
export type AuthenticateDAOutput = {
|
|
20
|
-
readonly jwt: JWT
|
|
21
|
-
readonly trustchainId: string
|
|
22
|
-
readonly applicationPath: string
|
|
23
|
-
readonly encryptionKey: Uint8Array
|
|
8
|
+
readonly jwt: JWT;
|
|
9
|
+
readonly trustchainId: string;
|
|
10
|
+
readonly applicationPath: string;
|
|
11
|
+
readonly encryptionKey: Uint8Array;
|
|
24
12
|
};
|
|
25
|
-
export type AuthenticateDAError = LKRPDeviceCommandError |
|
|
13
|
+
export type AuthenticateDAError = LKRPUnauthorizedError | AddToTrustchainDAError | LKRPDeviceCommandError | LKRPDataSourceError | LKRPParsingError | LKRPMissingDataError | LKRPTrustchainNotReady | OpenAppDAError | LKRPUnknownError;
|
|
26
14
|
export type AuthenticateDAIntermediateValue = {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
15
|
+
requiredUserInteraction: OpenAppDARequiredInteraction;
|
|
16
|
+
step: AuthenticateDAStep.OpenApp;
|
|
17
|
+
} | {
|
|
18
|
+
requiredUserInteraction: AuthenticateDAState.Authenticate;
|
|
19
|
+
step: AuthenticateDAStep.Authenticate;
|
|
20
|
+
} | {
|
|
21
|
+
requiredUserInteraction: UserInteractionRequired.None;
|
|
22
|
+
step?: AuthenticateDAStep.Authenticate | AuthenticateDAStep.GetTrustchain | AuthenticateDAStep.ExtractEncryptionKey;
|
|
23
|
+
} | AddToTrustchainDAIntermediateValue;
|
|
24
|
+
export declare enum AuthenticateDAState {
|
|
25
|
+
Authenticate = "lkrp-authenticate"
|
|
26
|
+
}
|
|
27
|
+
export declare enum AuthenticateDAStep {
|
|
28
|
+
OpenApp = "lkrp.steps.openApp",
|
|
29
|
+
Authenticate = "lkrp.steps.authenticate",
|
|
30
|
+
GetTrustchain = "lkrp.steps.getTrustchain",
|
|
31
|
+
ExtractEncryptionKey = "lkrp.steps.extractEncryptionKey"
|
|
32
|
+
}
|
|
37
33
|
//# sourceMappingURL=AuthenticateDeviceActionTypes.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AuthenticateDeviceActionTypes.d.ts","sourceRoot":"","sources":["../../../../src/api/app-binder/AuthenticateDeviceActionTypes.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,6BAA6B,EAClC,KAAK,cAAc,EACnB,KAAK,
|
|
1
|
+
{"version":3,"file":"AuthenticateDeviceActionTypes.d.ts","sourceRoot":"","sources":["../../../../src/api/app-binder/AuthenticateDeviceActionTypes.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,6BAA6B,EAClC,KAAK,cAAc,EACnB,KAAK,4BAA4B,EACjC,KAAK,uBAAuB,EAC7B,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EACL,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,KAAK,gBAAgB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,EACtB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,KAAK,GAAG,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,gEAAgE,CAAC;AAE7G,OAAO,EACL,KAAK,sBAAsB,EAC3B,KAAK,kCAAkC,EACxC,MAAM,oCAAoC,CAAC;AAE5C,MAAM,MAAM,wBAAwB,GAAG,6BAA6B,CAClE,oBAAoB,EACpB,mBAAmB,EACnB,+BAA+B,CAChC,CAAC;AAEF,MAAM,MAAM,oBAAoB,GAAG;IACjC,QAAQ,CAAC,GAAG,EAAE,GAAG,CAAC;IAClB,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,eAAe,EAAE,MAAM,CAAC;IACjC,QAAQ,CAAC,aAAa,EAAE,UAAU,CAAC;CACpC,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAC3B,qBAAqB,GACrB,sBAAsB,GACtB,sBAAsB,GACtB,mBAAmB,GACnB,gBAAgB,GAChB,oBAAoB,GACpB,sBAAsB,GACtB,cAAc,GACd,gBAAgB,CAAC;AAErB,MAAM,MAAM,+BAA+B,GACvC;IACE,uBAAuB,EAAE,4BAA4B,CAAC;IACtD,IAAI,EAAE,kBAAkB,CAAC,OAAO,CAAC;CAClC,GACD;IACE,uBAAuB,EAAE,mBAAmB,CAAC,YAAY,CAAC;IAC1D,IAAI,EAAE,kBAAkB,CAAC,YAAY,CAAC;CACvC,GACD;IACE,uBAAuB,EAAE,uBAAuB,CAAC,IAAI,CAAC;IACtD,IAAI,CAAC,EACD,kBAAkB,CAAC,YAAY,GAC/B,kBAAkB,CAAC,aAAa,GAChC,kBAAkB,CAAC,oBAAoB,CAAC;CAC7C,GACD,kCAAkC,CAAC;AAEvC,oBAAY,mBAAmB;IAC7B,YAAY,sBAAsB;CACnC;AACD,oBAAY,kBAAkB;IAC5B,OAAO,uBAAuB;IAC9B,YAAY,4BAA4B;IACxC,aAAa,6BAA6B;IAC1C,oBAAoB,oCAAoC;CACzD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GetVersionCommandTypes.d.ts","sourceRoot":"","sources":["../../../../src/api/app-binder/GetVersionCommandTypes.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,yBAAyB,GAAG;IACtC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B,CAAC
|
|
1
|
+
{"version":3,"file":"GetVersionCommandTypes.d.ts","sourceRoot":"","sources":["../../../../src/api/app-binder/GetVersionCommandTypes.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,yBAAyB,GAAG;IACtC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { type Key } from "./Key";
|
|
2
|
+
import { type KeyPair } from "./KeyPair";
|
|
3
|
+
export declare enum Curve {
|
|
4
|
+
K256 = 0,// secp256k1
|
|
5
|
+
P256 = 1
|
|
6
|
+
}
|
|
7
|
+
export declare enum EncryptionAlgo {
|
|
8
|
+
AES256_GCM = 0
|
|
9
|
+
}
|
|
10
|
+
export declare enum HashAlgo {
|
|
11
|
+
SHA256 = 0
|
|
12
|
+
}
|
|
13
|
+
export interface CryptoService {
|
|
14
|
+
randomBytes(len: number): Uint8Array;
|
|
15
|
+
hash(bytes: Uint8Array, algo: HashAlgo): Uint8Array;
|
|
16
|
+
hmac(key: Uint8Array, message: Uint8Array, algo: HashAlgo): Uint8Array;
|
|
17
|
+
createKeyPair(curve: Curve): Promise<KeyPair>;
|
|
18
|
+
importKeyPair(privateKey: Uint8Array, curve: Curve): KeyPair;
|
|
19
|
+
createSymmetricKey(algo: EncryptionAlgo): Promise<Key>;
|
|
20
|
+
importSymmetricKey(keyMaterial: Uint8Array, algo: EncryptionAlgo): Key;
|
|
21
|
+
}
|
|
22
|
+
//# sourceMappingURL=CryptoService.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CryptoService.d.ts","sourceRoot":"","sources":["../../../../src/api/crypto/CryptoService.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,GAAG,EAAE,MAAM,OAAO,CAAC;AACjC,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,WAAW,CAAC;AAEzC,oBAAY,KAAK;IACf,IAAI,IAAA,CAAE,YAAY;IAClB,IAAI,IAAA;CACL;AAED,oBAAY,cAAc;IACxB,UAAU,IAAA;CACX;AAED,oBAAY,QAAQ;IAClB,MAAM,IAAA;CACP;AAED,MAAM,WAAW,aAAa;IAE5B,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU,CAAC;IAGrC,IAAI,CAAC,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,GAAG,UAAU,CAAC;IAGpD,IAAI,CAAC,GAAG,EAAE,UAAU,EAAE,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,GAAG,UAAU,CAAC;IAGvE,aAAa,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;IAG9C,aAAa,CAAC,UAAU,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,GAAG,OAAO,CAAC;IAG7D,kBAAkB,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;IAGvD,kBAAkB,CAAC,WAAW,EAAE,UAAU,EAAE,IAAI,EAAE,cAAc,GAAG,GAAG,CAAC;CACxE"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export declare const AES256_KEY_SIZE = 32;
|
|
2
|
+
export declare const AES256_BLOCK_SIZE = 16;
|
|
3
|
+
export interface Key {
|
|
4
|
+
encrypt(iv: Uint8Array, data: Uint8Array): Promise<Uint8Array>;
|
|
5
|
+
decrypt(iv: Uint8Array, encryptedData: Uint8Array): Promise<Uint8Array>;
|
|
6
|
+
}
|
|
7
|
+
//# sourceMappingURL=Key.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Key.d.ts","sourceRoot":"","sources":["../../../../src/api/crypto/Key.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,eAAe,KAAK,CAAC;AAClC,eAAO,MAAM,iBAAiB,KAAK,CAAC;AAEpC,MAAM,WAAW,GAAG;IAClB,OAAO,CAAC,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IAC/D,OAAO,CAAC,EAAE,EAAE,UAAU,EAAE,aAAa,EAAE,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;CACzE"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare enum SigFormat {
|
|
2
|
+
COMPACT = 0,
|
|
3
|
+
DER = 1
|
|
4
|
+
}
|
|
5
|
+
export interface KeyPair {
|
|
6
|
+
id: string;
|
|
7
|
+
sign(data: Uint8Array, format?: SigFormat): Promise<Uint8Array>;
|
|
8
|
+
verify(data: Uint8Array, signature: Uint8Array, format?: SigFormat): Promise<boolean>;
|
|
9
|
+
deriveSharedSecret(peerPublicKey: Uint8Array): Promise<Uint8Array>;
|
|
10
|
+
getPublicKey(): Uint8Array;
|
|
11
|
+
getPublicKeyToHex(): string;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=KeyPair.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"KeyPair.d.ts","sourceRoot":"","sources":["../../../../src/api/crypto/KeyPair.ts"],"names":[],"mappings":"AAAA,oBAAY,SAAS;IACnB,OAAO,IAAA;IACP,GAAG,IAAA;CACJ;AAED,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,CAAC,IAAI,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IAChE,MAAM,CACJ,IAAI,EAAE,UAAU,EAChB,SAAS,EAAE,UAAU,EACrB,MAAM,CAAC,EAAE,SAAS,GACjB,OAAO,CAAC,OAAO,CAAC,CAAC;IACpB,kBAAkB,CAAC,aAAa,EAAE,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IACnE,YAAY,IAAI,UAAU,CAAC;IAC3B,iBAAiB,IAAI,MAAM,CAAC;CAC7B"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { type CryptoService, type Curve, type EncryptionAlgo, HashAlgo } from "../../crypto/CryptoService";
|
|
2
|
+
import { type Key } from "../../crypto/Key";
|
|
3
|
+
import { type KeyPair } from "../../crypto/KeyPair";
|
|
4
|
+
export declare class NobleCryptoService implements CryptoService {
|
|
5
|
+
randomBytes(len: number): Uint8Array;
|
|
6
|
+
hash(bytes: Uint8Array, algo: HashAlgo): Uint8Array;
|
|
7
|
+
hmac(key: Uint8Array, message: Uint8Array, algo: HashAlgo): Uint8Array;
|
|
8
|
+
createKeyPair(curve: Curve): Promise<KeyPair>;
|
|
9
|
+
importKeyPair(privateKey: Uint8Array, curve: Curve): KeyPair;
|
|
10
|
+
createSymmetricKey(algo: EncryptionAlgo): Promise<Key>;
|
|
11
|
+
importSymmetricKey(keyMaterial: Uint8Array, algo: EncryptionAlgo): Key;
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=NobleCryptoService.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NobleCryptoService.d.ts","sourceRoot":"","sources":["../../../../../src/api/crypto/noble/NobleCryptoService.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,KAAK,aAAa,EAClB,KAAK,KAAK,EACV,KAAK,cAAc,EACnB,QAAQ,EACT,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,KAAK,GAAG,EAAE,MAAM,iBAAiB,CAAC;AAC3C,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAKnD,qBAAa,kBAAmB,YAAW,aAAa;IACtD,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,UAAU;IAIpC,IAAI,CAAC,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,GAAG,UAAU;IASnD,IAAI,CAAC,GAAG,EAAE,UAAU,EAAE,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,GAAG,UAAU;IAShE,aAAa,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAAC,OAAO,CAAC;IAInD,aAAa,CAAC,UAAU,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,GAAG,OAAO;IAItD,kBAAkB,CAAC,IAAI,EAAE,cAAc,GAAG,OAAO,CAAC,GAAG,CAAC;IAI5D,kBAAkB,CAAC,WAAW,EAAE,UAAU,EAAE,IAAI,EAAE,cAAc,GAAG,GAAG;CAGvE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NobleCryptoService.test.d.ts","sourceRoot":"","sources":["../../../../../src/api/crypto/noble/NobleCryptoService.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { EncryptionAlgo } from "../../crypto/CryptoService";
|
|
2
|
+
import { type Key } from "../../crypto/Key";
|
|
3
|
+
export declare class NobleKey implements Key {
|
|
4
|
+
private key;
|
|
5
|
+
static generate(algo?: EncryptionAlgo): Promise<NobleKey>;
|
|
6
|
+
static from(keyMaterial: Uint8Array, algo?: EncryptionAlgo): NobleKey;
|
|
7
|
+
private constructor();
|
|
8
|
+
encrypt(iv: Uint8Array, data: Uint8Array): Promise<Uint8Array>;
|
|
9
|
+
decrypt(iv: Uint8Array, encryptedData: Uint8Array): Promise<Uint8Array>;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=NobleKey.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NobleKey.d.ts","sourceRoot":"","sources":["../../../../../src/api/crypto/noble/NobleKey.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC3D,OAAO,EAAsC,KAAK,GAAG,EAAE,MAAM,iBAAiB,CAAC;AAE/E,qBAAa,QAAS,YAAW,GAAG;IAoBd,OAAO,CAAC,GAAG;WAnBlB,QAAQ,CACnB,IAAI,GAAE,cAA0C,GAC/C,OAAO,CAAC,QAAQ,CAAC;IAOpB,MAAM,CAAC,IAAI,CACT,WAAW,EAAE,UAAU,EACvB,IAAI,GAAE,cAA0C,GAC/C,QAAQ;IAOX,OAAO;IAED,OAAO,CAAC,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC;IAK9D,OAAO,CACX,EAAE,EAAE,UAAU,EACd,aAAa,EAAE,UAAU,GACxB,OAAO,CAAC,UAAU,CAAC;CAIvB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NobleKey.test.d.ts","sourceRoot":"","sources":["../../../../../src/api/crypto/noble/NobleKey.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Curve } from "../../crypto/CryptoService";
|
|
2
|
+
import { type KeyPair, SigFormat } from "../../crypto/KeyPair";
|
|
3
|
+
export declare class NobleKeyPair implements KeyPair {
|
|
4
|
+
private curve;
|
|
5
|
+
private privateKey;
|
|
6
|
+
private publicKey;
|
|
7
|
+
static generate(curve: Curve): Promise<NobleKeyPair>;
|
|
8
|
+
static from(privateKey: Uint8Array, curve: Curve): NobleKeyPair;
|
|
9
|
+
private static getCurve;
|
|
10
|
+
private constructor();
|
|
11
|
+
get id(): `0x${string}`;
|
|
12
|
+
sign(data: Uint8Array, format?: SigFormat): Promise<Uint8Array>;
|
|
13
|
+
verify(data: Uint8Array, signature: Uint8Array, format?: SigFormat): Promise<boolean>;
|
|
14
|
+
deriveSharedSecret(peerPublicKey: Uint8Array, isCompressed?: boolean): Promise<Uint8Array>;
|
|
15
|
+
getPublicKey(): Uint8Array;
|
|
16
|
+
getPublicKeyToHex(): string;
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=NobleKeyPair.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NobleKeyPair.d.ts","sourceRoot":"","sources":["../../../../../src/api/crypto/noble/NobleKeyPair.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAClD,OAAO,EAAE,KAAK,OAAO,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAE9D,qBAAa,YAAa,YAAW,OAAO;IAyBxC,OAAO,CAAC,KAAK;IACb,OAAO,CAAC,UAAU;IAClB,OAAO,CAAC,SAAS;WA1BN,QAAQ,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,CAAC,YAAY,CAAC;IAM1D,MAAM,CAAC,IAAI,CAAC,UAAU,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,GAAG,YAAY;IAM/D,OAAO,CAAC,MAAM,CAAC,QAAQ;IAWvB,OAAO;IAMP,IAAI,EAAE,kBAEL;IAEK,IAAI,CAAC,IAAI,EAAE,UAAU,EAAE,MAAM,CAAC,EAAE,SAAS,GAAG,OAAO,CAAC,UAAU,CAAC;IAM/D,MAAM,CACV,IAAI,EAAE,UAAU,EAChB,SAAS,EAAE,UAAU,EACrB,MAAM,CAAC,EAAE,SAAS,GACjB,OAAO,CAAC,OAAO,CAAC;IAMb,kBAAkB,CACtB,aAAa,EAAE,UAAU,EACzB,YAAY,GAAE,OAAc,GAC3B,OAAO,CAAC,UAAU,CAAC;IAQtB,YAAY,IAAI,UAAU;IAI1B,iBAAiB,IAAI,MAAM;CAG5B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"NobleKeyPair.test.d.ts","sourceRoot":"","sources":["../../../../../src/api/crypto/noble/NobleKeyPair.test.ts"],"names":[],"mappings":""}
|
package/lib/types/api/index.d.ts
CHANGED
|
@@ -1,6 +1,14 @@
|
|
|
1
1
|
export * from "./app-binder/AuthenticateDeviceActionTypes";
|
|
2
|
-
export * from "./
|
|
3
|
-
export * from "./
|
|
2
|
+
export * from "./crypto/CryptoService";
|
|
3
|
+
export * from "./crypto/Key";
|
|
4
|
+
export * from "./crypto/KeyPair";
|
|
5
|
+
export * from "./crypto/noble/NobleCryptoService";
|
|
6
|
+
export * from "./crypto/noble/NobleKey";
|
|
7
|
+
export * from "./crypto/noble/NobleKeyPair";
|
|
8
|
+
export * from "./model/Env";
|
|
9
|
+
export * from "./model/Errors";
|
|
10
|
+
export * from "./model/JWT";
|
|
11
|
+
export * from "./model/Permissions";
|
|
4
12
|
export * from "./LedgerKeyringProtocol";
|
|
5
13
|
export * from "./LedgerKeyringProtocolBuilder";
|
|
6
14
|
export * from "../internal/externalTypes";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,4CAA4C,CAAC;AAC3D,cAAc
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,4CAA4C,CAAC;AAC3D,cAAc,wBAAwB,CAAC;AACvC,cAAc,cAAc,CAAC;AAC7B,cAAc,kBAAkB,CAAC;AACjC,cAAc,mCAAmC,CAAC;AAClD,cAAc,yBAAyB,CAAC;AACxC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CAAC;AAC5B,cAAc,qBAAqB,CAAC;AACpC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,mCAAmC,CAAC;AAClD,cAAc,yBAAyB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Env.d.ts","sourceRoot":"","sources":["../../../../src/api/model/Env.ts"],"names":[],"mappings":"AAAA,oBAAY,OAAO;IACjB,IAAI,SAAS;IACb,OAAO,YAAY;CACpB"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { GeneralDmkError } from "@ledgerhq/device-management-kit";
|
|
2
|
+
export type LKRPDataSourceErrorStatus = "UNAUTHORIZED" | "BAD_REQUEST" | "UNKNOWN";
|
|
3
|
+
export declare class LKRPDataSourceError extends GeneralDmkError {
|
|
4
|
+
readonly err: {
|
|
5
|
+
status: LKRPDataSourceErrorStatus;
|
|
6
|
+
message: string;
|
|
7
|
+
};
|
|
8
|
+
_tag: string;
|
|
9
|
+
readonly message: string;
|
|
10
|
+
readonly status: LKRPDataSourceErrorStatus;
|
|
11
|
+
constructor(err: {
|
|
12
|
+
status: LKRPDataSourceErrorStatus;
|
|
13
|
+
message: string;
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
export declare class LKRPUnauthorizedError extends GeneralDmkError {
|
|
17
|
+
readonly trustchainId: string | null;
|
|
18
|
+
readonly message: string;
|
|
19
|
+
_tag: string;
|
|
20
|
+
constructor(trustchainId?: string | null, message?: string);
|
|
21
|
+
}
|
|
22
|
+
export declare class LKRPOutdatedTrustchainError extends GeneralDmkError {
|
|
23
|
+
readonly message: string;
|
|
24
|
+
_tag: string;
|
|
25
|
+
constructor(message?: string);
|
|
26
|
+
}
|
|
27
|
+
export declare class LKRPTrustchainNotReady extends GeneralDmkError {
|
|
28
|
+
readonly message: string;
|
|
29
|
+
readonly _tag = "LedgerKeyringProtocolError";
|
|
30
|
+
constructor(message?: string);
|
|
31
|
+
}
|
|
32
|
+
export declare class LKRPParsingError extends GeneralDmkError {
|
|
33
|
+
readonly err?: unknown | undefined;
|
|
34
|
+
readonly _tag = "LedgerKeyringProtocolError";
|
|
35
|
+
constructor(err?: unknown | undefined);
|
|
36
|
+
}
|
|
37
|
+
export declare class LKRPMissingDataError extends GeneralDmkError {
|
|
38
|
+
readonly err?: unknown | undefined;
|
|
39
|
+
readonly _tag = "LedgerKeyringProtocolError";
|
|
40
|
+
constructor(err?: unknown | undefined);
|
|
41
|
+
}
|
|
42
|
+
export declare class LKRPUnsupportedCommandError extends GeneralDmkError {
|
|
43
|
+
readonly command: unknown;
|
|
44
|
+
readonly _tag = "LedgerKeyringProtocolError";
|
|
45
|
+
readonly message: string;
|
|
46
|
+
constructor(command: unknown);
|
|
47
|
+
}
|
|
48
|
+
export declare class LKRPUnknownError extends GeneralDmkError {
|
|
49
|
+
readonly message: string;
|
|
50
|
+
readonly _tag = "LedgerKeyringProtocolError";
|
|
51
|
+
constructor(message: string);
|
|
52
|
+
}
|
|
53
|
+
//# sourceMappingURL=Errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Errors.d.ts","sourceRoot":"","sources":["../../../../src/api/model/Errors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,iCAAiC,CAAC;AAElE,MAAM,MAAM,yBAAyB,GACjC,cAAc,GACd,aAAa,GACb,SAAS,CAAC;AAEd,qBAAa,mBAAoB,SAAQ,eAAe;IAMpD,QAAQ,CAAC,GAAG,EAAE;QACZ,MAAM,EAAE,yBAAyB,CAAC;QAClC,OAAO,EAAE,MAAM,CAAC;KACjB;IARM,IAAI,SAAgC;IAC7C,SAAgB,OAAO,EAAE,MAAM,CAAC;IAChC,SAAgB,MAAM,EAAE,yBAAyB,CAAC;gBAGvC,GAAG,EAAE;QACZ,MAAM,EAAE,yBAAyB,CAAC;QAClC,OAAO,EAAE,MAAM,CAAC;KACjB;CAMJ;AAED,qBAAa,qBAAsB,SAAQ,eAAe;IAGtD,QAAQ,CAAC,YAAY,EAAE,MAAM,GAAG,IAAI;IACpC,QAAQ,CAAC,OAAO,EAAE,MAAM;IAHjB,IAAI,SAAgC;gBAElC,YAAY,GAAE,MAAM,GAAG,IAAW,EAClC,OAAO,GAAE,MAAsG;CAI3H;AAED,qBAAa,2BAA4B,SAAQ,eAAe;IAElD,QAAQ,CAAC,OAAO;IADnB,IAAI,SAAgC;gBACxB,OAAO,SAAgC;CAG7D;AAED,qBAAa,sBAAuB,SAAQ,eAAe;IAGvD,QAAQ,CAAC,OAAO;IAFlB,SAAkB,IAAI,gCAAgC;gBAE3C,OAAO,SAAuE;CAI1F;AAED,qBAAa,gBAAiB,SAAQ,eAAe;IAEvC,QAAQ,CAAC,GAAG,CAAC,EAAE,OAAO;IADlC,SAAkB,IAAI,gCAAgC;gBACjC,GAAG,CAAC,EAAE,OAAO,YAAA;CAGnC;AAED,qBAAa,oBAAqB,SAAQ,eAAe;IAE3C,QAAQ,CAAC,GAAG,CAAC,EAAE,OAAO;IADlC,SAAkB,IAAI,gCAAgC;gBACjC,GAAG,CAAC,EAAE,OAAO,YAAA;CAGnC;AAED,qBAAa,2BAA4B,SAAQ,eAAe;IAGlD,QAAQ,CAAC,OAAO,EAAE,OAAO;IAFrC,SAAkB,IAAI,gCAAgC;IACtD,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;gBACJ,OAAO,EAAE,OAAO;CActC;AAED,qBAAa,gBAAiB,SAAQ,eAAe;IAEvC,QAAQ,CAAC,OAAO,EAAE,MAAM;IADpC,SAAkB,IAAI,gCAAgC;gBACjC,OAAO,EAAE,MAAM;CAGrC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"JWT.d.ts","sourceRoot":"","sources":["../../../../src/api/model/JWT.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,GAAG,GAAG;IAChB,YAAY,EAAE,MAAM,CAAC;IACrB,WAAW,EAAE;QACX,CAAC,YAAY,EAAE,MAAM,GAAG;YACtB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;SAC1B,CAAC;KACH,CAAC;CACH,CAAC"}
|
|
@@ -1,17 +1,3 @@
|
|
|
1
|
-
export interface Keypair {
|
|
2
|
-
pubKeyToU8a(): Uint8Array;
|
|
3
|
-
pubKeyToHex(): string;
|
|
4
|
-
sign(message: Uint8Array): Promise<Uint8Array>;
|
|
5
|
-
ecdh(publicKey: Uint8Array): Uint8Array;
|
|
6
|
-
}
|
|
7
|
-
export type JWT = {
|
|
8
|
-
access_token: string;
|
|
9
|
-
permissions: {
|
|
10
|
-
[trustchainId: string]: {
|
|
11
|
-
[path: string]: string[];
|
|
12
|
-
};
|
|
13
|
-
};
|
|
14
|
-
};
|
|
15
1
|
/**
|
|
16
2
|
* https://ledgerhq.atlassian.net/wiki/spaces/TA/pages/5865144361/ARCH+LKRP+-+v2+specifications#Member-permissions
|
|
17
3
|
*/
|
|
@@ -21,4 +7,4 @@ export declare enum Permissions {
|
|
|
21
7
|
CAN_DERIVE = 2,// The member can have access to the stream chain code (if a member have access to the private key and the chain code it is able to derive sub-streams)
|
|
22
8
|
CAN_ADD_BLOCK = 4
|
|
23
9
|
}
|
|
24
|
-
//# sourceMappingURL=
|
|
10
|
+
//# sourceMappingURL=Permissions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Permissions.d.ts","sourceRoot":"","sources":["../../../../src/api/model/Permissions.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,oBAAY,WAAW;IACrB,KAAK,aAAa,CAAE,iDAAiD;IACrE,WAAW,IAAI,CAAE,uDAAuD;IACxE,UAAU,IAAS,CAAE,uJAAuJ;IAC5K,aAAa,IAAS;CACvB"}
|
|
@@ -1,20 +1,23 @@
|
|
|
1
|
-
import { type DeviceManagementKit
|
|
2
|
-
import { Maybe } from "purify-ts";
|
|
1
|
+
import { type DeviceManagementKit } from "@ledgerhq/device-management-kit";
|
|
3
2
|
import { type AuthenticateDAReturnType } from "../api/app-binder/AuthenticateDeviceActionTypes";
|
|
4
|
-
import { type
|
|
3
|
+
import { type CryptoService } from "../api/crypto/CryptoService";
|
|
5
4
|
import { type LedgerKeyringProtocol } from "../api/LedgerKeyringProtocol";
|
|
5
|
+
import { type LKRPEnv } from "../api/model/Env";
|
|
6
|
+
import { type AuthenticateUsecaseInput } from "./use-cases/authentication/AuthenticateUseCase";
|
|
6
7
|
type DefaultLedgerKeyringProtocolConstructorArgs = {
|
|
7
8
|
dmk: DeviceManagementKit;
|
|
8
|
-
|
|
9
|
-
|
|
9
|
+
applicationId: number;
|
|
10
|
+
cryptoService: CryptoService;
|
|
11
|
+
env?: LKRPEnv;
|
|
12
|
+
baseUrl?: string;
|
|
10
13
|
};
|
|
11
14
|
export declare class DefaultLedgerKeyringProtocol implements LedgerKeyringProtocol {
|
|
12
15
|
name: string;
|
|
13
16
|
private _container;
|
|
14
|
-
constructor({ dmk,
|
|
15
|
-
authenticate(
|
|
16
|
-
encryptData(encryptionKey: Uint8Array, data: Uint8Array): Uint8Array
|
|
17
|
-
decryptData(encryptionKey: Uint8Array, data: Uint8Array):
|
|
17
|
+
constructor({ dmk, applicationId, cryptoService, env, baseUrl, }: DefaultLedgerKeyringProtocolConstructorArgs);
|
|
18
|
+
authenticate(input: AuthenticateUsecaseInput): AuthenticateDAReturnType;
|
|
19
|
+
encryptData(encryptionKey: Uint8Array, data: Uint8Array): Promise<Uint8Array>;
|
|
20
|
+
decryptData(encryptionKey: Uint8Array, data: Uint8Array): Promise<Uint8Array>;
|
|
18
21
|
}
|
|
19
22
|
export {};
|
|
20
23
|
//# sourceMappingURL=DefaultLedgerKeyringProtocol.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DefaultLedgerKeyringProtocol.d.ts","sourceRoot":"","sources":["../../../src/internal/DefaultLedgerKeyringProtocol.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"DefaultLedgerKeyringProtocol.d.ts","sourceRoot":"","sources":["../../../src/internal/DefaultLedgerKeyringProtocol.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AAG3E,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,+CAA+C,CAAC;AAC9F,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,KAAK,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AACxE,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAG9C,OAAO,EAEL,KAAK,wBAAwB,EAC9B,MAAM,gDAAgD,CAAC;AAKxD,KAAK,2CAA2C,GAAG;IACjD,GAAG,EAAE,mBAAmB,CAAC;IACzB,aAAa,EAAE,MAAM,CAAC;IACtB,aAAa,EAAE,aAAa,CAAC;IAC7B,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF,qBAAa,4BAA6B,YAAW,qBAAqB;IACxE,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,UAAU,CAAY;gBAElB,EACV,GAAG,EACH,aAAa,EACb,aAAa,EACb,GAAG,EACH,OAAO,GACR,EAAE,2CAA2C;IAW9C,YAAY,CAAC,KAAK,EAAE,wBAAwB,GAAG,wBAAwB;IAMvE,WAAW,CACT,aAAa,EAAE,UAAU,EACzB,IAAI,EAAE,UAAU,GACf,OAAO,CAAC,UAAU,CAAC;IAMtB,WAAW,CACT,aAAa,EAAE,UAAU,EACzB,IAAI,EAAE,UAAU,GACf,OAAO,CAAC,UAAU,CAAC;CAKvB"}
|
|
@@ -1,23 +1,29 @@
|
|
|
1
1
|
import { DeviceManagementKit, type DeviceSessionId } from "@ledgerhq/device-management-kit";
|
|
2
2
|
import { AuthenticateDAReturnType } from "../../api/app-binder/AuthenticateDeviceActionTypes";
|
|
3
3
|
import { GetVersionDAReturnType } from "../../api/app-binder/GetVersionDeviceActionTypes";
|
|
4
|
-
import {
|
|
4
|
+
import { type CryptoService } from "../../api/crypto/CryptoService";
|
|
5
|
+
import { KeyPair } from "../../api/crypto/KeyPair";
|
|
6
|
+
import { Permissions } from "../../api/model/Permissions";
|
|
5
7
|
import { type LKRPDataSource } from "../lkrp-datasource/data/LKRPDataSource";
|
|
6
8
|
export declare class LedgerKeyringProtocolBinder {
|
|
7
9
|
private readonly dmk;
|
|
8
|
-
private readonly
|
|
10
|
+
private readonly applicationId;
|
|
11
|
+
private readonly cryptoService;
|
|
9
12
|
private readonly lkrpDataSource;
|
|
10
|
-
constructor(dmk: DeviceManagementKit,
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
13
|
+
constructor(dmk: DeviceManagementKit, applicationId: number, cryptoService: CryptoService, lkrpDataSource: LKRPDataSource);
|
|
14
|
+
authenticateWithKeypair(args: {
|
|
15
|
+
keyPair: KeyPair;
|
|
16
|
+
trustchainId: string;
|
|
17
|
+
}): AuthenticateDAReturnType;
|
|
18
|
+
authenticateWithDevice(args: {
|
|
19
|
+
keyPair: KeyPair;
|
|
14
20
|
clientName: string;
|
|
15
21
|
permissions: Permissions;
|
|
16
|
-
|
|
17
|
-
jwt?: JWT;
|
|
22
|
+
sessionId: DeviceSessionId;
|
|
18
23
|
}): AuthenticateDAReturnType;
|
|
19
24
|
getVersion(args: {
|
|
20
25
|
skipOpenApp: boolean;
|
|
26
|
+
sessionId: DeviceSessionId;
|
|
21
27
|
}): GetVersionDAReturnType;
|
|
22
28
|
getAppName(): unknown;
|
|
23
29
|
getSeedId(): unknown;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LedgerKeyringProtocolBinder.d.ts","sourceRoot":"","sources":["../../../../src/internal/app-binder/LedgerKeyringProtocolBinder.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,eAAe,EAGrB,MAAM,iCAAiC,CAAC;AAGzC,OAAO,EAAE,wBAAwB,EAAE,MAAM,+CAA+C,CAAC;AACzF,OAAO,EAAE,sBAAsB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"LedgerKeyringProtocolBinder.d.ts","sourceRoot":"","sources":["../../../../src/internal/app-binder/LedgerKeyringProtocolBinder.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,KAAK,eAAe,EAGrB,MAAM,iCAAiC,CAAC;AAGzC,OAAO,EAAE,wBAAwB,EAAE,MAAM,+CAA+C,CAAC;AACzF,OAAO,EAAE,sBAAsB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAErD,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,+CAA+C,CAAC;AAOpF,qBACa,2BAA2B;IAET,OAAO,CAAC,QAAQ,CAAC,GAAG;IAG/C,OAAO,CAAC,QAAQ,CAAC,aAAa;IAG9B,OAAO,CAAC,QAAQ,CAAC,aAAa;IAG9B,OAAO,CAAC,QAAQ,CAAC,cAAc;gBATa,GAAG,EAAE,mBAAmB,EAGnD,aAAa,EAAE,MAAM,EAGrB,aAAa,EAAE,aAAa,EAG5B,cAAc,EAAE,cAAc;IAGjD,uBAAuB,CAAC,IAAI,EAAE;QAC5B,OAAO,EAAE,OAAO,CAAC;QACjB,YAAY,EAAE,MAAM,CAAC;KACtB,GAAG,wBAAwB;IAY5B,sBAAsB,CAAC,IAAI,EAAE;QAC3B,OAAO,EAAE,OAAO,CAAC;QACjB,UAAU,EAAE,MAAM,CAAC;QACnB,WAAW,EAAE,WAAW,CAAC;QACzB,SAAS,EAAE,eAAe,CAAC;KAC5B,GAAG,wBAAwB;IAgB5B,UAAU,CAAC,IAAI,EAAE;QACf,WAAW,EAAE,OAAO,CAAC;QACrB,SAAS,EAAE,eAAe,CAAC;KAC5B,GAAG,sBAAsB;IAc1B,UAAU,IAAI,OAAO;IAIrB,SAAS,IAAI,OAAO;IAIpB,IAAI,IAAI,OAAO;IAIf,WAAW,IAAI,OAAO;IAItB,SAAS,IAAI,OAAO;IAIpB,gBAAgB,IAAI,OAAO;CAG5B"}
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import { type Apdu, type ApduResponse, type Command, type CommandResult } from "@ledgerhq/device-management-kit";
|
|
2
|
-
import { type GetAppNameCommandArgs, type GetAppNameCommandResponse } from "../../../api/app-binder/GetAppNameCommandTypes";
|
|
3
2
|
import { type LedgerKeyringProtocolErrorCodes } from "./utils/ledgerKeyringProtocolErrors";
|
|
3
|
+
export type GetAppNameCommandResponse = {
|
|
4
|
+
readonly name: string;
|
|
5
|
+
};
|
|
6
|
+
export type GetAppNameCommandArgs = undefined;
|
|
4
7
|
export declare class GetAppNameCommand implements Command<GetAppNameCommandResponse, GetAppNameCommandArgs, LedgerKeyringProtocolErrorCodes> {
|
|
8
|
+
readonly name = "getAppName";
|
|
5
9
|
private readonly errorHelper;
|
|
6
10
|
getApdu(): Apdu;
|
|
7
11
|
parseResponse(apduResponse: ApduResponse): CommandResult<GetAppNameCommandResponse, LedgerKeyringProtocolErrorCodes>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GetAppNameCommand.d.ts","sourceRoot":"","sources":["../../../../../src/internal/app-binder/command/GetAppNameCommand.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,IAAI,EAIT,KAAK,YAAY,EACjB,KAAK,OAAO,EACZ,KAAK,aAAa,EAGnB,MAAM,iCAAiC,CAAC;AAIzC,OAAO,
|
|
1
|
+
{"version":3,"file":"GetAppNameCommand.d.ts","sourceRoot":"","sources":["../../../../../src/internal/app-binder/command/GetAppNameCommand.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,IAAI,EAIT,KAAK,YAAY,EACjB,KAAK,OAAO,EACZ,KAAK,aAAa,EAGnB,MAAM,iCAAiC,CAAC;AAIzC,OAAO,EAEL,KAAK,+BAA+B,EAErC,MAAM,qCAAqC,CAAC;AAE7C,MAAM,MAAM,yBAAyB,GAAG;IACtC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG,SAAS,CAAC;AAE9C,qBAAa,iBACX,YACE,OAAO,CACL,yBAAyB,EACzB,qBAAqB,EACrB,+BAA+B,CAChC;IAEH,QAAQ,CAAC,IAAI,gBAAgB;IAC7B,OAAO,CAAC,QAAQ,CAAC,WAAW,CAG6B;IAEzD,OAAO,IAAI,IAAI;IAYf,aAAa,CACX,YAAY,EAAE,YAAY,GACzB,aAAa,CAAC,yBAAyB,EAAE,+BAA+B,CAAC;CAmB7E"}
|