#if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR)
#pragma warning disable
using System;
using System.IO;
namespace BestHTTP.SecureProtocol.Org.BouncyCastle.Crypto
{
///
/// Base interface for a ciphers that do not require data to be block aligned.
///
/// Note: In cases where the underlying algorithm is block based, these ciphers may add or remove padding as needed.
///
///
public interface ICipher
{
///
/// Return the size of the output buffer required for a Write() plus a
/// close() with the write() being passed inputLen bytes.
///
/// The returned size may be dependent on the initialisation of this cipher
/// and may not be accurate once subsequent input data is processed as the cipher may
/// add, add or remove padding, as it sees fit.
///
///
/// The space required to accommodate a call to processBytes and doFinal with inputLen bytes of input.
/// The length of the expected input.
int GetMaxOutputSize(int inputLen);
///
/// Return the size of the output buffer required for a write() with the write() being
/// passed inputLen bytes and just updating the cipher output.
///
/// The space required to accommodate a call to processBytes with inputLen bytes of input.
/// The length of the expected input.
int GetUpdateOutputSize(int inputLen);
///
/// Gets the stream for reading/writing data processed/to be processed.
///
/// The stream associated with this cipher.
Stream Stream { get; }
}
}
#pragma warning restore
#endif