← Back
Editing: services.cpython-311.pyc
� |=�^2 � �F � d dl mZ d dlmZmZ d dlmZmZmZ dd�Z dd�Z dS )� )�mkFilter)�discover�DiscoveryFailure)� parseXRDS�iterServices� XRDSErrorNc �� � t | � � } t |j |j |� � }n/# t $ r"}t t |� � d� � �d}~ww xY w|j |fS )at Perform the Yadis protocol on the input URL and return an iterable of resulting endpoint objects. @param flt: A filter object or something that is convertable to a filter object (using mkFilter) that will be used to generate endpoint objects. This defaults to generating BasicEndpoint objects. @param input_url: The URL on which to perform the Yadis protocol @return: The normalized identity URL and an iterable of endpoint objects generated by the filter function. @rtype: (str, [endpoint]) @raises DiscoveryFailure: when Yadis fails to obtain an XRDS document. N)r �applyFilter�normalized_uri� response_textr r �str)� input_url�flt�result� endpoints�errs �7/usr/lib/python3/dist-packages/openid/yadis/services.py�getServiceEndpointsr sw � �$ �i� � �F�/��� 5�v�7K� #�%� %� � ��� /� /� /��s�3�x�x��.�.�.�����/�����!�9�-�-s �- � A�A�Ac � � t |� � }t |� � }g }t |� � D ]+}|� |� | |� � � � �,|S )aa Generate an iterable of endpoint objects given this input data, presumably from the result of performing the Yadis protocol. @param normalized_uri: The input URL, after following redirects, as in the Yadis protocol. @param xrd_data: The XML text the XRDS file fetched from the normalized URI. @type xrd_data: str )r r r �extendr )r �xrd_datar �etr �service_elements r r r # sv � � �3�-�-�C� �8� � �B��I�'��+�+� F� F������#�#�N�O�D�D� F� F� F� F� �� )N)�openid.yadis.filtersr �openid.yadis.discoverr r �openid.yadis.etxrdr r r r r � r r �<module>r s� �� *� )� )� )� )� )� <� <� <� <� <� <� <� <� A� A� A� A� A� A� A� A� A� A�.� .� .� .�6� � � � � r
Save File
Cancel