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__/libreswan.cpython-39.pyc
a

\��h�	�@s.ddlmZmZmZmZGdd�dee�ZdS)�)�Plugin�IndependentPlugin�SoSPredicate�	PluginOptc@s@eZdZdZdZdZedddd�gZdZd	Z	d
d�Z
dd
�ZdS)�	LibreswanzLibreswan IPsec�	libreswan)�networkZsecurityZ	openshift�
ipsec-barfFzcollect ipsec barf output)�defaultZdesc)�/etc/ipsec.conf)rZopenswancCsj|�gd��|�gd��t|ddgddid�}|jdd	g|d
�|�d�rX|�d�|�gd
��dS)N)rz/etc/ipsec.dz/proc/net/xfrm_stat)zipsec verifyzipsec whack --statuszipsec whack --listallzcertutil -L -d sql:/etc/ipsec.dZ	xfrm_userZ	xfrm_algo�kmods�all)r�requiredzip xfrm policyz
ip xfrm state)Zpredr	z
ipsec barf)z/etc/ipsec.secretsz/etc/ipsec.secrets.dz/etc/ipsec.d/*.dbz/etc/ipsec.d/*.secrets)Z
add_copy_specZadd_cmd_outputr�
get_optionZadd_forbidden_path)�selfZ	xfrm_pred�r�@/usr/lib/python3.9/site-packages/sos/report/plugins/libreswan.py�setups
���

zLibreswan.setupcCs.d}|�d|d�|�d�r*|�d|d�dS)Nz/(aead|auth|auth-trunc|enc)(\s.*\s)(0x[0-9a-f]+)�statez\1\2********r	Zbarf)Zdo_cmd_output_subr)rZxfrm_state_regexprrr�postproc@s�
�zLibreswan.postprocN)�__name__�
__module__�__qualname__Z
short_descZplugin_nameZprofilesrZoption_list�filesZpackagesrrrrrrrs��"rN)Zsos.report.pluginsrrrrrrrrr�<module>s