Searched refs:struct (Results 1 - 25 of 112) sorted by relevance

12345

/trex/scripts/automation/trex_control_plane/server/
H A Dzipmsg.py2 import struct namespace
15 new_msg = struct.pack(">II", self.MSG_COMPRESS_HEADER_MAGIC, len(msg)) + compressed
23 t = struct.unpack(">II", msg[:8])
/trex/scripts/automation/trex_control_plane/stl/trex_stl_lib/utils/
H A Dzipmsg.py2 import struct namespace
15 new_msg = struct.pack(">II", self.MSG_COMPRESS_HEADER_MAGIC, len(msg)) + compressed
23 t = struct.unpack(">II", msg[:8])
38 t = struct.unpack(">II", msg[:8])
/trex/scripts/external_libs/scapy-2.3.1/python2/scapy/layers/
H A Dradius.py10 import struct namespace
61 p = p[:2]+struct.pack("!H",l)+p[4:]
H A Dl2tp.py12 import struct namespace
31 pkt = pkt[:2]+struct.pack("!H", l)+pkt[4:]
/trex/scripts/external_libs/scapy-2.3.1/python3/scapy/layers/
H A Dradius.py10 import struct namespace
61 p = p[:2]+struct.pack("!H",l)+p[4:]
H A Dl2tp.py12 import struct namespace
31 pkt = pkt[:2]+struct.pack("!H", l)+pkt[4:]
/trex/scripts/external_libs/pyzmq-14.5.0/python2/ucs2/32bit/zmq/utils/
H A Dmonitor.py7 import struct namespace
36 event['event'], event['value'] = struct.unpack("=hi", msg[0])
H A Dz85.py14 import struct namespace
32 values = struct.unpack('>%dI' % nvalues, rawbytes)
56 return struct.pack('>%dI' % nvalues, *values)
/trex/scripts/external_libs/pyzmq-14.5.0/python2/ucs2/64bit/zmq/utils/
H A Dmonitor.py7 import struct namespace
36 event['event'], event['value'] = struct.unpack("=hi", msg[0])
H A Dz85.py14 import struct namespace
32 values = struct.unpack('>%dI' % nvalues, rawbytes)
56 return struct.pack('>%dI' % nvalues, *values)
/trex/scripts/external_libs/pyzmq-14.5.0/python2/ucs4/64bit/zmq/utils/
H A Dmonitor.py7 import struct namespace
36 event['event'], event['value'] = struct.unpack("=hi", msg[0])
H A Dz85.py14 import struct namespace
32 values = struct.unpack('>%dI' % nvalues, rawbytes)
56 return struct.pack('>%dI' % nvalues, *values)
/trex/scripts/external_libs/pyzmq-14.5.0/python3/ucs4/32bit/zmq/utils/
H A Dmonitor.py7 import struct namespace
36 event['event'], event['value'] = struct.unpack("=hi", msg[0])
H A Dz85.py14 import struct namespace
32 values = struct.unpack('>%dI' % nvalues, rawbytes)
56 return struct.pack('>%dI' % nvalues, *values)
/trex/scripts/external_libs/pyzmq-14.5.0/python3/ucs4/64bit/zmq/utils/
H A Dmonitor.py7 import struct namespace
36 event['event'], event['value'] = struct.unpack("=hi", msg[0])
H A Dz85.py14 import struct namespace
32 values = struct.unpack('>%dI' % nvalues, rawbytes)
56 return struct.pack('>%dI' % nvalues, *values)
/trex/scripts/external_libs/scapy-2.3.1/python2/scapy/contrib/
H A Dldp.py21 import struct namespace
46 type = struct.unpack("!H",p[0:2])[0]
48 if type == 0x0001 and struct.unpack("!H",p[2:4])[0] > 20:
62 nbr = struct.unpack("!H",x[2:4])[0]
90 fec += struct.pack("!B",o[1])
94 s += struct.pack("!H",l)
99 l = 4 + struct.unpack("!H",s[2:4])[0]
110 return struct.unpack("!I",x[4:8])[0]
115 s += struct.pack("!I",x)
119 l = 4 + struct
[all...]
H A Dcarp.py9 import struct, hmac, hashlib namespace
32 pkt = pkt[:6] + struct.pack("!H", checksum(pkt)) + pkt[8:]
45 h.update(struct.pack('!B', p.vhid))
H A Dbgp.py36 return struct.pack(">B",mask) + ip[:self.mask2iplen(mask)]
40 l = self.mask2iplen( struct.unpack(">B",s[0])[0] ) + 1
43 mask = struct.unpack(">B",m[0])[0]
58 p = p[:16]+struct.pack("!H", l)+p[18:]
72 p = p[:1]+struct.pack("!B", l)+p[2:]
92 p = p[:9] + struct.pack("!B",l) +p[10:]
115 p = p[:2] + struct.pack("!B",l) +p[3:]
137 p = p[:0]+struct.pack("!H", wl)+p[2:]
140 p = p[:2+wl]+struct.pack("!H", l)+p[4+wl:]
/trex/scripts/external_libs/scapy-2.3.1/python3/scapy/contrib/
H A Dldp.py21 import struct namespace
46 type = struct.unpack("!H",p[0:2])[0]
48 if type == 0x0001 and struct.unpack("!H",p[2:4])[0] > 20:
62 nbr = struct.unpack("!H",x[2:4])[0]
90 fec += struct.pack("!B",o[1])
94 s += struct.pack("!H",l)
99 l = 4 + struct.unpack("!H",s[2:4])[0]
110 return struct.unpack("!I",x[4:8])[0]
115 s += struct.pack("!I",x)
119 l = 4 + struct
[all...]
H A Dcarp.py9 import struct, hmac, hashlib namespace
32 pkt = pkt[:6] + struct.pack("!H", checksum(pkt)) + pkt[8:]
45 h.update(struct.pack('!B', p.vhid))
H A Dbgp.py36 return struct.pack(">B",mask) + ip[:self.mask2iplen(mask)]
40 l = self.mask2iplen( struct.unpack(">B",s[0])[0] ) + 1
43 mask = struct.unpack(">B",m[0])[0]
58 p = p[:16]+struct.pack("!H", l)+p[18:]
72 p = p[:1]+struct.pack("!B", l)+p[2:]
92 p = p[:9] + struct.pack("!B",l) +p[10:]
115 p = p[:2] + struct.pack("!B",l) +p[3:]
137 p = p[:0]+struct.pack("!H", wl)+p[2:]
140 p = p[:2+wl]+struct.pack("!H", l)+p[4+wl:]
/trex/scripts/external_libs/scapy-2.3.1/python2/scapy/arch/
H A Dlinux.py11 import sys,os,struct,socket,time namespace
83 return struct.unpack("16xh6s8x",get_if(iff,SIOCGIFHWADDR))
108 ifflags = struct.unpack("16xH14x",get_if(i,SIOCGIFFLAGS))[0]
132 bpf += struct.pack("HBBI",*map(long,l.split()))
137 bpfh = struct.pack("HL", nb, id(bpf)+36)
139 bpfh = struct.pack("HI", nb, id(bpf)+20)
143 mreq = struct.pack("IHH8s", get_if_index(iff), PACKET_MR_PROMISC, 0, "")
160 ifreq = ioctl(s, SIOCGIFADDR,struct.pack("16s16x",LOOPBACK_NAME))
161 addrfamily = struct.unpack("h",ifreq[16:18])[0]
163 ifreq2 = ioctl(s, SIOCGIFNETMASK,struct
[all...]
/trex/scripts/external_libs/scapy-2.3.1/python2/scapy/
H A Dpton_ntop.py13 import socket,struct namespace
74 value = struct.unpack("!H", addr[left:left+2])[0]
/trex/scripts/external_libs/scapy-2.3.1/python3/scapy/arch/
H A Dlinux.py10 import sys,os,struct,socket,time,ctypes namespace
85 return struct.unpack("16xh6s8x",get_if(iff,SIOCGIFHWADDR))[1]
112 ifflags = struct.unpack("16xH14x",get_if(i,SIOCGIFFLAGS))[0]
136 bpf += struct.pack("HBBI",*[int(x) for x in l.split()])
144 # bpfh = struct.pack("HL", nb, id(bpf)+36)
146 # bpfh = struct.pack("HI", nb, id(bpf)+20)
151 mreq = struct.pack("IHH8s", get_if_index(iff), PACKET_MR_PROMISC, 0, b"")
168 ifreq = ioctl(s, SIOCGIFADDR,struct.pack("16s16x",LOOPBACK_NAME.encode('utf-8')))
169 addrfamily = struct.unpack("h",ifreq[16:18])[0]
171 ifreq2 = ioctl(s, SIOCGIFNETMASK,struct
[all...]

Completed in 17 milliseconds

12345