
    ~ g                     ,    S SK JrJr   " S S\\5      rg)    )PluginUbuntuPluginc                   8    \ rS rSrSrSrSrSrSrSr	S r
S rS	rg
)Vault   zThe 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)sysmgmtsecurity)r   c                    SnU R                  U5         [        USSS9 nUR                  5       R                  5        H\  nU(       d  M  UR	                  S5      nUS   R                  5       S:X  d  M6  US   R                  S	5      nU R                  S
SU0S9  M^     S S S 5        g ! , (       d  f       g = f! [         a!  nU R                  SU SU 35         S nAg S nAff = f)N /var/snap/vault/common/vault.hclrzUTF-8)encoding=r   api_addr   z" zvault status
VAULT_ADDR)envzCould not open conf file z: )	add_copy_specopenread
splitlinessplitstripadd_cmd_outputIOError
_log_error)self	vault_cfgcfilelinewordsr   errors          :/usr/lib/python3/dist-packages/sos/report/plugins/vault.pysetupVault.setup   s    6	9%	Niw75!JJL335D  JJsOEQx~~':5#(8>>%#8++N1=x0H , J 6 877  	NOO7	{"UGLMM	Ns;   B9 AB(5*B(B9 (
B62B9 6B9 9
C$CC$c                 *    U R                  SSS5        g )Nr   z(password\s?=\s?).*z\1******)do_file_sub)r   s    r#   postprocVault.postproc/   s    ."	
     N)__name__
__module____qualname____firstlineno____doc__
short_descplugin_nameprofilesservicespackager$   r(   __static_attributes__r+   r*   r#   r   r      s.     GJK&HHGN&
r*   r   N)sos.report.pluginsr   r   r   r+   r*   r#   <module>r8      s    4&
FL &
r*   