Lines Matching full:raw
100 def __init__(self, raw, offset): argument
101 self._len, self._type = struct.unpack("HH", raw[offset:offset + 4])
105 self.raw = raw[offset + 4:offset + self.payload_len]
116 def formatted_string(cls, raw, display_hint): argument
118 formatted = ':'.join('%02x' % b for b in raw)
120 formatted = bytes.hex(raw, ' ')
122 formatted = format(ipaddress.ip_address(raw))
124 formatted = str(uuid.UUID(bytes=raw))
126 formatted = raw
131 return format.unpack(self.raw)[0]
134 return self.raw.decode('ascii')[:-1]
137 return self.raw
141 return [ x[0] for x in format.iter_unpack(self.raw) ]
149 decoded = self.raw[offset:offset+m['len']]
153 [ decoded ] = format.unpack_from(self.raw, offset)
161 return f"[type:{self.type} len:{self._len}] {self.raw}"
193 self.raw = msg[offset + 16:offset + self.nl_len]
200 self.error = struct.unpack("i", self.raw[0:4])[0]
210 extack_attrs = NlAttrs(self.raw[extack_off:])
240 …msg = f"nl_len = {self.nl_len} ({len(self.raw)}) nl_flags = 0x{self.nl_flags:x} nl_type = {self.nl…
304 for attr in NlAttrs(gm.raw):
313 for entry in NlAttrs(attr.raw):
316 for entry_attr in NlAttrs(entry.raw):
330 self.genl_cmd, self.genl_version, _ = struct.unpack_from("BBH", nl_msg.raw, 0)
331 self.raw = nl_msg.raw[4:]
367 msg.raw_attrs = NlAttrs(msg.raw[fixed_header_size:])
413 if self.proto == "netlink-raw":
475 def _decode_enum(self, raw, attr_spec): argument
480 while raw:
481 if raw & 1:
483 raw >>= 1
486 value = enum.entries_by_val[raw].name
507 while offset < len(attr.raw):
508 item = NlAttr(attr.raw, offset)
511 subattrs = self._decode(NlAttrs(item.raw), attr_spec['nested-attributes'])
524 subdict = self._decode(NlAttrs(attr.raw), attr_spec['nested-attributes'])
568 subpath = self._decode_extack_path(NlAttrs(attr.raw),
606 [ value ] = format.unpack_from(msg.raw, offset)
616 msg['raw'] = decoded