LibreOffice
LibreOffice 24.2 SDK API Reference
Public Member Functions | List of all members
XEncryptionProtectedStorage Interface Reference

This interface allows to set a password for an object. More...

import"XEncryptionProtectedStorage.idl";

Inheritance diagram for XEncryptionProtectedStorage:
XEncryptionProtectedSource2 XEncryptionProtectedSource XInterface

Public Member Functions

void setEncryptionAlgorithms ([in] sequence< ::com::sun::star::beans::NamedValue > aAlgorithms) raises ( ::com::sun::star::lang::IllegalArgumentException )
 allows to set the encryption algorithms for the object. More...
 
sequence< ::com::sun::star::beans::NamedValuegetEncryptionAlgorithms ()
 allows to get the encryption algorithms of the object. More...
 
void setGpgProperties ([in] sequence< sequence< ::com::sun::star::beans::NamedValue > > aProps) raises ( ::com::sun::star::lang::IllegalArgumentException )
 set OpenPGP-specific encryption properties More...
 
- Public Member Functions inherited from XEncryptionProtectedSource2
void setEncryptionData ([in] sequence< ::com::sun::star::beans::NamedValue > aEncryptionData) raises ( ::com::sun::star::io::IOException )
 sets an encryption data for the object. More...
 
boolean hasEncryptionData ()
 determine if an encryption data is set for this object. More...
 
- Public Member Functions inherited from XEncryptionProtectedSource
void setEncryptionPassword ([in] string sPassword) raises ( ::com::sun::star::io::IOException )
 sets a password for the object. More...
 
void removeEncryption () raises ( ::com::sun::star::io::IOException )
 removes encryption from the object. More...
 
- Public Member Functions inherited from XInterface
any queryInterface ([in] type aType)
 queries for a new interface to an existing UNO object. More...
 
void acquire ()
 increases the reference counter by one. More...
 
void release ()
 decreases the reference counter by one. More...
 

Detailed Description

This interface allows to set a password for an object.

Since
OOo 3.4

Member Function Documentation

◆ getEncryptionAlgorithms()

sequence< ::com::sun::star::beans::NamedValue > getEncryptionAlgorithms ( )

allows to get the encryption algorithms of the object.

◆ setEncryptionAlgorithms()

void setEncryptionAlgorithms ( [in] sequence< ::com::sun::star::beans::NamedValue aAlgorithms)
raises (::com::sun::star::lang::IllegalArgumentException
)

allows to set the encryption algorithms for the object.

The algorithms will of course be used only for streams that have been marked to be encrypted. If no stream in the storage is marked to be encrypted, the algorithms-related information may have no effect to the result package.

The following values could be part of the provided sequence:

StartKeyGenerationAlgorithm
specifies the algorithm that was used to generate the EncryptionKey from the original password; in case the contents should be decrypted, the algorithm might be already known by the object; if a different one is set an exception should be thrown to indicate the error; it should take values from com::sun::star::xml:crypto::DigestID.
KeyDerivationFunction
specifies the algorithm that was used to derive the encryption key from the password; it is applied to the result of the StartKeyGenerationAlgorithm; it should take values from com::sun::star::xml:crypto::KDFID.
EncryptionAlgorithm
specifies the algorithm that should be used to encrypt/decrypt the contents; in case the contents should be decrypted, the algorithm might be already known by the object; if a different one is set an exception should be thrown to indicate the error; it should take values from com::sun::star::xml:crypto::CipherID.
ChecksumAlgorithm
specifies the algorithm that was used to generate the checksum of the encrypted data; in case the contents should be decrypted, the algorithm might be already known by the object; if a different one is set an exception should be thrown to indicate the error; it should take values from com::sun::star::xml:crypto::DigestID.

◆ setGpgProperties()

void setGpgProperties ( [in] sequence< sequence< ::com::sun::star::beans::NamedValue > >  aProps)
raises (::com::sun::star::lang::IllegalArgumentException
)

set OpenPGP-specific encryption properties

When provided, switch ODF package encryption to OpenPGP.

For each recipient, add one sequence of named values, each of the same structure. The following values could be part of that provided sequence:

KeyId
specifies OpenPGP key ID or fingerprint of the public key used to encrypt this session key against
KeyPacket
(optional) public key packet of the key used to encrypt
CipherValue
OpenPGP-encrypted session key for this recipient
Since
LibreOffice 6.0

The documentation for this interface was generated from the following file: