OwlCyberSecurity - MANAGER
Edit File: collector.cpython-39.pyc
a )��ex@ � @ s� d Z ddlZddlZddlZddlZddlZddlZddlZddl Z ddlZ ddlm Z ddlmZ ddlmZmZmZmZmZmZmZmZmZmZmZ ddlmZ ddlmZ ddl m!Z!m"Z" dd l#m$Z$ dd l%m&Z& ddl'm(Z( ddl)m*Z* dd l+m,Z, ddl-m.Z. ddl/m0Z0 ddl1m2Z2 ddl3m4Z4m5Z5m6Z6 e�rHddlm7Z7 ne8Z7e�9e:�Z;ee<e<f Z=e<ee< d�dd�Z>G dd� de?�Z@edd�dd�ZAG dd� de?�ZBe<e*dd�dd �ZCe<e*ed�d!d"�ZDe=ee< d#�d$d%�ZEG d&d'� d'�ZFG d(d)� d)e7�ZGeGeGd*�d+d,�ZHeHd-ee& d.�d/d0��ZIG d1d-� d-�ZJG d2d3� d3e �ZKdCe&ee<e?f eed4 dd5�d6d7�ZLdDeeMeJd9�d:d;�ZNe&e*ed- d<�d=d>�ZOG d?d@� d@e�ZPG dAdB� dB�ZQdS )EzO The main purpose of this module is to expose LinkCollector.collect_sources(). � N)� HTMLParser)�Values)� TYPE_CHECKING�Callable�Dict�Iterable�List�MutableMapping� NamedTuple�Optional�Sequence�Tuple�Union)�requests)�Response)� RetryError�SSLError)�NetworkConnectionError)�Link)�SearchScope)� PipSession)�raise_for_status)�is_archive_file��redact_auth_from_url)�vcs� )�CandidatesFromPage� LinkSource�build_source)�Protocol��url�returnc C s6 t jD ]*}| �� �|�r| t|� dv r| S qdS )zgLook for VCS schemes in the URL. Returns the matched VCS scheme, or None if there's no match. z+:N)r Zschemes�lower� startswith�len)r"