| Server IP : 157.22.201.140 / Your IP : 216.73.216.74 Web Server : nginx/1.30.1 System : Linux mit.vincode.fvds.ru 6.8.0-111-generic #111-Ubuntu SMP PREEMPT_DYNAMIC Sat Apr 11 23:16:02 UTC 2026 x86_64 User : root ( 0) PHP Version : 8.3.6 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /lib/python3/dist-packages/passlib/__pycache__/ |
Upload File : |
�
XR_
� � � d Z ddlmZ ede� ddlmZ ddlmZ ddlm Z ddl
mZ g d�Zd Z
ej Zdd
�Zy)
a passlib.win32 - MS Windows support - DEPRECATED, WILL BE REMOVED IN 1.8
the LMHASH and NTHASH algorithms are used in various windows related contexts,
but generally not in a manner compatible with how passlib is structured.
in particular, they have no identifying marks, both being
32 bytes of binary data. thus, they can't be easily identified
in a context with other hashes, so a CryptHandler hasn't been defined for them.
this module provided two functions to aid in any use-cases which exist.
.. warning::
these functions should not be used for new code unless an existing
system requires them, they are both known broken,
and are beyond insecure on their own.
.. autofunction:: raw_lmhash
.. autofunction:: raw_nthash
See also :mod:`passlib.hash.nthash`.
� )�warnz�the 'passlib.win32' module is deprecated, and will be removed in passlib 1.8; please use the 'passlib.hash.nthash' and 'passlib.hash.lmhash' classes instead.)�hexlify)�unicode)�des_encrypt_block)�nthash)r �
raw_lmhash�
raw_nthashs KGS!@#$%c � � t | t � r| j |� } | j � dd ddt | � z
z z }t |dd t � t |dd t � z }|rt |� j d� S |S )z]encode password using des-based LMHASH algorithm; returns string of raw bytes, or unicode hexN� � � �ascii) �
isinstancer �encode�upper�lenr �LM_MAGICr �decode)�secret�encoding�hex�ns�outs �//usr/lib/python3/dist-packages/passlib/win32.pyr r 5 s� � � �&�'�"����x�(�� ������ �w�"�S��[�.�9� 9�B�
�B�r��F�H�
-�0A�"�Q�R�&�(�0S�
S�C�+.�7�3�<���w�'�7�C�7� N)r F)�__doc__�warningsr �DeprecationWarning�binasciir �passlib.utils.compatr �passlib.crypto.desr �passlib.hashr �__all__r r r � r r �<module>r% sO ���. � � .� �� � )� 0� ��� ��
�
�
�
�8r