internet.md
1> **Источник:** https://python-all.ru/3.11/library/internet.html2>3> «Документация Python на русском» – неофициальный перевод официальной документации Python: версии от 2.6 до 3.16, полнотекстовый поиск, английский оригинал рядом с переводом. Эта Markdown-версия страницы предназначена для работы с LLM: вставьте её в ChatGPT, Claude или Cursor.45---67# Интернет-протоколы и поддержка89Модули, описанные в этой главе, реализуют интернет-протоколы и поддержку сопутствующих технологий. Все они реализованы на Python. Большинству из этих модулей требуется системно-зависимый модуль [`socket`](https://python-all.ru/3.11/library/socket.html#module-socket), который в настоящее время поддерживается на большинстве популярных платформ. Вот краткий обзор:1011- [`webbrowser` – Удобный контроллер веб-браузера](https://python-all.ru/3.11/library/webbrowser.html)1213 - [Объекты управления браузером](https://python-all.ru/3.11/library/webbrowser.html#browser-controller-objects)14- [`wsgiref` – Утилиты WSGI и эталонная реализация](https://python-all.ru/3.11/library/wsgiref.html)1516 - [`wsgiref.util` – Утилиты окружения WSGI](https://python-all.ru/3.11/library/wsgiref.html#module-wsgiref.util)17 - [`wsgiref.headers` – Инструменты для заголовков ответов WSGI](https://python-all.ru/3.11/library/wsgiref.html#module-wsgiref.headers)18 - [`wsgiref.simple_server` – Простой HTTP-сервер WSGI](https://python-all.ru/3.11/library/wsgiref.html#module-wsgiref.simple_server)19 - [`wsgiref.validate` – Проверка соответствия WSGI](https://python-all.ru/3.11/library/wsgiref.html#module-wsgiref.validate)20 - [`wsgiref.handlers` – Базовые классы сервера/шлюза](https://python-all.ru/3.11/library/wsgiref.html#module-wsgiref.handlers)21 - [`wsgiref.types` – Типы WSGI для статической проверки типов](https://python-all.ru/3.11/library/wsgiref.html#module-wsgiref.types)22 - [Примеры](https://python-all.ru/3.11/library/wsgiref.html#examples)23- [`urllib` – Модули обработки URL](https://python-all.ru/3.11/library/urllib.html)24- [`urllib.request` – Расширяемая библиотека для открытия URL](https://python-all.ru/3.11/library/urllib.request.html)2526 - [Объекты Request](https://python-all.ru/3.11/library/urllib.request.html#request-objects)27 - [Объекты OpenerDirector](https://python-all.ru/3.11/library/urllib.request.html#openerdirector-objects)28 - [Объекты BaseHandler](https://python-all.ru/3.11/library/urllib.request.html#basehandler-objects)29 - [Объекты HTTPRedirectHandler](https://python-all.ru/3.11/library/urllib.request.html#httpredirecthandler-objects)30 - [Объекты HTTPCookieProcessor](https://python-all.ru/3.11/library/urllib.request.html#httpcookieprocessor-objects)31 - [Объекты ProxyHandler](https://python-all.ru/3.11/library/urllib.request.html#proxyhandler-objects)32 - [Объекты HTTPPasswordMgr](https://python-all.ru/3.11/library/urllib.request.html#httppasswordmgr-objects)33 - [Объекты HTTPPasswordMgrWithPriorAuth](https://python-all.ru/3.11/library/urllib.request.html#httppasswordmgrwithpriorauth-objects)34 - [Объекты AbstractBasicAuthHandler](https://python-all.ru/3.11/library/urllib.request.html#abstractbasicauthhandler-objects)35 - [Объекты HTTPBasicAuthHandler](https://python-all.ru/3.11/library/urllib.request.html#httpbasicauthhandler-objects)36 - [Объекты ProxyBasicAuthHandler](https://python-all.ru/3.11/library/urllib.request.html#proxybasicauthhandler-objects)37 - [Объекты AbstractDigestAuthHandler](https://python-all.ru/3.11/library/urllib.request.html#abstractdigestauthhandler-objects)38 - [Объекты HTTPDigestAuthHandler](https://python-all.ru/3.11/library/urllib.request.html#httpdigestauthhandler-objects)39 - [Объекты ProxyDigestAuthHandler](https://python-all.ru/3.11/library/urllib.request.html#proxydigestauthhandler-objects)40 - [Объекты HTTPHandler](https://python-all.ru/3.11/library/urllib.request.html#httphandler-objects)41 - [Объекты HTTPSHandler](https://python-all.ru/3.11/library/urllib.request.html#httpshandler-objects)42 - [Объекты FileHandler](https://python-all.ru/3.11/library/urllib.request.html#filehandler-objects)43 - [Объекты DataHandler](https://python-all.ru/3.11/library/urllib.request.html#datahandler-objects)44 - [Объекты FTPHandler](https://python-all.ru/3.11/library/urllib.request.html#ftphandler-objects)45 - [Объекты CacheFTPHandler](https://python-all.ru/3.11/library/urllib.request.html#cacheftphandler-objects)46 - [Объекты UnknownHandler](https://python-all.ru/3.11/library/urllib.request.html#unknownhandler-objects)47 - [Объекты HTTPErrorProcessor](https://python-all.ru/3.11/library/urllib.request.html#httperrorprocessor-objects)48 - [Примеры](https://python-all.ru/3.11/library/urllib.request.html#examples)49 - [Устаревший интерфейс](https://python-all.ru/3.11/library/urllib.request.html#legacy-interface)50 - [`urllib.request` Ограничения](https://python-all.ru/3.11/library/urllib.request.html#urllib-request-restrictions)51- [`urllib.response` – Классы ответов, используемые urllib](https://python-all.ru/3.11/library/urllib.request.html#module-urllib.response)52- [`urllib.parse` – Разбор URL на компоненты](https://python-all.ru/3.11/library/urllib.parse.html)5354 - [Разбор URL](https://python-all.ru/3.11/library/urllib.parse.html#url-parsing)55 - [Безопасность разбора URL](https://python-all.ru/3.11/library/urllib.parse.html#url-parsing-security)56 - [Разбор ASCII-закодированных байтов](https://python-all.ru/3.11/library/urllib.parse.html#parsing-ascii-encoded-bytes)57 - [Структурированные результаты разбора](https://python-all.ru/3.11/library/urllib.parse.html#structured-parse-results)58 - [Экранирование URL](https://python-all.ru/3.11/library/urllib.parse.html#url-quoting)59- [`urllib.error` – Классы исключений, вызываемые urllib.request](https://python-all.ru/3.11/library/urllib.error.html)60- [`urllib.robotparser` – Парсер для robots.txt](https://python-all.ru/3.11/library/urllib.robotparser.html)61- [`http` – Модули HTTP](https://python-all.ru/3.11/library/http.html)6263 - [Коды состояния HTTP](https://python-all.ru/3.11/library/http.html#http-status-codes)64 - [Методы HTTP](https://python-all.ru/3.11/library/http.html#http-methods)65- [`http.client` – Клиент протокола HTTP](https://python-all.ru/3.11/library/http.client.html)6667 - [Объекты HTTPConnection](https://python-all.ru/3.11/library/http.client.html#httpconnection-objects)68 - [Объекты HTTPResponse](https://python-all.ru/3.11/library/http.client.html#httpresponse-objects)69 - [Примеры](https://python-all.ru/3.11/library/http.client.html#examples)70 - [Объекты HTTPMessage](https://python-all.ru/3.11/library/http.client.html#httpmessage-objects)71- [`ftplib` – клиент протокола FTP](https://python-all.ru/3.11/library/ftplib.html)7273 - [Справочник](https://python-all.ru/3.11/library/ftplib.html#reference)7475 - [Объекты FTP](https://python-all.ru/3.11/library/ftplib.html#ftp-objects)76 - [Объекты FTP\_TLS](https://python-all.ru/3.11/library/ftplib.html#ftp-tls-objects)77 - [Переменные модуля](https://python-all.ru/3.11/library/ftplib.html#module-variables)78- [`poplib` – клиент протокола POP3](https://python-all.ru/3.11/library/poplib.html)7980 - [Объекты POP3](https://python-all.ru/3.11/library/poplib.html#pop3-objects)81 - [Пример POP3](https://python-all.ru/3.11/library/poplib.html#pop3-example)82- [`imaplib` – клиент протокола IMAP4](https://python-all.ru/3.11/library/imaplib.html)8384 - [Объекты IMAP4](https://python-all.ru/3.11/library/imaplib.html#imap4-objects)85 - [Пример IMAP4](https://python-all.ru/3.11/library/imaplib.html#imap4-example)86- [`smtplib` – клиент протокола SMTP](https://python-all.ru/3.11/library/smtplib.html)8788 - [Объекты SMTP](https://python-all.ru/3.11/library/smtplib.html#smtp-objects)89 - [Пример SMTP](https://python-all.ru/3.11/library/smtplib.html#smtp-example)90- [`uuid` – объекты UUID в соответствии с **RFC 4122**](https://python-all.ru/3.11/library/uuid.html)9192 - [Пример](https://python-all.ru/3.11/library/uuid.html#example)93- [`socketserver` – фреймворк для сетевых серверов](https://python-all.ru/3.11/library/socketserver.html)9495 - [Замечания по созданию сервера](https://python-all.ru/3.11/library/socketserver.html#server-creation-notes)96 - [Объекты сервера](https://python-all.ru/3.11/library/socketserver.html#server-objects)97 - [Объекты обработчиков запросов](https://python-all.ru/3.11/library/socketserver.html#request-handler-objects)98 - [Примеры](https://python-all.ru/3.11/library/socketserver.html#examples)99100 - [`socketserver.TCPServer` Пример](https://python-all.ru/3.11/library/socketserver.html#socketserver-tcpserver-example)101 - [`socketserver.UDPServer` Пример](https://python-all.ru/3.11/library/socketserver.html#socketserver-udpserver-example)102 - [Асинхронные примеси](https://python-all.ru/3.11/library/socketserver.html#asynchronous-mixins)103- [`http.server` – HTTP-серверы](https://python-all.ru/3.11/library/http.server.html)104105 - [Вопросы безопасности](https://python-all.ru/3.11/library/http.server.html#security-considerations)106- [`http.cookies` – управление состоянием HTTP](https://python-all.ru/3.11/library/http.cookies.html)107108 - [Объекты Cookie](https://python-all.ru/3.11/library/http.cookies.html#cookie-objects)109 - [Объекты Morsel](https://python-all.ru/3.11/library/http.cookies.html#morsel-objects)110 - [Пример](https://python-all.ru/3.11/library/http.cookies.html#example)111- [`http.cookiejar` – Обработка cookie для HTTP-клиентов](https://python-all.ru/3.11/library/http.cookiejar.html)112113 - [Объекты CookieJar и FileCookieJar](https://python-all.ru/3.11/library/http.cookiejar.html#cookiejar-and-filecookiejar-objects)114 - [Подклассы FileCookieJar и взаимодействие с веб-браузерами](https://python-all.ru/3.11/library/http.cookiejar.html#filecookiejar-subclasses-and-co-operation-with-web-browsers)115 - [Объекты CookiePolicy](https://python-all.ru/3.11/library/http.cookiejar.html#cookiepolicy-objects)116 - [Объекты DefaultCookiePolicy](https://python-all.ru/3.11/library/http.cookiejar.html#defaultcookiepolicy-objects)117 - [Объекты Cookie](https://python-all.ru/3.11/library/http.cookiejar.html#cookie-objects)118 - [Примеры](https://python-all.ru/3.11/library/http.cookiejar.html#examples)119- [`xmlrpc` – Модули сервера и клиента XML-RPC](https://python-all.ru/3.11/library/xmlrpc.html)120- [`xmlrpc.client` – Доступ клиента XML-RPC](https://python-all.ru/3.11/library/xmlrpc.client.html)121122 - [Объекты ServerProxy](https://python-all.ru/3.11/library/xmlrpc.client.html#serverproxy-objects)123 - [Объекты datetime](https://python-all.ru/3.11/library/xmlrpc.client.html#datetime-objects)124 - [Объекты Binary](https://python-all.ru/3.11/library/xmlrpc.client.html#binary-objects)125 - [Объекты Fault](https://python-all.ru/3.11/library/xmlrpc.client.html#fault-objects)126 - [Объекты ProtocolError](https://python-all.ru/3.11/library/xmlrpc.client.html#protocolerror-objects)127 - [Объекты MultiCall](https://python-all.ru/3.11/library/xmlrpc.client.html#multicall-objects)128 - [Удобные функции](https://python-all.ru/3.11/library/xmlrpc.client.html#convenience-functions)129 - [Пример использования клиента](https://python-all.ru/3.11/library/xmlrpc.client.html#example-of-client-usage)130 - [Пример использования клиента и сервера](https://python-all.ru/3.11/library/xmlrpc.client.html#example-of-client-and-server-usage)131- [`xmlrpc.server` – Базовые серверы XML-RPC](https://python-all.ru/3.11/library/xmlrpc.server.html)132133 - [Объекты SimpleXMLRPCServer](https://python-all.ru/3.11/library/xmlrpc.server.html#simplexmlrpcserver-objects)134135 - [Пример SimpleXMLRPCServer](https://python-all.ru/3.11/library/xmlrpc.server.html#simplexmlrpcserver-example)136 - [CGIXMLRPCRequestHandler](https://python-all.ru/3.11/library/xmlrpc.server.html#cgixmlrpcrequesthandler)137 - [Документирование сервера XML-RPC](https://python-all.ru/3.11/library/xmlrpc.server.html#documenting-xmlrpc-server)138 - [Объекты DocXMLRPCServer](https://python-all.ru/3.11/library/xmlrpc.server.html#docxmlrpcserver-objects)139 - [DocCGIXMLRPCRequestHandler](https://python-all.ru/3.11/library/xmlrpc.server.html#doccgixmlrpcrequesthandler)140- [`ipaddress` – Библиотека для работы с IPv4/IPv6](https://python-all.ru/3.11/library/ipaddress.html)141142 - [Удобные фабричные функции](https://python-all.ru/3.11/library/ipaddress.html#convenience-factory-functions)143 - [IP-адреса](https://python-all.ru/3.11/library/ipaddress.html#ip-addresses)144145 - [Объекты адресов](https://python-all.ru/3.11/library/ipaddress.html#address-objects)146 - [Преобразование в строки и целые числа](https://python-all.ru/3.11/library/ipaddress.html#conversion-to-strings-and-integers)147 - [Операторы](https://python-all.ru/3.11/library/ipaddress.html#operators)148149 - [Операторы сравнения](https://python-all.ru/3.11/library/ipaddress.html#comparison-operators)150 - [Арифметические операторы](https://python-all.ru/3.11/library/ipaddress.html#arithmetic-operators)151 - [Определения IP-сетей](https://python-all.ru/3.11/library/ipaddress.html#ip-network-definitions)152153 - [Префикс, маска сети и маска узла](https://python-all.ru/3.11/library/ipaddress.html#prefix-net-mask-and-host-mask)154 - [Объекты сетей](https://python-all.ru/3.11/library/ipaddress.html#network-objects)155 - [Операторы](https://python-all.ru/3.11/library/ipaddress.html#id1)156157 - [Логические операторы](https://python-all.ru/3.11/library/ipaddress.html#logical-operators)158 - [Итерация](https://python-all.ru/3.11/library/ipaddress.html#iteration)159 - [Сети как контейнеры адресов](https://python-all.ru/3.11/library/ipaddress.html#networks-as-containers-of-addresses)160 - [Объекты интерфейсов](https://python-all.ru/3.11/library/ipaddress.html#interface-objects)161162 - [Операторы](https://python-all.ru/3.11/library/ipaddress.html#id2)163164 - [Логические операторы](https://python-all.ru/3.11/library/ipaddress.html#id3)165 - [Прочие функции уровня модуля](https://python-all.ru/3.11/library/ipaddress.html#other-module-level-functions)166 - [Пользовательские исключения](https://python-all.ru/3.11/library/ipaddress.html#custom-exceptions)167