HEX
Server: Apache
System: Linux scp1.abinfocom.com 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
User: confeduphaar (1010)
PHP: 8.1.33
Disabled: exec,passthru,shell_exec,system
Upload Files
File: //usr/lib/python3/dist-packages/sos/cleaner/parsers/__pycache__/hostname_parser.cpython-38.pyc
U

i��d'�@s4ddlZddlmZddlmZGdd�de�ZdS)�N)�SoSCleanerParser)�SoSHostnameMapcs2eZdZdZdZdgZ�fdd�Zdd�Z�ZS)�SoSHostnameParserzHostname ParserZhostname_mapz5(((\b|_)[a-zA-Z0-9-\.]{1,200}\.[a-zA-Z]{1,63}(\b|_)))cst�|_tt|��|�dS)N)r�mapping�superr�__init__)�selfZconfig��	__class__��E/usr/lib/python3/dist-packages/sos/cleaner/parsers/hostname_parser.pyrszSoSHostnameParser.__init__cCsfd}|jD] }t�||tj�r
||fSq
|�|�\}}||7}|jr^|�|�\}}||7}||fS)aThis will be called for every line in every file we process, so that
        every parser has a chance to scrub everything.

        We are overriding parent method since we need to swap ordering of
        _parse_line_with_compiled_regexes and _parse_line calls.
        r)Zskip_line_patterns�re�match�IZ_parse_lineZcompile_regexesZ!_parse_line_with_compiled_regexes)r�line�countZskip_pattern�_countZ_rcountrrr�
parse_lines
zSoSHostnameParser.parse_line)	�__name__�
__module__�__qualname__�nameZmap_file_keyZregex_patternsrr�
__classcell__rrr	rrs�r)r
Zsos.cleaner.parsersrZ!sos.cleaner.mappings.hostname_maprrrrrr�<module>s