403Webshell
Server IP : 118.27.122.248  /  Your IP : 216.73.216.124
Web Server : Apache
System : Linux web0264.sh.tyo1 4.18.0-553.79.1.lve.el7h.x86_64 #1 SMP Wed Oct 15 16:34:46 UTC 2025 x86_64
User : c9415830 ( 11735)
PHP Version : 8.4.17
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /opt/alt/python36/lib64/python3.6/Tools/scripts/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /opt/alt/python36/lib64/python3.6/Tools/scripts/__pycache__/parse_html5_entities.cpython-36.pyc
3

x2_��@svdZddlZddlZddlZddlmZddlmZdZdd�Z	dd	�Z
d
d�Zejfdd
�Z
edk�rre
e	e��Zdejkr�ed�edje��e
e�n�dejk�rFdZedZee��jZeed��TZdZxHeD]@Zejd�r�e
eed�dZq�e�rejd�r�dZq�eje�q�WWdQRXWdQRXeje�ejee�n,eek�rZed�neee�edje��dS)z�
Utility for parsing HTML5 entity definitions available from:

    http://dev.w3.org/html5/spec/entities.json

Written by Ezio Melotti and Iuliia Proskurnia.

�N)�urlopen)�html5z*http://dev.w3.org/html5/spec/entities.jsonc	Cs,t|��}|j�jd�}WdQRXtj|�S)zADownload the json file from the url and returns a decoded object.zutf-8N)r�read�decode�json�loads)Zurl�f�data�r
�G/opt/alt/python36/lib64/python3.6/Tools/scripts/parse_html5_entities.py�get_jsons
rcCs0i}x&|j�D]\}}|d||jd�<qW|S)z3Create the html5 dict from the decoded json object.Z
characters�&)�items�lstrip)�entities�	new_html5�name�valuer
r
r�create_dictsrcCs|j�|j�}|rLtdjt|���x$t|�D]}tdj|||��q0W|j�|j�}|r�tdjt|���x$t|�D]}tdj|||��q|Wt�}x@|j�|j�@D],}||||kr�|j|||||f�q�W|�rtdjt|���x t|�D]}tdj|���qWdS)z8Compare the old and new dicts and print the differences.z{} entitie(s) have been added:z  {!r}: {!r}z {} entitie(s) have been removed:z!{} entitie(s) have been modified:z  {!r}: {!r} -> {!r}N)�keys�print�format�len�sorted�set�add)�old�newZaddedrZremovedZchanged�itemr
r
r�
compare_dicts s$rcCs\t|j��}t|tjd�}td|d�x$|D]}tdj|||�|d�q,Wtd|d�dS)z8Write the items of the dictionary in the specified file.)�keyz	html5 = {)�filez    {!r}: {!a},�}N)rr�str�lowerrr)rr!rrr
r
r�write_items5s

r%�__main__z--createzQ# map the HTML5 named character references to the equivalent Unicode character(s)z)# Generated by {}.  Do not edit manually.z--patchzLib/html/entities.pyz.temp�wFz	html5 = {)r!Tr"z"The current dictionary is updated.zwRun "./python {0} --patch" to update Lib/html/entities.html or "./python {0} --create" to see the generated dictionary.)�__doc__�os�sysrZurllib.requestrZ
html.entitiesrZentities_urlrrr�stdoutr%�__name__r�argvrr�__file__ZfnameZ
temp_fname�open�f1�f2�skip�line�
startswith�write�remove�renamer
r
r
r�<module>	sL





"





Youez - 2016 - github.com/yon3zu
LinuXploit