Example #1
0
 def new_raw_decrypting_stream(
         self, ciphertext_source: BinaryIO, associated_data: bytes,
         close_ciphertext_source: bool) -> io.RawIOBase:
     return _decrypting_stream.RawDecryptingStream(
         self._cc_streaming_aead,
         ciphertext_source,
         associated_data,
         close_ciphertext_source=close_ciphertext_source)
def get_raw_decrypting_stream(
        ciphertext_source: BinaryIO,
        aad: bytes,
        close_ciphertext_source: bool = True) -> io.RawIOBase:
    return _decrypting_stream.RawDecryptingStream(
        None,
        ciphertext_source,
        aad,
        close_ciphertext_source=close_ciphertext_source)
Example #3
0
def get_decrypting_stream(ciphertext_source: BinaryIO, aad: bytes) -> BinaryIO:
    raw = _decrypting_stream.RawDecryptingStream(None, ciphertext_source, aad)
    return cast(BinaryIO, io.BufferedReader(raw))
 def new_decrypting_stream(self, ciphertext_source: BinaryIO,
                           associated_data: bytes) -> BinaryIO:
   raw = _decrypting_stream.RawDecryptingStream(self._cc_streaming_aead,
                                                ciphertext_source,
                                                associated_data)
   return typing.cast(BinaryIO, io.BufferedReader(raw))