Lines Matching refs:s
117 def SetSocketTos(s, tos): argument
118 level = {AF_INET: SOL_IP, AF_INET6: SOL_IPV6}[s.family]
119 option = {AF_INET: IP_TOS, AF_INET6: IPV6_TCLASS}[s.family]
120 s.setsockopt(level, option, tos)
130 s = socket(family, sock_type, protocol)
131 csocket.SetSocketTimeout(s, 5000)
132 return s
149 s = Socket(family, SOCK_STREAM, IPPROTO_TCP)
150 SetNonBlocking(s.fileno())
151 return s
167 s = Socket(family, SOCK_RAW, IPPROTO_GRE)
168 return s
211 s = UDPSocket(AF_INET)
213 ifr = fcntl.ioctl(s, scapy.SIOCGIFINDEX, ifr)
218 s = UDPSocket(AF_INET)
224 fcntl.ioctl(s, SIOCSIFHWADDR, ifr)
228 s = UDPSocket(AF_INET)
230 ifr = fcntl.ioctl(s, scapy.SIOCGIFFLAGS, ifr)
237 ifr = fcntl.ioctl(s, scapy.SIOCSIFFLAGS, ifr)
277 address = [s for s in address.strip().split(" ") if s]
290 route = [s for s in route.strip().split(" ") if s]
299 route = [s for s in route.strip().split("\t") if s]
338 def SetFlowLabel(s, addr, label): argument
340 s.setsockopt(SOL_IPV6, IPV6_FLOWLABEL_MGR, opt)