@nmshd/transport 5.2.1 → 5.3.1
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/LICENSE +1 -1
- package/README.md +2 -2
- package/dist/buildInformation.js +5 -5
- package/dist/core/CoreCrypto.js +2 -2
- package/dist/core/CoreCrypto.js.map +1 -1
- package/dist/core/CoreIdHelper.d.ts +2 -1
- package/dist/core/CoreIdHelper.d.ts.map +1 -1
- package/dist/core/CoreIdHelper.js +11 -6
- package/dist/core/CoreIdHelper.js.map +1 -1
- package/dist/core/CoreSynchronizable.d.ts +4 -4
- package/dist/core/CoreSynchronizable.d.ts.map +1 -1
- package/dist/core/CoreSynchronizable.js +3 -4
- package/dist/core/CoreSynchronizable.js.map +1 -1
- package/dist/core/Reference.d.ts +1 -1
- package/dist/core/Reference.d.ts.map +1 -1
- package/dist/core/Reference.js +7 -7
- package/dist/core/Reference.js.map +1 -1
- package/dist/core/Transport.js +4 -4
- package/dist/core/Transport.js.map +1 -1
- package/dist/core/TransportController.d.ts +2 -2
- package/dist/core/TransportController.d.ts.map +1 -1
- package/dist/core/TransportController.js.map +1 -1
- package/dist/core/{CoreErrors.d.ts → TransportCoreErrors.d.ts} +3 -3
- package/dist/core/TransportCoreErrors.d.ts.map +1 -0
- package/dist/core/TransportCoreErrors.js +147 -0
- package/dist/core/TransportCoreErrors.js.map +1 -0
- package/dist/core/backbone/AuthClient.d.ts +1 -1
- package/dist/core/backbone/AuthClient.d.ts.map +1 -1
- package/dist/core/backbone/AuthClient.js +2 -2
- package/dist/core/backbone/AuthClient.js.map +1 -1
- package/dist/core/backbone/Authenticator.d.ts.map +1 -1
- package/dist/core/backbone/ClientResult.d.ts +1 -1
- package/dist/core/backbone/ClientResult.d.ts.map +1 -1
- package/dist/core/backbone/ClientResult.js +3 -3
- package/dist/core/backbone/ClientResult.js.map +1 -1
- package/dist/core/backbone/RESTClient.js +2 -2
- package/dist/core/backbone/RESTClient.js.map +1 -1
- package/dist/core/backbone/RequestError.d.ts.map +1 -1
- package/dist/core/backbone/RequestError.js +2 -2
- package/dist/core/backbone/RequestError.js.map +1 -1
- package/dist/core/index.d.ts +1 -4
- package/dist/core/index.d.ts.map +1 -1
- package/dist/core/index.js +1 -4
- package/dist/core/index.js.map +1 -1
- package/dist/core/types/CoreHash.d.ts +5 -3
- package/dist/core/types/CoreHash.d.ts.map +1 -1
- package/dist/core/types/CoreHash.js +9 -2
- package/dist/core/types/CoreHash.js.map +1 -1
- package/dist/core/types/index.d.ts +0 -3
- package/dist/core/types/index.d.ts.map +1 -1
- package/dist/core/types/index.js +0 -3
- package/dist/core/types/index.js.map +1 -1
- package/dist/events/PeerDeletedEvent.d.ts +7 -0
- package/dist/events/PeerDeletedEvent.d.ts.map +1 -0
- package/dist/events/PeerDeletedEvent.js +12 -0
- package/dist/events/PeerDeletedEvent.js.map +1 -0
- package/dist/events/PeerDeletionCancelledEvent.d.ts +7 -0
- package/dist/events/PeerDeletionCancelledEvent.d.ts.map +1 -0
- package/dist/events/PeerDeletionCancelledEvent.js +12 -0
- package/dist/events/PeerDeletionCancelledEvent.js.map +1 -0
- package/dist/events/PeerToBeDeletedEvent.d.ts +7 -0
- package/dist/events/PeerToBeDeletedEvent.d.ts.map +1 -0
- package/dist/events/PeerToBeDeletedEvent.js +12 -0
- package/dist/events/PeerToBeDeletedEvent.js.map +1 -0
- package/dist/events/RelationshipDecomposedBySelfEvent.d.ts +1 -1
- package/dist/events/RelationshipDecomposedBySelfEvent.d.ts.map +1 -1
- package/dist/events/index.d.ts +3 -0
- package/dist/events/index.d.ts.map +1 -1
- package/dist/events/index.js +3 -0
- package/dist/events/index.js.map +1 -1
- package/dist/modules/accounts/AccountController.d.ts +2 -1
- package/dist/modules/accounts/AccountController.d.ts.map +1 -1
- package/dist/modules/accounts/AccountController.js +8 -7
- package/dist/modules/accounts/AccountController.js.map +1 -1
- package/dist/modules/accounts/IdentityController.d.ts +2 -1
- package/dist/modules/accounts/IdentityController.d.ts.map +1 -1
- package/dist/modules/accounts/IdentityController.js +1 -1
- package/dist/modules/accounts/IdentityController.js.map +1 -1
- package/dist/modules/accounts/IdentityDeletionProcessController.d.ts +2 -1
- package/dist/modules/accounts/IdentityDeletionProcessController.d.ts.map +1 -1
- package/dist/modules/accounts/IdentityDeletionProcessController.js +2 -1
- package/dist/modules/accounts/IdentityDeletionProcessController.js.map +1 -1
- package/dist/modules/accounts/IdentityUtil.d.ts +1 -1
- package/dist/modules/accounts/IdentityUtil.d.ts.map +1 -1
- package/dist/modules/accounts/IdentityUtil.js +2 -2
- package/dist/modules/accounts/IdentityUtil.js.map +1 -1
- package/dist/modules/accounts/data/CachedIdentityDeletionProcess.d.ts +3 -2
- package/dist/modules/accounts/data/CachedIdentityDeletionProcess.d.ts.map +1 -1
- package/dist/modules/accounts/data/CachedIdentityDeletionProcess.js +12 -12
- package/dist/modules/accounts/data/CachedIdentityDeletionProcess.js.map +1 -1
- package/dist/modules/accounts/data/Identity.d.ts +4 -3
- package/dist/modules/accounts/data/Identity.d.ts.map +1 -1
- package/dist/modules/accounts/data/Identity.js +3 -3
- package/dist/modules/accounts/data/Identity.js.map +1 -1
- package/dist/modules/accounts/data/IdentityDeletionProcess.d.ts +2 -1
- package/dist/modules/accounts/data/IdentityDeletionProcess.d.ts.map +1 -1
- package/dist/modules/accounts/data/IdentityDeletionProcess.js +3 -2
- package/dist/modules/accounts/data/IdentityDeletionProcess.js.map +1 -1
- package/dist/modules/accounts/data/IdentitySecretCredentials.d.ts +3 -3
- package/dist/modules/accounts/data/IdentitySecretCredentials.d.ts.map +1 -1
- package/dist/modules/accounts/data/IdentitySecretCredentials.js +1 -2
- package/dist/modules/accounts/data/IdentitySecretCredentials.js.map +1 -1
- package/dist/modules/certificates/CertificateIssuer.d.ts +2 -1
- package/dist/modules/certificates/CertificateIssuer.d.ts.map +1 -1
- package/dist/modules/certificates/CertificateIssuer.js +2 -1
- package/dist/modules/certificates/CertificateIssuer.js.map +1 -1
- package/dist/modules/certificates/data/Certificate.d.ts +3 -3
- package/dist/modules/certificates/data/Certificate.d.ts.map +1 -1
- package/dist/modules/certificates/data/Certificate.js +1 -1
- package/dist/modules/certificates/data/Certificate.js.map +1 -1
- package/dist/modules/certificates/data/CertificateConstraint.d.ts +3 -3
- package/dist/modules/certificates/data/CertificateConstraint.d.ts.map +1 -1
- package/dist/modules/certificates/data/CertificateConstraint.js +1 -2
- package/dist/modules/certificates/data/CertificateConstraint.js.map +1 -1
- package/dist/modules/certificates/data/CertificateContent.d.ts +6 -5
- package/dist/modules/certificates/data/CertificateContent.d.ts.map +1 -1
- package/dist/modules/certificates/data/CertificateContent.js +6 -6
- package/dist/modules/certificates/data/CertificateContent.js.map +1 -1
- package/dist/modules/certificates/data/CertificateItem.d.ts +3 -3
- package/dist/modules/certificates/data/CertificateItem.d.ts.map +1 -1
- package/dist/modules/certificates/data/CertificateItem.js +1 -2
- package/dist/modules/certificates/data/CertificateItem.js.map +1 -1
- package/dist/modules/certificates/data/constraints/CertificateIdentityConstraint.d.ts +1 -1
- package/dist/modules/certificates/data/constraints/CertificateIdentityConstraint.d.ts.map +1 -1
- package/dist/modules/certificates/data/constraints/CertificateIdentityConstraint.js +2 -2
- package/dist/modules/certificates/data/constraints/CertificateIdentityConstraint.js.map +1 -1
- package/dist/modules/certificates/data/constraints/CertificateTimeConstraint.d.ts +1 -1
- package/dist/modules/certificates/data/constraints/CertificateTimeConstraint.d.ts.map +1 -1
- package/dist/modules/certificates/data/constraints/CertificateTimeConstraint.js +3 -3
- package/dist/modules/certificates/data/constraints/CertificateTimeConstraint.js.map +1 -1
- package/dist/modules/certificates/data/items/CertificatePrivateAttributeItem.d.ts +2 -1
- package/dist/modules/certificates/data/items/CertificatePrivateAttributeItem.d.ts.map +1 -1
- package/dist/modules/certificates/data/items/CertificatePrivateAttributeItem.js +2 -2
- package/dist/modules/certificates/data/items/CertificatePrivateAttributeItem.js.map +1 -1
- package/dist/modules/certificates/data/items/CertificatePrivateAttributeItemSource.d.ts +1 -1
- package/dist/modules/certificates/data/items/CertificatePrivateAttributeItemSource.d.ts.map +1 -1
- package/dist/modules/certificates/data/items/CertificatePrivateAttributeItemSource.js +2 -2
- package/dist/modules/certificates/data/items/CertificatePrivateAttributeItemSource.js.map +1 -1
- package/dist/modules/challenges/ChallengeController.d.ts.map +1 -1
- package/dist/modules/challenges/ChallengeController.js +10 -9
- package/dist/modules/challenges/ChallengeController.js.map +1 -1
- package/dist/modules/challenges/data/Challenge.d.ts +4 -3
- package/dist/modules/challenges/data/Challenge.d.ts.map +1 -1
- package/dist/modules/challenges/data/Challenge.js +6 -6
- package/dist/modules/challenges/data/Challenge.js.map +1 -1
- package/dist/modules/challenges/data/ChallengeSigned.d.ts +3 -4
- package/dist/modules/challenges/data/ChallengeSigned.d.ts.map +1 -1
- package/dist/modules/challenges/data/ChallengeSigned.js +1 -2
- package/dist/modules/challenges/data/ChallengeSigned.js.map +1 -1
- package/dist/modules/devices/DeviceController.d.ts +2 -1
- package/dist/modules/devices/DeviceController.d.ts.map +1 -1
- package/dist/modules/devices/DeviceController.js +4 -4
- package/dist/modules/devices/DeviceController.js.map +1 -1
- package/dist/modules/devices/DeviceSecretController.d.ts.map +1 -1
- package/dist/modules/devices/DeviceSecretController.js +10 -9
- package/dist/modules/devices/DeviceSecretController.js.map +1 -1
- package/dist/modules/devices/DevicesController.d.ts +1 -1
- package/dist/modules/devices/DevicesController.d.ts.map +1 -1
- package/dist/modules/devices/DevicesController.js +9 -8
- package/dist/modules/devices/DevicesController.js.map +1 -1
- package/dist/modules/devices/local/Device.d.ts +1 -2
- package/dist/modules/devices/local/Device.d.ts.map +1 -1
- package/dist/modules/devices/local/Device.js +4 -5
- package/dist/modules/devices/local/Device.js.map +1 -1
- package/dist/modules/devices/local/DeviceSecretCredentials.d.ts +4 -3
- package/dist/modules/devices/local/DeviceSecretCredentials.d.ts.map +1 -1
- package/dist/modules/devices/local/DeviceSecretCredentials.js +3 -3
- package/dist/modules/devices/local/DeviceSecretCredentials.js.map +1 -1
- package/dist/modules/devices/local/SendDeviceParameters.d.ts +3 -3
- package/dist/modules/devices/local/SendDeviceParameters.d.ts.map +1 -1
- package/dist/modules/devices/local/SendDeviceParameters.js +1 -2
- package/dist/modules/devices/local/SendDeviceParameters.js.map +1 -1
- package/dist/modules/devices/transmission/DeviceSharedSecret.d.ts +4 -3
- package/dist/modules/devices/transmission/DeviceSharedSecret.d.ts.map +1 -1
- package/dist/modules/devices/transmission/DeviceSharedSecret.js +5 -5
- package/dist/modules/devices/transmission/DeviceSharedSecret.js.map +1 -1
- package/dist/modules/files/FileController.d.ts +1 -1
- package/dist/modules/files/FileController.d.ts.map +1 -1
- package/dist/modules/files/FileController.js +16 -15
- package/dist/modules/files/FileController.js.map +1 -1
- package/dist/modules/files/local/CachedFile.d.ts +6 -4
- package/dist/modules/files/local/CachedFile.d.ts.map +1 -1
- package/dist/modules/files/local/CachedFile.js +19 -18
- package/dist/modules/files/local/CachedFile.js.map +1 -1
- package/dist/modules/files/local/File.d.ts +2 -1
- package/dist/modules/files/local/File.d.ts.map +1 -1
- package/dist/modules/files/local/File.js +5 -4
- package/dist/modules/files/local/File.js.map +1 -1
- package/dist/modules/files/local/SendFileParameters.d.ts +4 -4
- package/dist/modules/files/local/SendFileParameters.d.ts.map +1 -1
- package/dist/modules/files/local/SendFileParameters.js +4 -5
- package/dist/modules/files/local/SendFileParameters.js.map +1 -1
- package/dist/modules/files/transmission/FileMetadata.d.ts +5 -3
- package/dist/modules/files/transmission/FileMetadata.d.ts.map +1 -1
- package/dist/modules/files/transmission/FileMetadata.js +3 -2
- package/dist/modules/files/transmission/FileMetadata.js.map +1 -1
- package/dist/modules/index.d.ts +1 -0
- package/dist/modules/index.d.ts.map +1 -1
- package/dist/modules/index.js +1 -0
- package/dist/modules/index.js.map +1 -1
- package/dist/modules/messages/MessageController.d.ts +1 -1
- package/dist/modules/messages/MessageController.d.ts.map +1 -1
- package/dist/modules/messages/MessageController.js +31 -30
- package/dist/modules/messages/MessageController.js.map +1 -1
- package/dist/modules/messages/local/CachedMessage.d.ts +3 -4
- package/dist/modules/messages/local/CachedMessage.d.ts.map +1 -1
- package/dist/modules/messages/local/CachedMessage.js +6 -7
- package/dist/modules/messages/local/CachedMessage.js.map +1 -1
- package/dist/modules/messages/local/CachedMessageRecipient.d.ts +4 -4
- package/dist/modules/messages/local/CachedMessageRecipient.d.ts.map +1 -1
- package/dist/modules/messages/local/CachedMessageRecipient.js +6 -7
- package/dist/modules/messages/local/CachedMessageRecipient.js.map +1 -1
- package/dist/modules/messages/local/Message.d.ts +2 -1
- package/dist/modules/messages/local/Message.d.ts.map +1 -1
- package/dist/modules/messages/local/Message.js +6 -5
- package/dist/modules/messages/local/Message.js.map +1 -1
- package/dist/modules/messages/local/SendMessageParameters.d.ts +3 -3
- package/dist/modules/messages/local/SendMessageParameters.d.ts.map +1 -1
- package/dist/modules/messages/local/SendMessageParameters.js +3 -3
- package/dist/modules/messages/local/SendMessageParameters.js.map +1 -1
- package/dist/modules/messages/transmission/MessageContentWrapper.d.ts +3 -5
- package/dist/modules/messages/transmission/MessageContentWrapper.d.ts.map +1 -1
- package/dist/modules/messages/transmission/MessageContentWrapper.js +4 -6
- package/dist/modules/messages/transmission/MessageContentWrapper.js.map +1 -1
- package/dist/modules/messages/transmission/MessageEnvelope.d.ts +4 -3
- package/dist/modules/messages/transmission/MessageEnvelope.d.ts.map +1 -1
- package/dist/modules/messages/transmission/MessageEnvelope.js +8 -8
- package/dist/modules/messages/transmission/MessageEnvelope.js.map +1 -1
- package/dist/modules/messages/transmission/MessageEnvelopeRecipient.d.ts +4 -4
- package/dist/modules/messages/transmission/MessageEnvelopeRecipient.d.ts.map +1 -1
- package/dist/modules/messages/transmission/MessageEnvelopeRecipient.js +5 -6
- package/dist/modules/messages/transmission/MessageEnvelopeRecipient.js.map +1 -1
- package/dist/modules/messages/transmission/MessageSignature.d.ts +4 -3
- package/dist/modules/messages/transmission/MessageSignature.d.ts.map +1 -1
- package/dist/modules/messages/transmission/MessageSignature.js +3 -3
- package/dist/modules/messages/transmission/MessageSignature.js.map +1 -1
- package/dist/modules/messages/transmission/MessageSigned.d.ts +3 -3
- package/dist/modules/messages/transmission/MessageSigned.d.ts.map +1 -1
- package/dist/modules/messages/transmission/MessageSigned.js +1 -2
- package/dist/modules/messages/transmission/MessageSigned.js.map +1 -1
- package/dist/modules/relationshipTemplates/RelationshipTemplateController.d.ts +1 -1
- package/dist/modules/relationshipTemplates/RelationshipTemplateController.d.ts.map +1 -1
- package/dist/modules/relationshipTemplates/RelationshipTemplateController.js +13 -12
- package/dist/modules/relationshipTemplates/RelationshipTemplateController.js.map +1 -1
- package/dist/modules/relationshipTemplates/local/CachedRelationshipTemplate.d.ts +3 -4
- package/dist/modules/relationshipTemplates/local/CachedRelationshipTemplate.d.ts.map +1 -1
- package/dist/modules/relationshipTemplates/local/CachedRelationshipTemplate.js +6 -7
- package/dist/modules/relationshipTemplates/local/CachedRelationshipTemplate.js.map +1 -1
- package/dist/modules/relationshipTemplates/local/RelationshipTemplate.d.ts +1 -1
- package/dist/modules/relationshipTemplates/local/RelationshipTemplate.d.ts.map +1 -1
- package/dist/modules/relationshipTemplates/local/RelationshipTemplate.js +5 -5
- package/dist/modules/relationshipTemplates/local/RelationshipTemplate.js.map +1 -1
- package/dist/modules/relationshipTemplates/local/SendRelationshipTemplateParameters.d.ts +4 -4
- package/dist/modules/relationshipTemplates/local/SendRelationshipTemplateParameters.d.ts.map +1 -1
- package/dist/modules/relationshipTemplates/local/SendRelationshipTemplateParameters.js +3 -3
- package/dist/modules/relationshipTemplates/local/SendRelationshipTemplateParameters.js.map +1 -1
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplateContentWrapper.d.ts +2 -3
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplateContentWrapper.d.ts.map +1 -1
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplateContentWrapper.js +1 -2
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplateContentWrapper.js.map +1 -1
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplatePublicKey.d.ts +1 -1
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplatePublicKey.d.ts.map +1 -1
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplatePublicKey.js +2 -2
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplatePublicKey.js.map +1 -1
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplateSigned.d.ts +3 -3
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplateSigned.d.ts.map +1 -1
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplateSigned.js +1 -2
- package/dist/modules/relationshipTemplates/transmission/RelationshipTemplateSigned.js.map +1 -1
- package/dist/modules/relationships/RelationshipSecretController.d.ts +1 -1
- package/dist/modules/relationships/RelationshipSecretController.d.ts.map +1 -1
- package/dist/modules/relationships/RelationshipSecretController.js +25 -24
- package/dist/modules/relationships/RelationshipSecretController.js.map +1 -1
- package/dist/modules/relationships/RelationshipsController.d.ts +4 -1
- package/dist/modules/relationships/RelationshipsController.d.ts.map +1 -1
- package/dist/modules/relationships/RelationshipsController.js +42 -32
- package/dist/modules/relationships/RelationshipsController.js.map +1 -1
- package/dist/modules/relationships/local/CachedRelationship.d.ts +3 -3
- package/dist/modules/relationships/local/CachedRelationship.d.ts.map +1 -1
- package/dist/modules/relationships/local/CachedRelationship.js +4 -4
- package/dist/modules/relationships/local/CachedRelationship.js.map +1 -1
- package/dist/modules/relationships/local/PeerDeletionInfo.d.ts +16 -0
- package/dist/modules/relationships/local/PeerDeletionInfo.d.ts.map +1 -0
- package/dist/{core/types/CoreAddress.js → modules/relationships/local/PeerDeletionInfo.js} +14 -32
- package/dist/modules/relationships/local/PeerDeletionInfo.js.map +1 -0
- package/dist/modules/relationships/local/Relationship.d.ts +5 -1
- package/dist/modules/relationships/local/Relationship.d.ts.map +1 -1
- package/dist/modules/relationships/local/Relationship.js +16 -8
- package/dist/modules/relationships/local/Relationship.js.map +1 -1
- package/dist/modules/relationships/local/RelationshipAuditLog.js +4 -4
- package/dist/modules/relationships/local/RelationshipAuditLog.js.map +1 -1
- package/dist/modules/relationships/local/RelationshipAuditLogEntry.d.ts +4 -3
- package/dist/modules/relationships/local/RelationshipAuditLogEntry.d.ts.map +1 -1
- package/dist/modules/relationships/local/RelationshipAuditLogEntry.js +5 -5
- package/dist/modules/relationships/local/RelationshipAuditLogEntry.js.map +1 -1
- package/dist/modules/relationships/local/SendRelationshipParameters.d.ts +2 -3
- package/dist/modules/relationships/local/SendRelationshipParameters.d.ts.map +1 -1
- package/dist/modules/relationships/local/SendRelationshipParameters.js +1 -2
- package/dist/modules/relationships/local/SendRelationshipParameters.js.map +1 -1
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentCipher.d.ts +5 -3
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentCipher.d.ts.map +1 -1
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentCipher.js +10 -3
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentCipher.js.map +1 -1
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentSigned.d.ts +3 -3
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentSigned.d.ts.map +1 -1
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentSigned.js +1 -2
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentSigned.js.map +1 -1
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentWrapper.d.ts +3 -3
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentWrapper.d.ts.map +1 -1
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentWrapper.js +3 -3
- package/dist/modules/relationships/transmission/requests/RelationshipCreationContentWrapper.js.map +1 -1
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentCipher.d.ts +4 -3
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentCipher.d.ts.map +1 -1
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentCipher.js +6 -3
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentCipher.js.map +1 -1
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentSigned.d.ts +3 -3
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentSigned.d.ts.map +1 -1
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentSigned.js +1 -2
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentSigned.js.map +1 -1
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentWrapper.d.ts +4 -3
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentWrapper.d.ts.map +1 -1
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentWrapper.js +3 -3
- package/dist/modules/relationships/transmission/responses/RelationshipCreationResponseContentWrapper.js.map +1 -1
- package/dist/modules/secrets/SecretController.d.ts +1 -1
- package/dist/modules/secrets/SecretController.d.ts.map +1 -1
- package/dist/modules/secrets/SecretController.js +6 -5
- package/dist/modules/secrets/SecretController.js.map +1 -1
- package/dist/modules/secrets/data/SecretContainerCipher.d.ts +1 -1
- package/dist/modules/secrets/data/SecretContainerCipher.d.ts.map +1 -1
- package/dist/modules/secrets/data/SecretContainerCipher.js +4 -4
- package/dist/modules/secrets/data/SecretContainerCipher.js.map +1 -1
- package/dist/modules/secrets/data/SecretContainerPlain.d.ts +5 -5
- package/dist/modules/secrets/data/SecretContainerPlain.d.ts.map +1 -1
- package/dist/modules/secrets/data/SecretContainerPlain.js +6 -6
- package/dist/modules/secrets/data/SecretContainerPlain.js.map +1 -1
- package/dist/modules/sync/DatawalletModificationMapper.d.ts.map +1 -1
- package/dist/modules/sync/DatawalletModificationMapper.js +2 -1
- package/dist/modules/sync/DatawalletModificationMapper.js.map +1 -1
- package/dist/modules/sync/DatawalletModificationsProcessor.d.ts +1 -1
- package/dist/modules/sync/DatawalletModificationsProcessor.d.ts.map +1 -1
- package/dist/modules/sync/DatawalletModificationsProcessor.js +7 -5
- package/dist/modules/sync/DatawalletModificationsProcessor.js.map +1 -1
- package/dist/modules/sync/SyncController.d.ts +2 -1
- package/dist/modules/sync/SyncController.d.ts.map +1 -1
- package/dist/modules/sync/SyncController.js +12 -21
- package/dist/modules/sync/SyncController.js.map +1 -1
- package/dist/modules/sync/SynchronizedCollection.js +2 -2
- package/dist/modules/sync/SynchronizedCollection.js.map +1 -1
- package/dist/modules/sync/externalEventProcessors/ExternalEventProcessorRegistry.d.ts.map +1 -1
- package/dist/modules/sync/externalEventProcessors/ExternalEventProcessorRegistry.js +6 -0
- package/dist/modules/sync/externalEventProcessors/ExternalEventProcessorRegistry.js.map +1 -1
- package/dist/modules/sync/externalEventProcessors/MessageReceivedExternalEventProcessor.js +2 -2
- package/dist/modules/sync/externalEventProcessors/MessageReceivedExternalEventProcessor.js.map +1 -1
- package/dist/modules/sync/externalEventProcessors/PeerDeletedExternalEventProcessor.d.ts +7 -0
- package/dist/modules/sync/externalEventProcessors/PeerDeletedExternalEventProcessor.d.ts.map +1 -0
- package/dist/modules/sync/externalEventProcessors/PeerDeletedExternalEventProcessor.js +35 -0
- package/dist/modules/sync/externalEventProcessors/PeerDeletedExternalEventProcessor.js.map +1 -0
- package/dist/modules/sync/externalEventProcessors/PeerDeletionCancelledExternalEventProcessor.d.ts +7 -0
- package/dist/modules/sync/externalEventProcessors/PeerDeletionCancelledExternalEventProcessor.d.ts.map +1 -0
- package/dist/modules/sync/externalEventProcessors/PeerDeletionCancelledExternalEventProcessor.js +33 -0
- package/dist/modules/sync/externalEventProcessors/PeerDeletionCancelledExternalEventProcessor.js.map +1 -0
- package/dist/modules/sync/externalEventProcessors/PeerToBeDeletedExternalEventProcessor.d.ts +7 -0
- package/dist/modules/sync/externalEventProcessors/PeerToBeDeletedExternalEventProcessor.d.ts.map +1 -0
- package/dist/modules/sync/externalEventProcessors/PeerToBeDeletedExternalEventProcessor.js +35 -0
- package/dist/modules/sync/externalEventProcessors/PeerToBeDeletedExternalEventProcessor.js.map +1 -0
- package/dist/modules/sync/local/DatawalletModification.d.ts +4 -3
- package/dist/modules/sync/local/DatawalletModification.d.ts.map +1 -1
- package/dist/modules/sync/local/DatawalletModification.js +4 -4
- package/dist/modules/sync/local/DatawalletModification.js.map +1 -1
- package/dist/modules/tokens/AnonymousTokenController.d.ts +2 -1
- package/dist/modules/tokens/AnonymousTokenController.d.ts.map +1 -1
- package/dist/modules/tokens/AnonymousTokenController.js +7 -6
- package/dist/modules/tokens/AnonymousTokenController.js.map +1 -1
- package/dist/modules/tokens/TokenController.d.ts +1 -1
- package/dist/modules/tokens/TokenController.d.ts.map +1 -1
- package/dist/modules/tokens/TokenController.js +14 -13
- package/dist/modules/tokens/TokenController.js.map +1 -1
- package/dist/modules/tokens/local/CachedToken.d.ts +3 -3
- package/dist/modules/tokens/local/CachedToken.d.ts.map +1 -1
- package/dist/modules/tokens/local/CachedToken.js +6 -6
- package/dist/modules/tokens/local/CachedToken.js.map +1 -1
- package/dist/modules/tokens/local/SendTokenParameters.d.ts +3 -3
- package/dist/modules/tokens/local/SendTokenParameters.d.ts.map +1 -1
- package/dist/modules/tokens/local/SendTokenParameters.js +3 -3
- package/dist/modules/tokens/local/SendTokenParameters.js.map +1 -1
- package/dist/modules/tokens/local/Token.d.ts +2 -1
- package/dist/modules/tokens/local/Token.d.ts.map +1 -1
- package/dist/modules/tokens/local/Token.js +5 -4
- package/dist/modules/tokens/local/Token.js.map +1 -1
- package/dist/modules/tokens/transmission/TokenContentDeviceSharedSecret.d.ts +3 -3
- package/dist/modules/tokens/transmission/TokenContentDeviceSharedSecret.d.ts.map +1 -1
- package/dist/modules/tokens/transmission/TokenContentDeviceSharedSecret.js +1 -2
- package/dist/modules/tokens/transmission/TokenContentDeviceSharedSecret.js.map +1 -1
- package/dist/modules/tokens/transmission/TokenContentFile.d.ts +4 -3
- package/dist/modules/tokens/transmission/TokenContentFile.d.ts.map +1 -1
- package/dist/modules/tokens/transmission/TokenContentFile.js +3 -3
- package/dist/modules/tokens/transmission/TokenContentFile.js.map +1 -1
- package/dist/modules/tokens/transmission/TokenContentRelationshipTemplate.d.ts +4 -3
- package/dist/modules/tokens/transmission/TokenContentRelationshipTemplate.d.ts.map +1 -1
- package/dist/modules/tokens/transmission/TokenContentRelationshipTemplate.js +3 -3
- package/dist/modules/tokens/transmission/TokenContentRelationshipTemplate.js.map +1 -1
- package/dist/util/PasswordGenerator.d.ts.map +1 -1
- package/dist/util/PasswordGenerator.js +1 -2
- package/dist/util/PasswordGenerator.js.map +1 -1
- package/dist/util/Random.d.ts.map +1 -1
- package/dist/util/Random.js +7 -8
- package/dist/util/Random.js.map +1 -1
- package/package.json +8 -8
- package/dist/core/CoreError.d.ts +0 -19
- package/dist/core/CoreError.d.ts.map +0 -1
- package/dist/core/CoreError.js +0 -63
- package/dist/core/CoreError.js.map +0 -1
- package/dist/core/CoreErrors.d.ts.map +0 -1
- package/dist/core/CoreErrors.js +0 -147
- package/dist/core/CoreErrors.js.map +0 -1
- package/dist/core/CoreSerializable.d.ts +0 -17
- package/dist/core/CoreSerializable.d.ts.map +0 -1
- package/dist/core/CoreSerializable.js +0 -37
- package/dist/core/CoreSerializable.js.map +0 -1
- package/dist/core/CoreSerializableAsync.d.ts +0 -17
- package/dist/core/CoreSerializableAsync.d.ts.map +0 -1
- package/dist/core/CoreSerializableAsync.js +0 -38
- package/dist/core/CoreSerializableAsync.js.map +0 -1
- package/dist/core/types/CoreAddress.d.ts +0 -16
- package/dist/core/types/CoreAddress.d.ts.map +0 -1
- package/dist/core/types/CoreAddress.js.map +0 -1
- package/dist/core/types/CoreDate.d.ts +0 -40
- package/dist/core/types/CoreDate.d.ts.map +0 -1
- package/dist/core/types/CoreDate.js +0 -152
- package/dist/core/types/CoreDate.js.map +0 -1
- package/dist/core/types/CoreId.d.ts +0 -17
- package/dist/core/types/CoreId.d.ts.map +0 -1
- package/dist/core/types/CoreId.js +0 -57
- package/dist/core/types/CoreId.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageContentWrapper.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageContentWrapper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAA6B,MAAM,oBAAoB,CAAC;AAC5F,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"MessageContentWrapper.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageContentWrapper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAA6B,MAAM,oBAAoB,CAAC;AAC5F,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACnF,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,wCAAwC,CAAC;AAEvF,MAAM,WAAW,sBAAuB,SAAQ,aAAa;IACzD,WAAW,CAAC,EAAE,cAAc,EAAE,CAAC;IAC/B,OAAO,EAAE,aAAa,CAAC;IACvB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,UAAU,EAAE,YAAY,EAAE,CAAC;CAC9B;AAED;;;;;;;;;GASG;AACH,qBACa,qBAAsB,SAAQ,YAAa,YAAW,sBAAsB;IAG9E,WAAW,EAAE,aAAa,EAAE,CAAM;IAIlC,OAAO,EAAE,YAAY,CAAC;IAItB,SAAS,EAAE,QAAQ,CAAC;IAIpB,UAAU,EAAE,WAAW,EAAE,CAAC;qBAEP,OAAO,CAAC,KAAK,EAAE,GAAG,GAAG,GAAG;WAMpC,IAAI,CAAC,KAAK,EAAE,sBAAsB,GAAG,qBAAqB;CAG3E"}
|
|
@@ -11,9 +11,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MessageContentWrapper = void 0;
|
|
13
13
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
14
|
-
const
|
|
15
|
-
const CoreAddress_1 = require("../../../core/types/CoreAddress");
|
|
16
|
-
const CoreDate_1 = require("../../../core/types/CoreDate");
|
|
14
|
+
const core_types_1 = require("@nmshd/core-types");
|
|
17
15
|
const FileReference_1 = require("../../files/transmission/FileReference");
|
|
18
16
|
/**
|
|
19
17
|
* MessageContentWrapper is a container for the actual message as [[IMessage]], its creationDate and
|
|
@@ -25,7 +23,7 @@ const FileReference_1 = require("../../files/transmission/FileReference");
|
|
|
25
23
|
* the sender. If a recipient is not in the signed list of recipients, the message needs to be
|
|
26
24
|
* ignored (as the whole message could have been forwarded by bad party to a wrong recipient).
|
|
27
25
|
*/
|
|
28
|
-
let MessageContentWrapper = class MessageContentWrapper extends
|
|
26
|
+
let MessageContentWrapper = class MessageContentWrapper extends ts_serval_1.Serializable {
|
|
29
27
|
constructor() {
|
|
30
28
|
super(...arguments);
|
|
31
29
|
this.attachments = [];
|
|
@@ -53,11 +51,11 @@ __decorate([
|
|
|
53
51
|
__decorate([
|
|
54
52
|
(0, ts_serval_1.validate)(),
|
|
55
53
|
(0, ts_serval_1.serialize)(),
|
|
56
|
-
__metadata("design:type",
|
|
54
|
+
__metadata("design:type", core_types_1.CoreDate)
|
|
57
55
|
], MessageContentWrapper.prototype, "createdAt", void 0);
|
|
58
56
|
__decorate([
|
|
59
57
|
(0, ts_serval_1.validate)(),
|
|
60
|
-
(0, ts_serval_1.serialize)({ type:
|
|
58
|
+
(0, ts_serval_1.serialize)({ type: core_types_1.CoreAddress }),
|
|
61
59
|
__metadata("design:type", Array)
|
|
62
60
|
], MessageContentWrapper.prototype, "recipients", void 0);
|
|
63
61
|
exports.MessageContentWrapper = MessageContentWrapper = __decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageContentWrapper.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageContentWrapper.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,kDAA4F;AAC5F,
|
|
1
|
+
{"version":3,"file":"MessageContentWrapper.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageContentWrapper.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,kDAA4F;AAC5F,kDAAmF;AACnF,0EAAuF;AASvF;;;;;;;;;GASG;AAEI,IAAM,qBAAqB,GAA3B,MAAM,qBAAsB,SAAQ,wBAAY;IAAhD;;QAGI,gBAAW,GAAoB,EAAE,CAAC;IAuB7C,CAAC;IATa,MAAM,CAAU,OAAO,CAAC,KAAU;QACxC,IAAI,CAAC,KAAK,CAAC,WAAW;YAAE,KAAK,CAAC,WAAW,GAAG,EAAE,CAAC;QAE/C,OAAO,KAAK,CAAC;IACjB,CAAC;IAEM,MAAM,CAAC,IAAI,CAAC,KAA6B;QAC5C,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAC/B,CAAC;CACJ,CAAA;AA1BY,sDAAqB;AAGvB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,6BAAa,EAAE,CAAC;;0DACM;AAIlC;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACI,wBAAY;sDAAC;AAItB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACM,qBAAQ;wDAAC;AAIpB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,wBAAW,EAAE,CAAC;;yDACA;gCAfxB,qBAAqB;IADjC,IAAA,gBAAI,EAAC,uBAAuB,CAAC;GACjB,qBAAqB,CA0BjC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import { ISerializable, Serializable } from "@js-soft/ts-serval";
|
|
2
|
+
import { CoreAddress, CoreDate, CoreId, ICoreAddress, ICoreDate, ICoreId } from "@nmshd/core-types";
|
|
1
3
|
import { CryptoCipher, ICryptoCipher } from "@nmshd/crypto";
|
|
2
|
-
import { CoreAddress, CoreDate, CoreId, CoreSerializable, ICoreAddress, ICoreDate, ICoreId, ICoreSerializable } from "../../../core";
|
|
3
4
|
import { IMessageEnvelopeRecipient, MessageEnvelopeRecipient } from "./MessageEnvelopeRecipient";
|
|
4
|
-
export interface IMessageEnvelope extends
|
|
5
|
+
export interface IMessageEnvelope extends ISerializable {
|
|
5
6
|
id: ICoreId;
|
|
6
7
|
createdAt: ICoreDate;
|
|
7
8
|
createdBy: ICoreAddress;
|
|
@@ -10,7 +11,7 @@ export interface IMessageEnvelope extends ICoreSerializable {
|
|
|
10
11
|
attachments: ICoreId[];
|
|
11
12
|
recipients: IMessageEnvelopeRecipient[];
|
|
12
13
|
}
|
|
13
|
-
export declare class MessageEnvelope extends
|
|
14
|
+
export declare class MessageEnvelope extends Serializable implements IMessageEnvelope {
|
|
14
15
|
id: CoreId;
|
|
15
16
|
createdAt: CoreDate;
|
|
16
17
|
createdBy: CoreAddress;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageEnvelope.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageEnvelope.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"MessageEnvelope.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageEnvelope.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAA6B,MAAM,oBAAoB,CAAC;AAC5F,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,EAAE,YAAY,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AACpG,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAC5D,OAAO,EAAE,yBAAyB,EAAE,wBAAwB,EAAE,MAAM,4BAA4B,CAAC;AAEjG,MAAM,WAAW,gBAAiB,SAAQ,aAAa;IACnD,EAAE,EAAE,OAAO,CAAC;IAEZ,SAAS,EAAE,SAAS,CAAC;IACrB,SAAS,EAAE,YAAY,CAAC;IACxB,eAAe,EAAE,OAAO,CAAC;IAEzB,MAAM,EAAE,aAAa,CAAC;IAEtB,WAAW,EAAE,OAAO,EAAE,CAAC;IACvB,UAAU,EAAE,yBAAyB,EAAE,CAAC;CAC3C;AAED,qBACa,eAAgB,SAAQ,YAAa,YAAW,gBAAgB;IAGlE,EAAE,EAAE,MAAM,CAAC;IAIX,SAAS,EAAE,QAAQ,CAAC;IAIpB,SAAS,EAAE,WAAW,CAAC;IAIvB,eAAe,EAAE,MAAM,CAAC;IAIxB,UAAU,EAAE,wBAAwB,EAAE,CAAC;IAIvC,MAAM,EAAE,YAAY,CAAC;IAIrB,WAAW,EAAE,MAAM,EAAE,CAAC;WAEf,IAAI,CAAC,KAAK,EAAE,gBAAgB,GAAG,eAAe;WAI9C,SAAS,CAAC,KAAK,EAAE,GAAG,CAAC,WAAW,EAAE,YAAY,CAAC,GAAG,MAAM;WAUxD,cAAc,CAAC,KAAK,EAAE,GAAG,GAAG,GAAG,CAAC,WAAW,EAAE,YAAY,CAAC;CAU3E"}
|
|
@@ -11,10 +11,10 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MessageEnvelope = void 0;
|
|
13
13
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
14
|
+
const core_types_1 = require("@nmshd/core-types");
|
|
14
15
|
const crypto_1 = require("@nmshd/crypto");
|
|
15
|
-
const core_1 = require("../../../core");
|
|
16
16
|
const MessageEnvelopeRecipient_1 = require("./MessageEnvelopeRecipient");
|
|
17
|
-
let MessageEnvelope = class MessageEnvelope extends
|
|
17
|
+
let MessageEnvelope = class MessageEnvelope extends ts_serval_1.Serializable {
|
|
18
18
|
static from(value) {
|
|
19
19
|
return this.fromAny(value);
|
|
20
20
|
}
|
|
@@ -31,7 +31,7 @@ let MessageEnvelope = class MessageEnvelope extends core_1.CoreSerializable {
|
|
|
31
31
|
const obj = new Map();
|
|
32
32
|
for (const key in value) {
|
|
33
33
|
const cipher = value[key];
|
|
34
|
-
const serializedKey =
|
|
34
|
+
const serializedKey = core_types_1.CoreAddress.deserialize(key);
|
|
35
35
|
const serializedValue = crypto_1.CryptoCipher.deserialize(cipher);
|
|
36
36
|
obj.set(serializedKey, serializedValue);
|
|
37
37
|
}
|
|
@@ -42,22 +42,22 @@ exports.MessageEnvelope = MessageEnvelope;
|
|
|
42
42
|
__decorate([
|
|
43
43
|
(0, ts_serval_1.validate)(),
|
|
44
44
|
(0, ts_serval_1.serialize)(),
|
|
45
|
-
__metadata("design:type",
|
|
45
|
+
__metadata("design:type", core_types_1.CoreId)
|
|
46
46
|
], MessageEnvelope.prototype, "id", void 0);
|
|
47
47
|
__decorate([
|
|
48
48
|
(0, ts_serval_1.validate)(),
|
|
49
49
|
(0, ts_serval_1.serialize)(),
|
|
50
|
-
__metadata("design:type",
|
|
50
|
+
__metadata("design:type", core_types_1.CoreDate)
|
|
51
51
|
], MessageEnvelope.prototype, "createdAt", void 0);
|
|
52
52
|
__decorate([
|
|
53
53
|
(0, ts_serval_1.validate)(),
|
|
54
54
|
(0, ts_serval_1.serialize)(),
|
|
55
|
-
__metadata("design:type",
|
|
55
|
+
__metadata("design:type", core_types_1.CoreAddress)
|
|
56
56
|
], MessageEnvelope.prototype, "createdBy", void 0);
|
|
57
57
|
__decorate([
|
|
58
58
|
(0, ts_serval_1.validate)(),
|
|
59
59
|
(0, ts_serval_1.serialize)(),
|
|
60
|
-
__metadata("design:type",
|
|
60
|
+
__metadata("design:type", core_types_1.CoreId)
|
|
61
61
|
], MessageEnvelope.prototype, "createdByDevice", void 0);
|
|
62
62
|
__decorate([
|
|
63
63
|
(0, ts_serval_1.validate)(),
|
|
@@ -71,7 +71,7 @@ __decorate([
|
|
|
71
71
|
], MessageEnvelope.prototype, "cipher", void 0);
|
|
72
72
|
__decorate([
|
|
73
73
|
(0, ts_serval_1.validate)(),
|
|
74
|
-
(0, ts_serval_1.serialize)({ type:
|
|
74
|
+
(0, ts_serval_1.serialize)({ type: core_types_1.CoreId }),
|
|
75
75
|
__metadata("design:type", Array)
|
|
76
76
|
], MessageEnvelope.prototype, "attachments", void 0);
|
|
77
77
|
exports.MessageEnvelope = MessageEnvelope = __decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageEnvelope.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageEnvelope.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"MessageEnvelope.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageEnvelope.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,kDAA4F;AAC5F,kDAAoG;AACpG,0CAA4D;AAC5D,yEAAiG;AAgB1F,IAAM,eAAe,GAArB,MAAM,eAAgB,SAAQ,wBAAY;IA6BtC,MAAM,CAAC,IAAI,CAAC,KAAuB;QACtC,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAC/B,CAAC;IAEM,MAAM,CAAC,SAAS,CAAC,KAAqC;QACzD,MAAM,GAAG,GAAQ,EAAE,CAAC;QACpB,KAAK,MAAM,CAAC,GAAG,EAAE,MAAM,CAAC,IAAI,KAAK,CAAC,OAAO,EAAE,EAAE,CAAC;YAC1C,MAAM,aAAa,GAAG,GAAG,CAAC,SAAS,EAAE,CAAC;YACtC,MAAM,eAAe,GAAG,MAAM,CAAC,SAAS,EAAE,CAAC;YAC3C,GAAG,CAAC,aAAa,CAAC,GAAG,eAAe,CAAC;QACzC,CAAC;QACD,OAAO,GAAG,CAAC;IACf,CAAC;IAEM,MAAM,CAAC,cAAc,CAAC,KAAU;QACnC,MAAM,GAAG,GAAmC,IAAI,GAAG,EAA6B,CAAC;QACjF,KAAK,MAAM,GAAG,IAAI,KAAK,EAAE,CAAC;YACtB,MAAM,MAAM,GAAQ,KAAK,CAAC,GAAG,CAAC,CAAC;YAC/B,MAAM,aAAa,GAAG,wBAAW,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;YACnD,MAAM,eAAe,GAAG,qBAAY,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC;YACzD,GAAG,CAAC,GAAG,CAAC,aAAa,EAAE,eAAe,CAAC,CAAC;QAC5C,CAAC;QACD,OAAO,GAAG,CAAC;IACf,CAAC;CACJ,CAAA;AArDY,0CAAe;AAGjB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACD,mBAAM;2CAAC;AAIX;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACM,qBAAQ;kDAAC;AAIpB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACM,wBAAW;kDAAC;AAIvB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACY,mBAAM;wDAAC;AAIxB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,mDAAwB,EAAE,CAAC;;mDACA;AAIvC;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACG,qBAAY;+CAAC;AAIrB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,mBAAM,EAAE,CAAC;;oDACC;0BA3BpB,eAAe;IAD3B,IAAA,gBAAI,EAAC,iBAAiB,CAAC;GACX,eAAe,CAqD3B"}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
+
import { ISerializable, Serializable } from "@js-soft/ts-serval";
|
|
2
|
+
import { CoreAddress, CoreDate, CoreId, ICoreAddress, ICoreDate, ICoreId } from "@nmshd/core-types";
|
|
1
3
|
import { CryptoCipher, ICryptoCipher } from "@nmshd/crypto";
|
|
2
|
-
|
|
3
|
-
import { CoreAddress, ICoreAddress } from "../../../core/types/CoreAddress";
|
|
4
|
-
export interface IMessageEnvelopeRecipient extends ICoreSerializable {
|
|
4
|
+
export interface IMessageEnvelopeRecipient extends ISerializable {
|
|
5
5
|
address: ICoreAddress;
|
|
6
6
|
encryptedKey: ICryptoCipher;
|
|
7
7
|
receivedAt?: ICoreDate;
|
|
8
8
|
receivedByDevice?: ICoreId;
|
|
9
9
|
}
|
|
10
|
-
export declare class MessageEnvelopeRecipient extends
|
|
10
|
+
export declare class MessageEnvelopeRecipient extends Serializable implements IMessageEnvelopeRecipient {
|
|
11
11
|
address: CoreAddress;
|
|
12
12
|
encryptedKey: CryptoCipher;
|
|
13
13
|
receivedAt?: CoreDate;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageEnvelopeRecipient.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageEnvelopeRecipient.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"MessageEnvelopeRecipient.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageEnvelopeRecipient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAA6B,MAAM,oBAAoB,CAAC;AAC5F,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,EAAE,YAAY,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AACpG,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAE5D,MAAM,WAAW,yBAA0B,SAAQ,aAAa;IAC5D,OAAO,EAAE,YAAY,CAAC;IACtB,YAAY,EAAE,aAAa,CAAC;IAC5B,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC9B;AAED,qBACa,wBAAyB,SAAQ,YAAa,YAAW,yBAAyB;IAGpF,OAAO,EAAE,WAAW,CAAC;IAIrB,YAAY,EAAE,YAAY,CAAC;IAI3B,UAAU,CAAC,EAAE,QAAQ,CAAC;IAItB,gBAAgB,CAAC,EAAE,MAAM,CAAC;WAEnB,IAAI,CAAC,KAAK,EAAE,yBAAyB,GAAG,wBAAwB;CAGjF"}
|
|
@@ -11,10 +11,9 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MessageEnvelopeRecipient = void 0;
|
|
13
13
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
14
|
+
const core_types_1 = require("@nmshd/core-types");
|
|
14
15
|
const crypto_1 = require("@nmshd/crypto");
|
|
15
|
-
|
|
16
|
-
const CoreAddress_1 = require("../../../core/types/CoreAddress");
|
|
17
|
-
let MessageEnvelopeRecipient = class MessageEnvelopeRecipient extends core_1.CoreSerializable {
|
|
16
|
+
let MessageEnvelopeRecipient = class MessageEnvelopeRecipient extends ts_serval_1.Serializable {
|
|
18
17
|
static from(value) {
|
|
19
18
|
return this.fromAny(value);
|
|
20
19
|
}
|
|
@@ -23,7 +22,7 @@ exports.MessageEnvelopeRecipient = MessageEnvelopeRecipient;
|
|
|
23
22
|
__decorate([
|
|
24
23
|
(0, ts_serval_1.validate)(),
|
|
25
24
|
(0, ts_serval_1.serialize)(),
|
|
26
|
-
__metadata("design:type",
|
|
25
|
+
__metadata("design:type", core_types_1.CoreAddress)
|
|
27
26
|
], MessageEnvelopeRecipient.prototype, "address", void 0);
|
|
28
27
|
__decorate([
|
|
29
28
|
(0, ts_serval_1.validate)(),
|
|
@@ -33,12 +32,12 @@ __decorate([
|
|
|
33
32
|
__decorate([
|
|
34
33
|
(0, ts_serval_1.validate)({ nullable: true }),
|
|
35
34
|
(0, ts_serval_1.serialize)(),
|
|
36
|
-
__metadata("design:type",
|
|
35
|
+
__metadata("design:type", core_types_1.CoreDate)
|
|
37
36
|
], MessageEnvelopeRecipient.prototype, "receivedAt", void 0);
|
|
38
37
|
__decorate([
|
|
39
38
|
(0, ts_serval_1.validate)({ nullable: true }),
|
|
40
39
|
(0, ts_serval_1.serialize)(),
|
|
41
|
-
__metadata("design:type",
|
|
40
|
+
__metadata("design:type", core_types_1.CoreId)
|
|
42
41
|
], MessageEnvelopeRecipient.prototype, "receivedByDevice", void 0);
|
|
43
42
|
exports.MessageEnvelopeRecipient = MessageEnvelopeRecipient = __decorate([
|
|
44
43
|
(0, ts_serval_1.type)("MessageEnvelopeRecipient")
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageEnvelopeRecipient.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageEnvelopeRecipient.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"MessageEnvelopeRecipient.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageEnvelopeRecipient.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,kDAA4F;AAC5F,kDAAoG;AACpG,0CAA4D;AAUrD,IAAM,wBAAwB,GAA9B,MAAM,wBAAyB,SAAQ,wBAAY;IAiB/C,MAAM,CAAC,IAAI,CAAC,KAAgC;QAC/C,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAC/B,CAAC;CACJ,CAAA;AApBY,4DAAwB;AAG1B;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACI,wBAAW;yDAAC;AAIrB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACS,qBAAY;8DAAC;AAI3B;IAFN,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IAC5B,IAAA,qBAAS,GAAE;8BACQ,qBAAQ;4DAAC;AAItB;IAFN,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IAC5B,IAAA,qBAAS,GAAE;8BACc,mBAAM;kEAAC;mCAfxB,wBAAwB;IADpC,IAAA,gBAAI,EAAC,0BAA0B,CAAC;GACpB,wBAAwB,CAoBpC"}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import { ISerializable, Serializable } from "@js-soft/ts-serval";
|
|
2
|
+
import { CoreAddress, ICoreAddress } from "@nmshd/core-types";
|
|
1
3
|
import { CryptoSignature, ICryptoSignature } from "@nmshd/crypto";
|
|
2
|
-
|
|
3
|
-
export interface IMessageSignature extends ICoreSerializable {
|
|
4
|
+
export interface IMessageSignature extends ISerializable {
|
|
4
5
|
recipient: ICoreAddress;
|
|
5
6
|
signature: ICryptoSignature;
|
|
6
7
|
}
|
|
7
|
-
export declare class MessageSignature extends
|
|
8
|
+
export declare class MessageSignature extends Serializable implements IMessageSignature {
|
|
8
9
|
recipient: CoreAddress;
|
|
9
10
|
signature: CryptoSignature;
|
|
10
11
|
static from(value: IMessageSignature): MessageSignature;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageSignature.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageSignature.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"MessageSignature.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageSignature.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAA6B,MAAM,oBAAoB,CAAC;AAC5F,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAElE,MAAM,WAAW,iBAAkB,SAAQ,aAAa;IACpD,SAAS,EAAE,YAAY,CAAC;IACxB,SAAS,EAAE,gBAAgB,CAAC;CAC/B;AAED,qBACa,gBAAiB,SAAQ,YAAa,YAAW,iBAAiB;IAGpE,SAAS,EAAE,WAAW,CAAC;IAIvB,SAAS,EAAE,eAAe,CAAC;WAEpB,IAAI,CAAC,KAAK,EAAE,iBAAiB,GAAG,gBAAgB;CAGjE"}
|
|
@@ -11,9 +11,9 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MessageSignature = void 0;
|
|
13
13
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
14
|
+
const core_types_1 = require("@nmshd/core-types");
|
|
14
15
|
const crypto_1 = require("@nmshd/crypto");
|
|
15
|
-
|
|
16
|
-
let MessageSignature = class MessageSignature extends core_1.CoreSerializable {
|
|
16
|
+
let MessageSignature = class MessageSignature extends ts_serval_1.Serializable {
|
|
17
17
|
static from(value) {
|
|
18
18
|
return this.fromAny(value);
|
|
19
19
|
}
|
|
@@ -22,7 +22,7 @@ exports.MessageSignature = MessageSignature;
|
|
|
22
22
|
__decorate([
|
|
23
23
|
(0, ts_serval_1.validate)(),
|
|
24
24
|
(0, ts_serval_1.serialize)(),
|
|
25
|
-
__metadata("design:type",
|
|
25
|
+
__metadata("design:type", core_types_1.CoreAddress)
|
|
26
26
|
], MessageSignature.prototype, "recipient", void 0);
|
|
27
27
|
__decorate([
|
|
28
28
|
(0, ts_serval_1.validate)(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageSignature.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageSignature.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"MessageSignature.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageSignature.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,kDAA4F;AAC5F,kDAA8D;AAC9D,0CAAkE;AAQ3D,IAAM,gBAAgB,GAAtB,MAAM,gBAAiB,SAAQ,wBAAY;IASvC,MAAM,CAAC,IAAI,CAAC,KAAwB;QACvC,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAC/B,CAAC;CACJ,CAAA;AAZY,4CAAgB;AAGlB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACM,wBAAW;mDAAC;AAIvB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,EAAC,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC;8BACjB,wBAAe;mDAAC;2BAPzB,gBAAgB;IAD5B,IAAA,gBAAI,EAAC,kBAAkB,CAAC;GACZ,gBAAgB,CAY5B"}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ISerializable, Serializable } from "@js-soft/ts-serval";
|
|
2
2
|
import { IMessageSignature, MessageSignature } from "./MessageSignature";
|
|
3
|
-
export interface IMessageSigned extends
|
|
3
|
+
export interface IMessageSigned extends ISerializable {
|
|
4
4
|
signatures: IMessageSignature[];
|
|
5
5
|
message: string;
|
|
6
6
|
}
|
|
7
7
|
/**
|
|
8
8
|
* MessageSigned encapsulates the actual message with the senders digital signature.
|
|
9
9
|
*/
|
|
10
|
-
export declare class MessageSigned extends
|
|
10
|
+
export declare class MessageSigned extends Serializable {
|
|
11
11
|
signatures: MessageSignature[];
|
|
12
12
|
message: string;
|
|
13
13
|
static from(value: IMessageSigned): MessageSigned;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageSigned.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageSigned.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"MessageSigned.d.ts","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageSigned.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAA6B,MAAM,oBAAoB,CAAC;AAC5F,OAAO,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAEzE,MAAM,WAAW,cAAe,SAAQ,aAAa;IACjD,UAAU,EAAE,iBAAiB,EAAE,CAAC;IAChC,OAAO,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,qBACa,aAAc,SAAQ,YAAY;IAGpC,UAAU,EAAE,gBAAgB,EAAE,CAAC;IAI/B,OAAO,EAAE,MAAM,CAAC;WAET,IAAI,CAAC,KAAK,EAAE,cAAc,GAAG,aAAa;CAG3D"}
|
|
@@ -11,12 +11,11 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.MessageSigned = void 0;
|
|
13
13
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
14
|
-
const core_1 = require("../../../core");
|
|
15
14
|
const MessageSignature_1 = require("./MessageSignature");
|
|
16
15
|
/**
|
|
17
16
|
* MessageSigned encapsulates the actual message with the senders digital signature.
|
|
18
17
|
*/
|
|
19
|
-
let MessageSigned = class MessageSigned extends
|
|
18
|
+
let MessageSigned = class MessageSigned extends ts_serval_1.Serializable {
|
|
20
19
|
static from(value) {
|
|
21
20
|
return this.fromAny(value);
|
|
22
21
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageSigned.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageSigned.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"MessageSigned.js","sourceRoot":"","sources":["../../../../src/modules/messages/transmission/MessageSigned.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,kDAA4F;AAC5F,yDAAyE;AAOzE;;GAEG;AAEI,IAAM,aAAa,GAAnB,MAAM,aAAc,SAAQ,wBAAY;IASpC,MAAM,CAAC,IAAI,CAAC,KAAqB;QACpC,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAC/B,CAAC;CACJ,CAAA;AAZY,sCAAa;AAGf;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,EAAC,EAAE,IAAI,EAAE,mCAAgB,EAAE,CAAC;;iDACA;AAI/B;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;;8CACW;wBAPd,aAAa;IADzB,IAAA,gBAAI,EAAC,eAAe,CAAC;GACT,aAAa,CAYzB"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ISerializable } from "@js-soft/ts-serval";
|
|
2
|
+
import { CoreId } from "@nmshd/core-types";
|
|
2
3
|
import { CryptoSecretKey } from "@nmshd/crypto";
|
|
3
|
-
import { CoreId } from "../../core";
|
|
4
4
|
import { ControllerName, TransportController } from "../../core/TransportController";
|
|
5
5
|
import { AccountController } from "../accounts/AccountController";
|
|
6
6
|
import { Relationship } from "../relationships/local/Relationship";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RelationshipTemplateController.d.ts","sourceRoot":"","sources":["../../../src/modules/relationshipTemplates/RelationshipTemplateController.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAEnD,OAAO,
|
|
1
|
+
{"version":3,"file":"RelationshipTemplateController.d.ts","sourceRoot":"","sources":["../../../src/modules/relationshipTemplates/RelationshipTemplateController.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAEnD,OAAO,EAAyB,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAClE,OAAO,EAA4B,eAAe,EAAE,MAAM,eAAe,CAAC;AAG1E,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AAErF,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,YAAY,EAAE,MAAM,qCAAqC,CAAC;AACnE,OAAO,EAAE,4BAA4B,EAAE,MAAM,+CAA+C,CAAC;AAC7F,OAAO,EAAE,sBAAsB,EAAE,MAAM,gCAAgC,CAAC;AAExE,OAAO,EAAE,0BAA0B,EAAE,MAAM,uCAAuC,CAAC;AACnF,OAAO,EAAE,0BAA0B,EAAE,MAAM,oCAAoC,CAAC;AAChF,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AACpE,OAAO,EAAE,mCAAmC,EAAsC,MAAM,4CAA4C,CAAC;AAErI,OAAO,EAAE,6BAA6B,EAAE,MAAM,8CAA8C,CAAC;AAG7F,qBAAa,8BAA+B,SAAQ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,oBAAoB,CAAC;IA0BnG,wCAAwC,CAAC,YAAY,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC;CAenG"}
|
|
@@ -11,6 +11,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.RelationshipTemplateController = void 0;
|
|
13
13
|
const ts_utils_1 = require("@js-soft/ts-utils");
|
|
14
|
+
const core_types_1 = require("@nmshd/core-types");
|
|
14
15
|
const crypto_1 = require("@nmshd/crypto");
|
|
15
16
|
const core_1 = require("../../core");
|
|
16
17
|
const DbCollectionName_1 = require("../../core/DbCollectionName");
|
|
@@ -59,7 +60,7 @@ class RelationshipTemplateController extends TransportController_1.TransportCont
|
|
|
59
60
|
})).value;
|
|
60
61
|
const templateCache = CachedRelationshipTemplate_1.CachedRelationshipTemplate.from({
|
|
61
62
|
content: parameters.content,
|
|
62
|
-
createdAt:
|
|
63
|
+
createdAt: core_types_1.CoreDate.from(backboneResponse.createdAt),
|
|
63
64
|
createdBy: this.parent.identity.address,
|
|
64
65
|
createdByDevice: this.parent.activeDevice.id,
|
|
65
66
|
expiresAt: parameters.expiresAt,
|
|
@@ -68,11 +69,11 @@ class RelationshipTemplateController extends TransportController_1.TransportCont
|
|
|
68
69
|
templateKey: templateKey
|
|
69
70
|
});
|
|
70
71
|
const template = RelationshipTemplate_1.RelationshipTemplate.from({
|
|
71
|
-
id:
|
|
72
|
+
id: core_types_1.CoreId.from(backboneResponse.id),
|
|
72
73
|
secretKey: secretKey,
|
|
73
74
|
isOwn: true,
|
|
74
75
|
cache: templateCache,
|
|
75
|
-
cachedAt:
|
|
76
|
+
cachedAt: core_types_1.CoreDate.utc()
|
|
76
77
|
});
|
|
77
78
|
await this.templates.create(template);
|
|
78
79
|
return template;
|
|
@@ -109,7 +110,7 @@ class RelationshipTemplateController extends TransportController_1.TransportCont
|
|
|
109
110
|
return;
|
|
110
111
|
}
|
|
111
112
|
const template = RelationshipTemplate_1.RelationshipTemplate.from(templateDoc);
|
|
112
|
-
return { id:
|
|
113
|
+
return { id: core_types_1.CoreId.from(t.id), cache: await this.decryptRelationshipTemplate(t, template.secretKey) };
|
|
113
114
|
});
|
|
114
115
|
const caches = await Promise.all(decryptionPromises);
|
|
115
116
|
return caches.filter((c) => c !== undefined);
|
|
@@ -117,7 +118,7 @@ class RelationshipTemplateController extends TransportController_1.TransportCont
|
|
|
117
118
|
async updateCacheOfExistingTemplateInDb(id, response) {
|
|
118
119
|
const templateDoc = await this.templates.read(id);
|
|
119
120
|
if (!templateDoc) {
|
|
120
|
-
throw core_1.
|
|
121
|
+
throw core_1.TransportCoreErrors.general.recordNotFound(RelationshipTemplate_1.RelationshipTemplate, id);
|
|
121
122
|
}
|
|
122
123
|
const template = RelationshipTemplate_1.RelationshipTemplate.from(templateDoc);
|
|
123
124
|
await this.updateCacheOfTemplate(template, response);
|
|
@@ -140,14 +141,14 @@ class RelationshipTemplateController extends TransportController_1.TransportCont
|
|
|
140
141
|
const templateContent = RelationshipTemplateContentWrapper_1.RelationshipTemplateContentWrapper.deserialize(signedTemplate.serializedTemplate);
|
|
141
142
|
const templateSignatureValid = await this.secrets.verifyTemplate(crypto_1.CoreBuffer.fromUtf8(signedTemplate.serializedTemplate), signedTemplate.deviceSignature, templateContent.identity.publicKey);
|
|
142
143
|
if (!templateSignatureValid) {
|
|
143
|
-
throw core_1.
|
|
144
|
+
throw core_1.TransportCoreErrors.general.signatureNotValid("template");
|
|
144
145
|
}
|
|
145
146
|
const cachedTemplate = CachedRelationshipTemplate_1.CachedRelationshipTemplate.from({
|
|
146
147
|
content: templateContent.content,
|
|
147
|
-
createdBy:
|
|
148
|
-
createdByDevice:
|
|
149
|
-
createdAt:
|
|
150
|
-
expiresAt: response.expiresAt ?
|
|
148
|
+
createdBy: core_types_1.CoreAddress.from(response.createdBy),
|
|
149
|
+
createdByDevice: core_types_1.CoreId.from(response.createdByDevice),
|
|
150
|
+
createdAt: core_types_1.CoreDate.from(response.createdAt),
|
|
151
|
+
expiresAt: response.expiresAt ? core_types_1.CoreDate.from(response.expiresAt) : undefined,
|
|
151
152
|
identity: templateContent.identity,
|
|
152
153
|
maxNumberOfAllocations: response.maxNumberOfAllocations ?? undefined,
|
|
153
154
|
templateKey: templateContent.templateKey
|
|
@@ -162,10 +163,10 @@ class RelationshipTemplateController extends TransportController_1.TransportCont
|
|
|
162
163
|
return RelationshipTemplate_1.RelationshipTemplate.from(templateDoc);
|
|
163
164
|
}
|
|
164
165
|
async setRelationshipTemplateMetadata(idOrTemplate, metadata) {
|
|
165
|
-
const id = idOrTemplate instanceof
|
|
166
|
+
const id = idOrTemplate instanceof core_types_1.CoreId ? idOrTemplate.toString() : idOrTemplate.id.toString();
|
|
166
167
|
const templateDoc = await this.templates.read(id);
|
|
167
168
|
if (!templateDoc) {
|
|
168
|
-
throw core_1.
|
|
169
|
+
throw core_1.TransportCoreErrors.general.recordNotFound(RelationshipTemplate_1.RelationshipTemplate, id.toString());
|
|
169
170
|
}
|
|
170
171
|
const template = RelationshipTemplate_1.RelationshipTemplate.from(templateDoc);
|
|
171
172
|
template.setMetadata(metadata);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RelationshipTemplateController.js","sourceRoot":"","sources":["../../../src/modules/relationshipTemplates/RelationshipTemplateController.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,gDAAwC;AACxC,0CAA0E;AAC1E,
|
|
1
|
+
{"version":3,"file":"RelationshipTemplateController.js","sourceRoot":"","sources":["../../../src/modules/relationshipTemplates/RelationshipTemplateController.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,gDAAwC;AACxC,kDAAkE;AAClE,0CAA0E;AAC1E,qCAA6D;AAC7D,kEAA+D;AAC/D,wEAAqF;AACrF,yCAAmE;AAMnE,sFAAmF;AACnF,mFAAgF;AAChF,uEAAoE;AACpE,mGAAqI;AACrI,0GAAuG;AACvG,gGAA6F;AAC7F,0FAAuF;AAEvF,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,iBAAiB,EAAE,YAAY,CAAC,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE;SAC1D,CAAC,CAAC;QAEH,KAAK,MAAM,QAAQ,IAAI,oBAAoB,EAAE,CAAC;YAC1C,MAAM,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;QAC1C,CAAC;IACL,CAAC;CACJ;AA/PD,wEA+PC;AAlIiB;IADb,IAAA,cAAG,GAAE;;;;uFAYL;AAea;IADb,IAAA,cAAG,GAAE;;6CACmG,wBAAe;;iFA6BvH;AAWY;IADZ,IAAA,cAAG,GAAE;;;;qFAaL"}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { ISerializable, Serializable } from "@js-soft/ts-serval";
|
|
2
|
+
import { CoreAddress, CoreDate, CoreId, ICoreAddress, ICoreDate, ICoreId } from "@nmshd/core-types";
|
|
2
3
|
import { ICryptoExchangePublicKey } from "@nmshd/crypto";
|
|
3
|
-
import { CoreAddress, CoreDate, CoreSerializable, ICoreAddress, ICoreDate, ICoreSerializable } from "../../../core";
|
|
4
|
-
import { CoreId, ICoreId } from "../../../core/types/CoreId";
|
|
5
4
|
import { IIdentity, Identity } from "../../accounts/data/Identity";
|
|
6
5
|
import { RelationshipTemplatePublicKey } from "../transmission/RelationshipTemplatePublicKey";
|
|
7
|
-
export interface ICachedRelationshipTemplate extends
|
|
6
|
+
export interface ICachedRelationshipTemplate extends ISerializable {
|
|
8
7
|
identity: IIdentity;
|
|
9
8
|
createdBy: ICoreAddress;
|
|
10
9
|
createdByDevice: ICoreId;
|
|
@@ -14,7 +13,7 @@ export interface ICachedRelationshipTemplate extends ICoreSerializable {
|
|
|
14
13
|
expiresAt?: ICoreDate;
|
|
15
14
|
maxNumberOfAllocations?: number;
|
|
16
15
|
}
|
|
17
|
-
export declare class CachedRelationshipTemplate extends
|
|
16
|
+
export declare class CachedRelationshipTemplate extends Serializable implements ICachedRelationshipTemplate {
|
|
18
17
|
identity: Identity;
|
|
19
18
|
createdBy: CoreAddress;
|
|
20
19
|
createdByDevice: CoreId;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CachedRelationshipTemplate.d.ts","sourceRoot":"","sources":["../../../../src/modules/relationshipTemplates/local/CachedRelationshipTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAA6B,MAAM,oBAAoB,CAAC;AAC5F,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"CachedRelationshipTemplate.d.ts","sourceRoot":"","sources":["../../../../src/modules/relationshipTemplates/local/CachedRelationshipTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAA6B,MAAM,oBAAoB,CAAC;AAC5F,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,EAAE,YAAY,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AACpG,OAAO,EAAE,wBAAwB,EAAE,MAAM,eAAe,CAAC;AACzD,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACnE,OAAO,EAAE,6BAA6B,EAAE,MAAM,+CAA+C,CAAC;AAE9F,MAAM,WAAW,2BAA4B,SAAQ,aAAa;IAC9D,QAAQ,EAAE,SAAS,CAAC;IACpB,SAAS,EAAE,YAAY,CAAC;IACxB,eAAe,EAAE,OAAO,CAAC;IACzB,WAAW,EAAE,wBAAwB,CAAC;IACtC,OAAO,EAAE,aAAa,CAAC;IACvB,SAAS,EAAE,SAAS,CAAC;IACrB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC;CACnC;AAED,qBACa,0BAA2B,SAAQ,YAAa,YAAW,2BAA2B;IAGxF,QAAQ,EAAE,QAAQ,CAAC;IAInB,SAAS,EAAE,WAAW,CAAC;IAIvB,eAAe,EAAE,MAAM,CAAC;IAIxB,WAAW,EAAE,6BAA6B,CAAC;IAI3C,OAAO,EAAE,YAAY,CAAC;IAItB,SAAS,EAAE,QAAQ,CAAC;IAIpB,SAAS,CAAC,EAAE,QAAQ,CAAC;IAIrB,sBAAsB,CAAC,EAAE,MAAM,CAAC;WAEzB,IAAI,CAAC,KAAK,EAAE,2BAA2B,GAAG,0BAA0B;CAGrF;AAED,wBAAgB,8BAA8B,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAQjF"}
|
|
@@ -12,11 +12,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
12
12
|
exports.CachedRelationshipTemplate = void 0;
|
|
13
13
|
exports.validateMaxNumberOfAllocations = validateMaxNumberOfAllocations;
|
|
14
14
|
const ts_serval_1 = require("@js-soft/ts-serval");
|
|
15
|
-
const
|
|
16
|
-
const CoreId_1 = require("../../../core/types/CoreId");
|
|
15
|
+
const core_types_1 = require("@nmshd/core-types");
|
|
17
16
|
const Identity_1 = require("../../accounts/data/Identity");
|
|
18
17
|
const RelationshipTemplatePublicKey_1 = require("../transmission/RelationshipTemplatePublicKey");
|
|
19
|
-
let CachedRelationshipTemplate = class CachedRelationshipTemplate extends
|
|
18
|
+
let CachedRelationshipTemplate = class CachedRelationshipTemplate extends ts_serval_1.Serializable {
|
|
20
19
|
static from(value) {
|
|
21
20
|
return this.fromAny(value);
|
|
22
21
|
}
|
|
@@ -30,12 +29,12 @@ __decorate([
|
|
|
30
29
|
__decorate([
|
|
31
30
|
(0, ts_serval_1.validate)(),
|
|
32
31
|
(0, ts_serval_1.serialize)(),
|
|
33
|
-
__metadata("design:type",
|
|
32
|
+
__metadata("design:type", core_types_1.CoreAddress)
|
|
34
33
|
], CachedRelationshipTemplate.prototype, "createdBy", void 0);
|
|
35
34
|
__decorate([
|
|
36
35
|
(0, ts_serval_1.validate)(),
|
|
37
36
|
(0, ts_serval_1.serialize)(),
|
|
38
|
-
__metadata("design:type",
|
|
37
|
+
__metadata("design:type", core_types_1.CoreId)
|
|
39
38
|
], CachedRelationshipTemplate.prototype, "createdByDevice", void 0);
|
|
40
39
|
__decorate([
|
|
41
40
|
(0, ts_serval_1.validate)(),
|
|
@@ -50,12 +49,12 @@ __decorate([
|
|
|
50
49
|
__decorate([
|
|
51
50
|
(0, ts_serval_1.validate)(),
|
|
52
51
|
(0, ts_serval_1.serialize)(),
|
|
53
|
-
__metadata("design:type",
|
|
52
|
+
__metadata("design:type", core_types_1.CoreDate)
|
|
54
53
|
], CachedRelationshipTemplate.prototype, "createdAt", void 0);
|
|
55
54
|
__decorate([
|
|
56
55
|
(0, ts_serval_1.validate)({ nullable: true }),
|
|
57
56
|
(0, ts_serval_1.serialize)(),
|
|
58
|
-
__metadata("design:type",
|
|
57
|
+
__metadata("design:type", core_types_1.CoreDate)
|
|
59
58
|
], CachedRelationshipTemplate.prototype, "expiresAt", void 0);
|
|
60
59
|
__decorate([
|
|
61
60
|
(0, ts_serval_1.validate)({ nullable: true, customValidator: validateMaxNumberOfAllocations }),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CachedRelationshipTemplate.js","sourceRoot":"","sources":["../../../../src/modules/relationshipTemplates/local/CachedRelationshipTemplate.ts"],"names":[],"mappings":";;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"CachedRelationshipTemplate.js","sourceRoot":"","sources":["../../../../src/modules/relationshipTemplates/local/CachedRelationshipTemplate.ts"],"names":[],"mappings":";;;;;;;;;;;;AAwDA,wEAQC;AAhED,kDAA4F;AAC5F,kDAAoG;AAEpG,2DAAmE;AACnE,iGAA8F;AAcvF,IAAM,0BAA0B,GAAhC,MAAM,0BAA2B,SAAQ,wBAAY;IAiCjD,MAAM,CAAC,IAAI,CAAC,KAAkC;QACjD,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;IAC/B,CAAC;CACJ,CAAA;AApCY,gEAA0B;AAG5B;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACK,mBAAQ;4DAAC;AAInB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACM,wBAAW;6DAAC;AAIvB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACY,mBAAM;mEAAC;AAIxB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACQ,6DAA6B;+DAAC;AAI3C;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACI,wBAAY;2DAAC;AAItB;IAFN,IAAA,oBAAQ,GAAE;IACV,IAAA,qBAAS,GAAE;8BACM,qBAAQ;6DAAC;AAIpB;IAFN,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IAC5B,IAAA,qBAAS,GAAE;8BACO,qBAAQ;6DAAC;AAIrB;IAFN,IAAA,oBAAQ,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,eAAe,EAAE,8BAA8B,EAAE,CAAC;IAC7E,IAAA,qBAAS,GAAE;;0EAC2B;qCA/B9B,0BAA0B;IADtC,IAAA,gBAAI,EAAC,4BAA4B,CAAC;GACtB,0BAA0B,CAoCtC;AAED,SAAgB,8BAA8B,CAAC,KAAc;IACzD,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO;IAEhC,IAAI,KAAK,IAAI,CAAC,EAAE,CAAC;QACb,OAAO,+CAA+C,CAAC;IAC3D,CAAC;IAED,OAAO;AACX,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { CoreDate, ICoreDate } from "@nmshd/core-types";
|
|
1
2
|
import { CryptoSecretKey, ICryptoSecretKey } from "@nmshd/crypto";
|
|
2
3
|
import { CoreSynchronizable, ICoreSynchronizable } from "../../../core";
|
|
3
|
-
import { CoreDate, ICoreDate } from "../../../core/types/CoreDate";
|
|
4
4
|
import { RelationshipTemplateReference } from "../transmission/RelationshipTemplateReference";
|
|
5
5
|
import { CachedRelationshipTemplate, ICachedRelationshipTemplate } from "./CachedRelationshipTemplate";
|
|
6
6
|
export interface IRelationshipTemplate extends ICoreSynchronizable {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RelationshipTemplate.d.ts","sourceRoot":"","sources":["../../../../src/modules/relationshipTemplates/local/RelationshipTemplate.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"RelationshipTemplate.d.ts","sourceRoot":"","sources":["../../../../src/modules/relationshipTemplates/local/RelationshipTemplate.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAElE,OAAO,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AACxE,OAAO,EAAE,6BAA6B,EAAE,MAAM,+CAA+C,CAAC;AAC9F,OAAO,EAAE,0BAA0B,EAAE,2BAA2B,EAAE,MAAM,8BAA8B,CAAC;AAEvG,MAAM,WAAW,qBAAsB,SAAQ,mBAAmB;IAC9D,SAAS,EAAE,gBAAgB,CAAC;IAC5B,KAAK,EAAE,OAAO,CAAC;IACf,KAAK,CAAC,EAAE,2BAA2B,CAAC;IACpC,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,QAAQ,CAAC,EAAE,GAAG,CAAC;IACf,kBAAkB,CAAC,EAAE,SAAS,CAAC;CAClC;AAED,qBACa,oBAAqB,SAAQ,kBAAmB,YAAW,qBAAqB;IACzF,SAAyB,mBAAmB,WAAyH;IAErK,SAAyB,kBAAkB,WAAgH;IAIpJ,SAAS,EAAE,eAAe,CAAC;IAI3B,KAAK,EAAE,OAAO,CAAC;IAIf,KAAK,CAAC,EAAE,0BAA0B,CAAC;IAInC,QAAQ,CAAC,EAAE,QAAQ,CAAC;IAIpB,QAAQ,CAAC,EAAE,GAAG,CAAC;IAIf,kBAAkB,CAAC,EAAE,QAAQ,CAAC;WAEvB,IAAI,CAA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