403Webshell
Server IP : 178.105.222.151  /  Your IP : 216.73.216.38
Web Server : nginx/1.28.3
System : Linux MNK 7.0.0-15-generic #15-Ubuntu SMP PREEMPT_DYNAMIC Wed Apr 22 16:06:43 UTC 2026 x86_64
User : www-data ( 33)
PHP Version : 8.5.4
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/landscape/sysinfo/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/landscape/sysinfo/__pycache__/sysinfo.cpython-314.pyc
+
�e�i�&��z�^RIt^RIt^RIt^RIHt^RIHt^RIHt^RI	H
t
^RIHt!RR]
4t
R
R	ltR#)�N)�	getLogger)�Failure)�log_failure)�PluginRegistry)�gather_resultsc�laa�]tRt^
toRtV3RltRtRtRtRt	Rt
RtR	tR
t
RtRtVtV;t#)
�SysInfoPluginRegistrya
When the sysinfo plugin registry is run, it will run each of the
registered plugins so that they get a chance to feed information
into the registry.

There are three kinds of details collected: headers, notes, and footnotes.

They are presented to the user in a way similar to the following:

    Header1: Value1   Header3: Value3
    Header2: Value2   Header4: Value4

    => This is first note
    => This is the second note

    The first footnote.
    The second footnote.

