CryptoManager.BeginEncrypting

Syntax variant: Data in return value

Syntax:

BeginEncrypting(<NotifyDescription>, <SourceData>, <Recipients>)

Parameters:

<NotifyDescription> (required)

Type: NotifyDescription.
Contains a description of the procedure that will be called upon completing data encryption with the following parameters:
  • <SignedData> - encrypted data of the type BinaryData.
  • <AdditionalParameters> - value specified when the NotifyDescription object was created.

<SourceData> (required)

Type: String: BinaryData.
Source data for encryption.
Data can be located in a file (in this case the name of file is specified) or represented as BinaryData.

<Recipients> (required)

Type: CryptoCertificate: Array.
The parameter can contain one certificate or an array of certificates.
Only recipients from the specified list (the recipients who have transferred certificates) will be able to decrypt the data using their private keys.

Description of method variant:

Performs the data encryption for defined users. Only users from defined list can decrypt the data using their keys.
The format of encrypted data is PKCS#7.
Uses the algorithm, specified in property EncryptAlgorithm.
After completion of encryption a procedure specified in the NotifyDescription parameter is called..
The procedure stated in parameter NotifyDescription must contain the parameters:
  • <EncryptedData> - encrypted data of the type BinaryData.
  • <AdditionalParameters>.
<EncryptedData> - encrypted data of the type BinaryData.
<AdditionalParameters>.

Syntax variant: Save data to a file

Syntax:

BeginEncrypting(<NotifyDescription>, <SourceData>, <OutputData>, <Recipients>)

Parameters:

<NotifyDescription> (required)

Type: NotifyDescription.
Contains a description of the procedure that will be called upon completing data encryption with the following parameters:
  • <FileName> - name of file, to which the data is put.
  • <AdditionalParameters> - value specified when the NotifyDescription object was created.

<SourceData> (required)

Type: BinaryData; String.
Source data for encryption.
Data can be located in a file (in this case the name of file is specified) or represented as BinaryData.

<OutputData> (required)

Type: String.
Name of file, to which the encrypted data is downloaded.

<Recipients> (required)

Type: CryptoCertificate: Array.
The parameter can contain one certificate or an array of certificate objects.
Only recipients from the specified list (the recipients who have transferred certificates) will be able to decrypt the data using their private keys.

Description of method variant:

Encrypted data is written to a file.

Description:

Begins the data encryption for defined users. Only users from defined list can decrypt the data using their keys.
The format of encrypted data is PKCS#7.
Uses the algorithm, specified in property EncryptAlgorithm.
After encryption is completed, the procedure with a name specified in NotifyDescription is called.

Availability:

Thin client, web-client, thick client.

See also:

CryptoManager, method Encrypt

    

1C:Enterprise Developer's Community