403Webshell
Server IP : 35.80.110.71  /  Your IP : 216.73.216.52
Web Server : Apache/2.4.58 (Ubuntu)
System : Linux ip-172-31-21-44 6.17.0-1019-aws #19~24.04.1-Ubuntu SMP Tue Jun 23 18:53:06 UTC 2026 x86_64
User : ubuntu ( 1000)
PHP Version : 8.3.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/css_parser/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/css_parser/__pycache__/tokenize2.cpython-312.pyc
�

��3eh.���dZddlmZmZmZmZddgZdZdZddl	m
Z
mZmZdd	l
mZdd
lZdd
lZdd
lZej$ddk\reZiZGd�de�Zd
�Zd�Zy
)z New CSS Tokenizer (a generator)
�)�unicode_literals�division�absolute_import�print_function�	Tokenizer�CSSProductions�restructuredtextz$Id$�)r�MACROS�PRODUCTIONS)�	normalizeN�c�6�eZdZdZej
ejejejejejd�ZdZe
jd�jZe
jd�jZd
d�Zd�Zd	�Zd
�Zd�Zdd�Zy)rz^
    generates a list of Token tuples:
        (Tokenname, value, startline, startcolumn)
    )z
@font-facez@importz@mediaz
@namespacez@pagez
@variables�
z*\\[0-9a-fA-F]{1,6}(?:\r\n|[\t\r\n\f\x20])?z\\((\r\n)|[\n\r\f])Nc���t|t�rt|j��}n|}t	||f�}|t
vrt
|\}}}n{|st}|st}|j|j||��}|D�	cgc]}	|	ddk(s�|	d��c}	d}|D�	cgc]}	|	ddk(s�|	d��c}	d}|||ft
|<||_
||_||_||_
g|_ycc}	wcc}	w)z�
        inits tokenizer with given macros and productions which default to
        css_parser own macros and productions
        r�COMMENTr
�URIN)�
isinstance�dict�sorted�items�str�_TOKENIZER_CACHErr�_compile_productions�_expand_macros�tokenmatches�commentmatcher�
urimatcher�_doComments�_pushed)
�self�macros�productions�
doComments�macros_hash_key�hash_keyrrr�xs
          �6/usr/lib/python3/dist-packages/css_parser/tokenize2.py�__init__zTokenizer.__init__(s��
�f�d�#�$�V�\�\�^�4�O�$�O����5�6���'�'�9I�(�9S�6�\�>�:�����)���4�4�T�5H�5H��IT�6V�W�L�,8�N�q�A�a�D�I�<M�a��d�N�q�Q�N�(4�F�1��!���
�!�A�$�F�q�I�J�*6��
�)S��X�&�(���,���$���%�������O��Fs�
C/�C/�$
C4�2C4c�����fd�}g}|D]\\}}tjd|�r.tjd||�}tjd|�r�.|j||f��^|S)z@returns macro expanded productions, order of productions is keptc�6��d�|j�dzS)N�(?:%s)�macro)�	groupdict)�mr"s �r(�macro_valuez-Tokenizer._expand_macros.<locals>.macro_valueHs����f�Q�[�[�]�7�%;�<�<�<�z{[a-zA-Z][a-zA-Z0-9-]*}z"{(?P<macro>[a-zA-Z][a-zA-Z0-9-]*)})�re�search�sub�append)r!r"r#r0�expanded�key�values `     r(rzTokenizer._expand_macrosFso���	=���%�	*�J�C���)�)�6��>����D�*�E�3���)�)�6��>�
�O�O�S�%�L�)�		*�
�r1c��g}|D]G\}}|j|tjd|ztj�jf��I|S)z>compile productions into callable match objects, order is keptr,)r5r2�compile�U�match)r!�expanded_productions�compiledr7r8s     r(rzTokenizer._compile_productionsRsL����.�	M�J�C���O�O�S�"�*�*�X��-=�r�t�t�"D�"J�"J�K�L�	M��r1c�N�tj||j�|_y)z:Push back tokens which have been pulled but not processed.N)�	itertools�chainr )r!�tokenss  r(�pushzTokenizer.pushYs�� ���v�t�|�|�<��r1c��g|_y�N)r )r!s r(�clearzTokenizer.clear]s	����r1c	#���K�d����fd�}dx}}d}�jd�jddc\}}}	|||�}
|
r'|
jd�}||||f��|t|�z
}t||d�r4d}tj
|||f��|t|�z
}|t|�z
}t|�}|}
||k�r:�jD]}|���||}|dvrd|||f��|dz
}|dz
}�n�|	D�]�\}}|rF|dk(rAt||d	�r4d
||dz}�j|�}
|
r�jr
d|||f��|}�n�|||�}
|
s�[|
jd�}|dk(rH|j�d
k7r5|
jd�t|�kr||
jd�dk(r��|rfd|k(rt|||�rd|�|d��}}nHd|k(rCd||�k(r8dD]3}||d�|��}�j|�}
|
s� d|
jd�}}n|dvr)�j�|�}|dvr0�jd|�}nd|k(r	�j||�}|}�js�js
|dk7r||||f��|t|�z
}|j#�j$�}||z
}|r(t||j'�j$�d�}n|t|�z
}n||
usJ�||kr��:|r	dd||f��yy#t $r9d|k(r/t||t|�zd�rtj
}|dz
}nd}Y��wxYw�w)a;Generator: Tokenize text and yield tokens, each token is a tuple
        of::

            (name, value, line, col)

        The token value will contain a normal string, meaning CSS unicode
        escapes have been resolved to normal characters. The serializer
        escapes needed characters back to unicode escapes depending on
        the stylesheet target encoding.

        text
            to be tokenized
        fullsheet
            if ``True`` appends EOF token as last one and completes incomplete
            COMMENT or INVALID (to STRING) tokens
        c��t|jd�ddd�}|tjkrt	|�S|jd�S)zused by unicodesubrr