Headers are supposed to display information which is regularly
available, such as the load and temperature of the system.  Notes
contain eventual information, such as warnings of high temperatures,
and low disk space.  Finally, footnotes contain pointers to further
information such as URLs.
c�j<�\SV`4/Vn.Vn.Vn.VnRVnR#)FN)�super�__init__�
_header_index�_headers�_notes�
_footnotes�
_plugin_error)�self�	__class__s&��;/usr/lib/python3/dist-packages/landscape/sysinfo/sysinfo.pyr�SysInfoPluginRegistry.__init__'s3���
���������
�������"���c�,�VPPV4pVfA\VP4VPV&VPP	W34R#V^,
pW0PV&VPPW1V34R#)a:Add a new information header to be displayed to the user.

Header names can be repeated.

Headers with value None are not returned by get_headers(), but
they still allocate a position in the list.  This fact may be
explored to create a deterministic ordering even when dealing
with values obtained asynchornously.
N)r
�get�lenr�append�insert)r�name�value�indexs&&& r�
add_header� SysInfoPluginRegistry.add_header/sy���"�"�&�&�t�,���=�'*�4�=�=�'9�D���t�$��M�M� � �$��/��Q�J�E�',���t�$��M�M� � ��u�
�6rc�\�VPUu.uFq^,fKVNK	up#uupi)z�Get all information headers to be displayed to the user.

Headers which were added with value None are not included in
the result.
)r)r�pairs& r�get_headers�!SysInfoPluginRegistry.get_headersBs&��"&���F���q�'����F�F��Fs�)�)c�<�VPPV4R#)z<Add a new eventual note to be shown up to the administrator.N)rr�r�notes&&r�add_note�SysInfoPluginRegistry.add_noteJs�������4� rc��VP#)z;Get all eventual notes to be shown up to the administrator.)r�rs&r�	get_notes�SysInfoPluginRegistry.get_notesNs���{�{�rc�<�VPPV4R#)z7Add a new footnote to be shown up to the administrator.N)rrr&s&&r�add_footnote�"SysInfoPluginRegistry.add_footnoteRs�������t�$rc��VP#)z6Get all footnotes to be shown up to the administrator.)rr+s&r�
get_footnotes�#SysInfoPluginRegistry.get_footnotesVs�����rc�P�.pVP4FApVP4pVPVPV4VP	V4KC	\V4PVP4# \
dTP\
4T4K�i;i)z�Run all plugins, and return a deferred aggregating their results.

This will call the run() method on each of the registered plugins,
and return a deferred which aggregates each resulting deferred.
)
�get_plugins�run�
addErrback�_log_plugin_errorr�	Exceptionrr�addCallback�_report_error_note)r�	deferreds�plugin�results&   rr6�SysInfoPluginRegistry.runZs����	��&�&�(�F�
)�������!�!�$�"8�"8�&�A�� � ��(�)��i�(�4�4�T�5L�5L�M�M���
:��&�&�w�y�&�9�
:�s�A<�<%B%�$B%c�v�RVnVPPR2p\R4p\	WVR7R#)Tz plugin raised an exception.zlandscape-sysinfo)�loggerN)rr�__name__rr)r�failurer=�messagerAs&&&  rr8�'SysInfoPluginRegistry._log_plugin_errorks9��!����%�%�.�.�/�/K�L���.�/���G�V�4rc��^RIHpVP'd;\PPV!4R4pVP
RVR24V#)r)�get_landscape_log_directoryzsysinfo.logz@There were exceptions while processing one or more plugins. See z for more information.)�landscape.sysinfo.deploymentrGr�os�path�joinr()rr>rGrJs&&  rr;�(SysInfoPluginRegistry._report_error_noteqsN��L������7�7�<�<� ;� =�}�M�D��M�M���f�2�4�
��
r)rr
rrr)rB�
__module__�__qualname__�__firstlineno__�__doc__rrr#r(r,r/r2r6r8r;�__static_attributes__�__classdictcell__�
__classcell__)r�
__classdict__s@@rr	r	
sC�����2#�7�&G�!��%��N�"5�	�	rr	c�a�V\S4,p\V4pRpTp	VF1wr�\V	\V
4\V4,^,4p	K3	\\P!\V4V	\V4,,44p\\P!V\V4,44p
.p^p\
V4F�p^p^p\
V
4FQpVV
,V,pVV8gKVV,wr�\V\V
44p\V\V44pKS	V^8�dV\V4,
pVVV,\V4,,
pVPVV34K�	V^8XgW�8dMV^,pEK.p\
V
4F�pSp\
V4F�pVV
,V,pVV8gKVV,wr�VV,wppV^8�d
VV,
pVV
V,RV\V
4,
,,V,,
pVV^,V
,V,8�gK�VRV\V4,
,,
pK�	VPV4K�	V'deV'dVPR4SV,pVF<pVP\P!VVR\V4,VR74K>	V'd5V'dVPR4VPV3RlV44RPV4#)a�Format sysinfo headers, notes and footnotes to be displayed.

This function will format headers notes and footnotes in a way that
looks similar to the following:

    Header1: Value1   Header3: Value3
    Header2: Value2   Header4: Value4

    => This is first note
    => This is the second note

    The first footnote.
    The second footnote.

Header columns will be dynamically adjusted to conform to the size
of header labels and values.
z: � �)�initial_indent�subsequent_indent�widthc3�6<"�TFpSV,x�K	R#5i)N�)�.0�footnote�indents& �r�	<genexpr>�!format_sysinfo.<locals>.<genexpr>s����A�y�8�V�h�&�&�y�s��
)
r�min�int�math�ceil�float�range�maxr�extend�textwrap�wraprK)�headers�notes�	footnotesrZr_�column_separator�note_prefix�headers_len�value_separator�
min_length�headerr�columns�headers_per_column�header_lengths�total_length�column�widest_header_len�widest_value_len�row�header_index�lines�linerXr's&&&&f&&                  r�format_sysinfor�}s���8
�S��[��E��g�,�K��O�
�J� �
������K�#�e�*�$�q�(�
�
�!�
��	�	�%��,�*�s�3C�/D�"D�E�F��G��!����;��w��+G�!H�I�������G�n�F�!"�� ���/�0��%�(:�:�S�@�� �+�-�$+�L�$9�M�F�(+�,=�s�6�{�(K�%�'*�+;�S��Z�'H�$�1���z���$4� 5�5���-�0@�@�3��CW�W�W�L�
�!�!�#4�6F�"G�H�-%�0�a�<�<�/�
�	�1���
�E��'�(����
�G�n�F�!�$6�6��<�L��k�)� '�� 5�
��6D�V�6L�3�!�#3��A�:��,�,�D���%�&��.��V��<�=�>������&�1�*�0B�!B�S�!H�H��C�#3�c�%�j�#@�A�A�D�+%�,	���T��9)�<
���L�L����+�-���D��L�L��
�
��#1�&)�C��,?�&?��	�
�����L�L���
���A�y�A�A��9�9�U��r)r\r\r\�PrWz   z=> )rerIrk�loggingr�twisted.python.failurer�landscape.lib.logr�landscape.lib.pluginr�landscape.lib.twisted_utilrr	r�r\rr�<module>r�s2���	���*�)�/�5�m�N�m�`Sr

Youez - 2016 - github.com/yon3zu
LinuXploit