PdfRpt.FluentInterface.EncryptedFileBuilder.WithPublicKey C# (CSharp) Method

WithPublicKey() public method

Using a personal information exchange file to encrypt the pdf file.
public WithPublicKey ( string pfxPassword, string pfxPath ) : void
pfxPassword string Certificate file's password
pfxPath string Certificate file's path
return void
        public void WithPublicKey(string pfxPassword, string pfxPath)
        {
            _encryptionPreferences.EncryptionType = EncryptionType.PublicKeyEncryption;
            _encryptionPreferences.PublicKeyEncryption = new PublicKeyEncryption
            {
                PfxPassword = pfxPassword,
                PfxPath = pfxPath
            };
        }