from scapy.config import conf

from unpacker.frame import Frame
from unpacker.socket_handler import SocketHandler


class WindowsSocket(SocketHandler):
    def __init__(self, interface):
        self.sock = conf.L2socket(iface=interface)

    def get_raw_frame(self) -> Frame:
        while True:
            raw_data = self.sock.recv()
            if raw_data:
                return raw_data.original

    def send_frame(self, frame: bytes):
        self.sock.send(frame)

a9e3c5024b6879c088fce7d7af3455e0a822a927
<mask token>

<mask token>


class WindowsSocket(SocketHandler):
    <mask token>
    <mask token>

    def send_frame(self, frame: bytes):
        self.sock.send(frame)

<mask token>


class WindowsSocket(SocketHandler):
    <mask token>

    def get_raw_frame(self) ->Frame:
        while True:
            raw_data = self.sock.recv()
            if raw_data:
                return raw_data.original

    def send_frame(self, frame: bytes):
        self.sock.send(frame)

<mask token>


class WindowsSocket(SocketHandler):

    def __init__(self, interface):
        self.sock = conf.L2socket(iface=interface)

    def get_raw_frame(self) ->Frame:
        while True:
            raw_data = self.sock.recv()
            if raw_data:
                return raw_data.original

    def send_frame(self, frame: bytes):
        self.sock.send(frame)

from scapy.config import conf

from unpacker.frame import Frame
from unpacker.socket_handler import SocketHandler


class WindowsSocket(SocketHandler):
    def __init__(self, interface):
        self.sock = conf.L2socket(iface=interface)

    def get_raw_frame(self) -> Frame:
        while True:
            raw_data = self.sock.recv()
            if raw_data:
                return raw_data.original

    def send_frame(self, frame: bytes):
        self.sock.send(frame)
