:py:mod:`acquire.acquire.tools.decrypter` ========================================= .. py:module:: acquire.acquire.tools.decrypter Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: acquire.acquire.tools.decrypter.EncryptedFile Functions ~~~~~~~~~ .. autoapisummary:: :nosignatures: acquire.acquire.tools.decrypter.decrypt_header acquire.acquire.tools.decrypter.check_existing acquire.acquire.tools.decrypter.worker acquire.acquire.tools.decrypter.setup_logging acquire.acquire.tools.decrypter.main acquire.acquire.tools.decrypter.show_duplicates acquire.acquire.tools.decrypter.find_enc_files Attributes ~~~~~~~~~~ .. autoapisummary:: acquire.acquire.tools.decrypter.progress acquire.acquire.tools.decrypter.log acquire.acquire.tools.decrypter.CHUNK_SIZE acquire.acquire.tools.decrypter.WORKER_COUNT acquire.acquire.tools.decrypter.STATUS_EXIT acquire.acquire.tools.decrypter.STATUS_INFO acquire.acquire.tools.decrypter.STATUS_START acquire.acquire.tools.decrypter.STATUS_UPDATE .. py:data:: progress .. py:data:: log .. py:data:: CHUNK_SIZE .. py:data:: WORKER_COUNT .. py:data:: STATUS_EXIT :value: 0 .. py:data:: STATUS_INFO :value: 1 .. py:data:: STATUS_START :value: 2 .. py:data:: STATUS_UPDATE :value: 3 .. py:exception:: VerifyError Bases: :py:obj:`Exception` Common base class for all non-exit exceptions. .. py:class:: EncryptedFile(fh, key_file=None, key_server=None) Bases: :py:obj:`dissect.util.stream.AlignedStream` Basic buffered stream that provides easy aligned reads. Must be subclassed for various stream implementations. Subclasses can implement: - _read(offset, length) - _seek(pos, whence=io.SEEK_SET) The offset and length for _read are guaranteed to be aligned. The only time that overriding _seek would make sense is if there's no known size of your stream, but still want to provide SEEK_END functionality. Most subclasses of AlignedStream take one or more file-like objects as source. Operations on these subclasses, like reading, will modify the source file-like object as a side effect. :param size: The size of the stream. This is used in read and seek operations. None if unknown. :param align: The alignment size. Read operations are aligned on this boundary. Also determines buffer size. .. py:property:: file_header .. py:property:: header .. py:property:: footer .. py:property:: timestamp .. py:method:: seekable() Return whether object supports random access. If False, seek(), tell() and truncate() will raise OSError. This method may need to do a test seek(). .. py:method:: seek(pos, whence=io.SEEK_CUR) Seek the stream to the specified position. .. py:method:: chunks(chunk_size=CHUNK_SIZE) .. py:method:: verify() .. py:function:: decrypt_header(header, fingerprint, key_file=None, key_server=None) .. py:function:: check_existing(in_path: pathlib.Path, out_path: pathlib.Path, status_queue: multiprocessing.Queue) -> bool .. py:function:: worker(task_id, stop_event, status_queue, in_path, out_path, key_file=None, key_server=None, clobber=False) .. py:function:: setup_logging(logger, verbosity) .. py:function:: main() .. py:function:: show_duplicates(output_directory: pathlib.Path, files: list[pathlib.Path]) -> None .. py:function:: find_enc_files(files: list[pathlib.Path]) -> list[pathlib.Path]