Provides a streaming mechanism for ciphering data.


A CryptoStream can be written to or read from in the same manner as other stream objects. A CryptoStream is designed to be used in a daisy-chain fashion, allowing for multiple transformations to be applied as a single process.

By supplying another Stream object to the Cor.NewCryptoStream function, an automatic daisy-chaining of the two streams is created. The Stream does not have to be another CryptoStream object. It can be any object implementing the Stream interface.

See Also

Project VBCorLib Overview | Constructors





 CryptoStreamModeSpecifies modes for a CryptoStream. 


 CanRead (get)Returns if the Stream can be read from. 
 CanSeek (get)Returns if the Stream can seek. 
 CanTimeout (get)Returns if the Stream can timeout. 
 CanWrite (get)Returns if the Stream can be written to. 
 Length (get)Returns the length of the current Stream. 
 Position (get)Returns the current position withing the Stream. 
 Position (let)Sets the current position within the Stream. 
 ReadTimeout (get)Returns the amount of time must pass before a Read timeout occurs. 
 ReadTimeout (let)Sets the timeout period for Read operations. 
 WriteTimeout (get)Returns the timeout period for a write operation. 
 WriteTimeout (let)Sets the timeout period for a write operation. 


 BeginReadBegins an Asynchronous read operation (currently is only synchronous) 
 BeginWriteBegins an asynchronous buffer write. Currently the CryptoStream class does not support asynchronous buffer writing. 
 CloseStreamCloses the underlying Stream. 
 EndReadSignifies the end of an asynchronous read from the stream. 
 EndWriteSignifies the end of an asynchronous write to the stream. 
 EqualsReturns a boolean indicating if the value and this object instance are the same instance. 
 FlushFlushes the buffers of the underlying Stream. 
 FlushFinalBlockFlushes the remaining data to the underlying stream. 
 GetHashCodeReturns a psuedo-unique number used to help identify this object in memory. The current method is to return the value obtained from ObjPtr. If a different method needs to be impelmented then change the method here in this function. An override might be necessary if the hashcode should be derived from a value contained within the class. 
 ReadBlockReads a requested amount of data from the stream. 
 ReadByteReads a single byte from the Stream. 
 SeekPositionSeeks a new position within the Stream. 
 SetLengthSets the length of the current Stream. 
 ToStringReturns a string representation of this object instance. The default method simply returns the application name and class name in which this class resides. A Person class may return the persons name instead. 
 WriteBlockWrites an array of bytes to the Stream. 
 WriteByteWrites a single byte to the Stream.