Plumtree EDK (Enterprise Web Development Kit) 5.4.0 |

# ICredentialSetter.SetPrivateKey Method

Specify the private key to use to encrypt the password that is sent back to the portal to be saved.

void SetPrivateKey(
string key
);

#### Parameters

key
  Key used for RSA decryption.

#### Remarks

The `CredentialEncryptionType` must be set with the `SetCredentialEncryptionType` method. This value will only be used if it is not specified in a config file (web.config). A config file setting will override anything set with this method.

The config file parameter for this setting depends on the type of encryption being used, and can be one of: RSAPrivateKey, RC2PrivateKey, or AESPrivateKey.

#### See Also

ICredentialSetter Interface | Plumtree.Remote.Portlet Namespace