Sets the stream from which the component will read data to encrypt or decrypt.
public void setInputStream(java.io.InputStream inputStream);
This method sets the stream from which the component will read data to encrypt or decrypt. If an input stream is set before the component attempts to encode or decode an OpenPGP message, the data is read from the input stream instead of from the InputFile or InputMessage properties.
Encrypt and/or Sign
You can call this method to set the input stream that you would like to sign and/or encrypt. Then call Sign, Encrypt, or SignAndEncrypt to sign and/or encrypt the message. The appropriate ASCII Armor headers will be generated in MessageHeaders.
Decrypt and/or Verify
You can call this method to specify a valid input stream that contains the signed and/or encrypted data you would like to verify or decrypt. Then call VerifySignature, Decrypt, or DecryptAndVerifySignature to verify and/or decrypt the message.
The content of the stream will be read from the current position all the way to the end and no bytes will be skipped.
Input and Output Properties
The component will determine the source and destination of the input and output based on which properties are set.
The order in which the input properties are checked is as follows:
When a valid source is found the search stops. The order in which the output properties are checked is as follows:
- OutputMessage: The output data is written to this property if no other destination is specified.