HEX
Server: Apache
System: Linux 185.122.168.184.host.secureserver.net 5.14.0-570.60.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Nov 5 05:00:59 EST 2025 x86_64
User: barbeatleanalyti (1024)
PHP: 8.1.33
Disabled: NONE
Upload Files
File: //lib/python3.9/site-packages/sos/report/plugins/__pycache__/vault.cpython-39.opt-1.pyc
a

\��h��@s&ddlmZmZGdd�dee�ZdS)�)�Plugin�UbuntuPluginc@s4eZdZdZdZdZdZdZdZdd�Z	dd	�Z
d
S)�Vaultz�The Vault plugin collects the current status of the vault
    snap on a Ubuntu machine.

    It will collect logs from journal, vault status and configuration
    z3Manage access to secrets and protect sensitive data�vault)ZsysmgmtZsecurity)rc
Cs�d}|�|�z�t|ddd��b}|����D]D}|s6q,|�d�}|d��dkr,|d�d	�}|jd
d|id�q,Wd�n1s�0YWn:ty�}z"|�d
|�d|���WYd}~n
d}~00dS)N� /var/snap/vault/common/vault.hcl�rzUTF-8)�encoding�=r�api_addr�z" zvault statusZ
VAULT_ADDR)�envzCould not open conf file z: )	Z
add_copy_spec�open�read�
splitlines�split�stripZadd_cmd_output�IOErrorZ
_log_error)�selfZ	vault_cfg�cfile�line�wordsr
�error�r�</usr/lib/python3.9/site-packages/sos/report/plugins/vault.py�setups

�*zVault.setupcCs|�ddd�dS)Nrz(password\s?=\s?).*z\1******)Zdo_file_sub)rrrr�postproc/s
�zVault.postprocN)�__name__�
__module__�__qualname__�__doc__Z
short_descZplugin_nameZprofilesZservices�packagerrrrrrrsrN)Zsos.report.pluginsrrrrrrr�<module>s