mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-22 15:37:45 +00:00
[sans-io] remove old implementations
This commit is contained in:
parent
84287f928c
commit
2736c9c705
@ -1,15 +1,11 @@
|
||||
from . import modes
|
||||
from .glue import GlueLayer
|
||||
from .http.http import HTTPLayer
|
||||
from .tcp import TCPLayer
|
||||
from .tls import ClientTLSLayer, ServerTLSLayer
|
||||
from .websocket import WebsocketLayer
|
||||
|
||||
__all__ = [
|
||||
"modes",
|
||||
"GlueLayer",
|
||||
"HTTPLayer",
|
||||
"TCPLayer",
|
||||
"ClientTLSLayer", "ServerTLSLayer",
|
||||
"WebsocketLayer",
|
||||
]
|
||||
|
@ -12,7 +12,7 @@ from mitmproxy.proxy.protocol.http import HTTPMode
|
||||
from mitmproxy.proxy2 import events, commands, context
|
||||
from mitmproxy.proxy2.context import Context
|
||||
from mitmproxy.proxy2.layer import Layer, NextLayer
|
||||
from mitmproxy.proxy2.layers import websocket
|
||||
from mitmproxy.proxy2.layers.old import websocket
|
||||
from mitmproxy.proxy2.utils import expect
|
||||
|
||||
|
||||
|
@ -20,7 +20,6 @@ from mitmproxy import http, options as moptions
|
||||
from mitmproxy.proxy.protocol.http import HTTPMode
|
||||
from mitmproxy.proxy2 import commands, events, layer, layers
|
||||
from mitmproxy.proxy2.context import Client, Connection, ConnectionState, Context
|
||||
from mitmproxy.proxy2.layers import glue
|
||||
from mitmproxy.utils import human
|
||||
|
||||
|
||||
@ -200,8 +199,6 @@ class ConnectionHandler(metaclass=abc.ABCMeta):
|
||||
elif isinstance(command, commands.GetSocket):
|
||||
socket = self.transports[command.connection].w.get_extra_info("socket")
|
||||
self.server_event(events.GetSocketReply(command, socket))
|
||||
elif isinstance(command, glue.GlueGetConnectionHandler):
|
||||
self.server_event(glue.GlueGetConnectionHandlerReply(command, self))
|
||||
elif isinstance(command, commands.Hook):
|
||||
asyncio.ensure_future(
|
||||
self.handle_hook(command)
|
||||
|
@ -5,7 +5,7 @@ import pytest
|
||||
|
||||
from mitmproxy.net.websockets import Frame, OPCODE
|
||||
from mitmproxy.proxy2 import commands, events
|
||||
from mitmproxy.proxy2.layers import websocket
|
||||
from mitmproxy.proxy2.layers.old import websocket
|
||||
from mitmproxy.test import tflow
|
||||
from .. import tutils
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user