| Server IP : 217.160.0.135 / Your IP : 216.73.217.37 Web Server : Apache System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64 User : sws1074145052 ( 1074145052) PHP Version : 8.3.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /lib/python3/dist-packages/openid/yadis/__pycache__/ |
Upload File : |
�
8O�^�
� � � d Z ddlZddlmZ ddlmZ g d�Zd� Zd� Z ej d� � Z
d � Zd
� Zd� Z
d� Zd
� Zd� Zd� ZdS )z�Utility functions for handling XRIs.
@see: XRI Syntax v2.0 at the U{OASIS XRI Technical Committee<http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=xri>}
� N)�reduce)� codecutil)�!�=�@�+�$�(c �V � | � d� � s| r| d t v rdS dS )zWDetermine if this identifier is an XRI or URI.
@returns: C{"XRI"} or C{"URI"}
�xri://r �XRI�URI)�
startswith�XRI_AUTHORITIES)�
identifiers �2/usr/lib/python3/dist-packages/openid/yadis/xri.py�identifierSchemer s: � �
���X�&�&� �:� �+5�a�=�O�+K�+K��u��u� c �T � | � d� � sd| z } t | � � S )z$Transform an XRI to IRI-normal form.r )r �escapeForIRI��xris r �toIRINormalr s- � ��>�>�(�#�#� ���n������r z \((.*?)\)c � � | � � � }|� dd� � }|� dd� � }|� dd� � }|S )zKEscape things that need to be escaped if they're in a cross-reference.
�/z%2F�?z%3F�#z%23)�group�replace)�
xref_match�xrefs r �_escape_xrefr"