Class EncryptionSession

    • Constructor Detail

      • EncryptionSession

        EncryptionSession(MobileEncryptionSession encryptionSession)
    • Method Detail

      • addRecipients

         final Map<String, ActionStatus> addRecipients(Array<RecipientWithRights> recipients)

        Add new recipients to this session. These recipients will be able to read all encrypted messages of this session.

        Parameters:
        recipients - RecipientWithRights The Seald IDs with the associated rights of users to add to this session.
      • addRecipientsAsync

         final Map<String, ActionStatus> addRecipientsAsync(Array<RecipientWithRights> recipients)

        Add new recipients to this session. These recipients will be able to read all encrypted messages of this session.

        Parameters:
        recipients - The Seald IDs with the associated rights of users to add to this session.
      • addProxySession

         final Unit addProxySession(String proxySessionId, RecipientRights rights)

        Add a proxy session as a recipient of this session. Any recipient of the proxy session will also be able to retrieve this session. The current user has to be a direct recipient of the proxy session.

        Parameters:
        proxySessionId - The ID of the session to add as proxy.
        rights - The rights to assign to this proxy.
      • addProxySessionAsync

         final Unit addProxySessionAsync(String proxySessionId, RecipientRights rights)

        Add a proxy session as a recipient of this session. Any recipient of the proxy session will also be able to retrieve this session. The current user has to be a direct recipient of the proxy session.

        Parameters:
        proxySessionId - The ID of the session to add as proxy.
        rights - The ID of the session to add as proxy.
      • revokeRecipients

         final RevokeResult revokeRecipients(Array<String> recipientsIds, Array<String> proxySessionsIds)

        Revoke some recipients or proxy sessions from this session. If you want to revoke all recipients, see revokeAll instead. If you want to revoke all recipients besides yourself, see revokeOthers.

        Parameters:
        recipientsIds - The Seald IDs of users to revoke from this session.
        proxySessionsIds - The IDs of proxy sessions to revoke from this session.
      • revokeRecipientsAsync

         final RevokeResult revokeRecipientsAsync(Array<String> recipientsIds, Array<String> proxySessionsIds)

        Revoke some recipients or proxy sessions from this session. If you want to revoke all recipients, see revokeAll instead. If you want to revoke all recipients besides yourself, see revokeOthers.

        Parameters:
        recipientsIds - The Seald IDs of users to revoke from this session.
        proxySessionsIds - The IDs of proxy sessions to revoke from this session.
      • encryptMessage

         final String encryptMessage(String clearMessage)

        Encrypt a clear-text string into an encrypted message, for the recipients of this session.

        Parameters:
        clearMessage - The message to encrypt.
      • encryptMessageAsync

         final String encryptMessageAsync(String clearMessage)

        Encrypt a clear-text string into an encrypted message, for the recipients of this session.

        Parameters:
        clearMessage - The message to encrypt.
      • decryptMessage

         final String decryptMessage(String encryptedMessage)

        Decrypt an encrypted message string into the corresponding clear-text string.

        Parameters:
        encryptedMessage - The encrypted message to decrypt.
      • decryptMessageAsync

         final String decryptMessageAsync(String encryptedMessage)

        Decrypt an encrypted message string into the corresponding clear-text string.

        Parameters:
        encryptedMessage - The encrypted message to decrypt.
      • encryptFile

         final ByteArray encryptFile(ByteArray clearFile, String filename)

        Encrypt a clear-text file into an encrypted file, for the recipients of this session.

        Parameters:
        clearFile - A ByteArray of the clear-text content of the file to encrypt.
        filename - The name of the file to encrypt.
      • encryptFileAsync

         final ByteArray encryptFileAsync(ByteArray clearFile, String filename)

        Encrypt a clear-text file into an encrypted file, for the recipients of this session.

        Parameters:
        clearFile - A ByteArray of the clear-text content of the file to encrypt.
        filename - The name of the file to encrypt.
      • decryptFile

         final ClearFile decryptFile(ByteArray encryptedFile)

        Decrypts an encrypted file into the corresponding clear-text file.

        Parameters:
        encryptedFile - A ByteArray of the content of the encrypted file to decrypt.
      • decryptFileAsync

         final ClearFile decryptFileAsync(ByteArray encryptedFile)

        Decrypts an encrypted file into the corresponding clear-text file.

        Parameters:
        encryptedFile - A ByteArray of the content of the encrypted file to decrypt.
      • encryptFileFromURI

         final String encryptFileFromURI(String clearFileURI)

        Encrypt a clear file into an encrypted file, for the recipients of this session.

        Parameters:
        clearFileURI - A String URI of the file to encrypt.
      • encryptFileFromURIAsync

         final String encryptFileFromURIAsync(String clearFileURI)

        Encrypt a clear file into an encrypted file, for the recipients of this session.

        Parameters:
        clearFileURI - A String URI of the file to encrypt.
      • decryptFileFromURI

         final String decryptFileFromURI(String encryptedFileURI)

        Decrypts an encrypted file into the corresponding clear-text file.

        Parameters:
        encryptedFileURI - A String URI of the encrypted file to decrypt.
      • decryptFileFromURIAsync

         final String decryptFileFromURIAsync(String encryptedFileURI)

        Decrypts an encrypted file into the corresponding clear-text file.

        Parameters:
        encryptedFileURI - A String URI of the encrypted file to decrypt.
      • addTmrAccess

         final String addTmrAccess(TmrRecipientWithRights recipient)

        Add a TMR access to this session for the given authentication factor.

        Parameters:
        recipient - A TMR recipient with its associated rights.