%PDF- %PDF-
Direktori : /lib/python3/dist-packages/sos/cleaner/preppers/__pycache__/ |
Current File : //lib/python3/dist-packages/sos/cleaner/preppers/__pycache__/__init__.cpython-312.pyc |
� i��dW � � � d dl Z G d� d� Zy)� Nc �B � e Zd ZdZdZdZd� Zd� Zd� Zd� Z d� Z d � Zd � Zy)� SoSPreppera� A prepper is a way to prepare loaded mappings with selected items within an sos report prior to beginning the full obfuscation routine. This was previously handled directly within archives, however this is a bit cumbersome and doesn't allow for all the flexibility we could use in this effort. Preppers are separated from parsers but will leverage them in order to feed parser-matched strings from files highlighted by a Prepper() to the appropriate mapping for initial obfuscation. Preppers may specify their own priority in order to influence the order in which mappings are prepped. Further, Preppers have two ways to prepare the maps - either by generating a list of filenames or via directly pulling content out of select files without the assistance of a parser. A lower priority value means the prepper should run sooner than those with higher values. For the former approach, `Prepper._get_$parser_file_list()` should be used and should yield filenames that exist in target archives. For the latter, the `Prepper._get_items_for_$map()` should be used. Finally, a `regex_items` dict is available for storing individual regex items for parsers that rely on them. These items will be added after all files and other individual items are handled. This dict has keys set to parser/mapping names, and the values should be sets of items, so preppers should add to them like so: self.regex_items['hostname'].add('myhostname') � Undefined�d c � � t � t � t � t � t � t � d�| _ || _ t j d� | _ t j d� | _ y )N)�hostname�ip�ipv6�keyword�mac�username�sos�sos_ui)�set�regex_items�opts�logging� getLogger�soslog�ui_log)�self�optionss �?/usr/lib/python3/dist-packages/sos/cleaner/preppers/__init__.py�__init__zSoSPrepper.__init__2 sW � ����%��E��u��5��� ��� �� ��'�'��.����'�'��1��� c �&