N�)�int�group�sys�
maxunicode�unichr)r/�nums  r(�_replz!Tokenizer.tokenize.<locals>._replqs@���a�g�g�a�j���n�b�)�C��c�n�n�$��c�{�"��w�w�q�z�!r1c�:��t�j�|��S)znormalize and do unicodesub)r
�
unicodesub)r8rPr!s ��r(�
_normalizez&Tokenizer.tokenize.<locals>._normalizeys����T�_�_�U�E�:�;�;r1r
rNz	@charset z,:;{}>[]�CHARz/*z%s*/r�IDENT�and�(�INVALID�STRING�FUNCTIONzurl()z')z")�)r)	�	DIMENSIONrUrYr�HASHrrZrXz
UNICODE-RANGE)rYrX��	ATKEYWORDz@charset� �EOF)rrK�len�has_atr�CHARSET_SYMr rr�lower�end�	suffix_eqrrR�cleanstring�_atkeywords�KeyError�count�_linesep�rfind)r!�text�	fullsheetrS�line�col�pos�BOM�matcherr#r<�found�	_len_text�
_orig_text�pushed�c�name�possiblecommentrf�possibleurir8�nlsrPs`                     @r(�tokenizezTokenizer.tokenize`s������"	"�	<����s���'+�&7�&7��&:�D�<M�<M�a�b�<Q�#���g����c�"����K�K��N�E���t�S�)�)��3�u�:��C��$��[�)��E�!�-�-�u�d�C�@�@��3�u�:��C��3�u�:��C���I�	��
��I�o��,�,�
����
��S�	�A��J���q�$��,�,��q����q���&1�V�M�D�'�"�d�f�n�"�4��d�3�*0�4���:�*=�� $� 3� 3�O� D�� �T�%5�%5�#,�o�t�S�"I�I�"+�C�!�#�D�#�.�E�� %���A���!�G�O� %���
�� 6� %�	�	�!��s�4�y� 8� $�U�Y�Y�q�\� 2�c� 9�$�$� )�T� 1�$-�d�C��$?�.6�%��q��8R�e��!+�t�!3�!'�:�e�+<�!<�,=�!.�C�<@���J��2L�K�,0�O�O�K�,H�E�',�6;�U�[�[��^�e��(-�!.� �$5�5�
%)�O�O�E�5�$A�E�#�'<�<�(,�(8�(8��U�(C�� +�d�2�!;�+/�+;�+;�J�u�<M�+N�D�%*�E��+�+�D�4D�4D�04�	�0A�#'���c�":�:��s�5�z�)��#�k�k�$�-�-�8�������"%�e�E�K�K��
�
�,F�,G�&H�"I�C��3�u�:�-�C��mV�p�:�%�%�%�M�I�o�P��"�d�C�(�(���9(0�!;�(2�e�(;�,2�4��s�5�z�9I�3�,O�/=�/I�/I��(-����/:���!;�s?�EM�B/M�;AM�L�BM�6M�?M�M�M�M)NNT)F)�__name__�
__module__�__qualname__�__doc__r�
FONT_FACE_SYM�
IMPORT_SYM�	MEDIA_SYM�
NAMESPACE_SYM�PAGE_SYM�
VARIABLES_SYMrirlr2r:r4rRrhr)rrrCrFr~�r1r(rrs����
%�2�2�!�,�,� �*�*�$�2�2��(�(�$�2�2�
�K��H�����I�J�N�N�J��"�*�*�3�4�8�8�K��<
��=��])r1c�*�|||t|�z|k(S)a�Check if text has substring string as position pos.

    This is effectively equal to ``text[pos:pos+len(string)] == string``.

    If ``pos`` is 0, this is equal to ``text.startswith(string)``.

    :param str text: The text to check against.
    :param int pos: The starting position where the substring should be
                    searched.
    :param str string: The string to search.
    )rb)rnrr�strings   r(rcrcs����C��F��O�$��.�.r1c������s��k(St���z
t��k(xr(t���fd�tt���D��S)ayCheck if the suffix of text starting at pos equals expected.

    This is effectively equivalent to ``text[pos:] == expected``, but avoids
    allocating a huge substring.

    If ``pos`` is 0, this is equal to ``text == expected``.

    :param str text: Text to compare.
    :param int pos: Starting position for the suffix.
    :param str expected: String to compare to.
    c3�:�K�|]}�|�z�|k(���y�wrEr�)�.0�i�expectedrrrns  ���r(�	<genexpr>zsuffix_eq.<locals>.<genexpr>s"�����K���Q��W�
��!��,�K�s�)rb�all�range)rnrrr�s```r(rgrgsJ�����x�����I��O�s�8�}�,�
L��K�e�C��M�6J�K�K�Mr1)r��
__future__rrrr�__all__�
__docformat__�__version__�cssproductionsrrr�helperr
r@r2rL�version_info�chrrNr�objectrrcrgr�r1r(�<module>r�so���R�R��(�
)��"�
���?�?���	�
����A��!��
�F���f)��f)�R/�Mr1

Youez - 2016 - github.com/yon3zu
LinuXploit