Ejemplo n.º 1
0
 def __init__(self):
     """
 Class constructor.
 """
     # Establish a connection to the kernel via the NETLINK socket
     self.connection = netlink.Connection(netlink.NETLINK_GENERIC)
     controller = genetlink.Controller(self.connection)
     try:
         self.family_id = controller.get_family_id(L2TP_GENL_NAME)
     except OSError:
         raise L2TPSupportUnavailable
Ejemplo n.º 2
0
 def __init__(self):
     self._conn = netlink.Connection(netlink.NETLINK_GENERIC)
     self._fid = netlink.genl_controller.get_family_id(b'MAC80211_HWSIM')
Ejemplo n.º 3
0
 def __init__(self):
     self._conn = netlink.Connection(netlink.NETLINK_GENERIC)
     self._fid = netlink.genl_controller.get_family_id(b'NRC-NL-FAM')