Same as nsummary(), except that packets are also hexdumped lfilter: a truth function that decides whether a packet must be displayed
(self, lfilter=None)
| 413 | hexdump(p.getlayer(conf.raw_layer).load) # type: ignore |
| 414 | |
| 415 | def hexdump(self, lfilter=None): |
| 416 | # type: (Optional[Callable[..., bool]]) -> None |
| 417 | """Same as nsummary(), except that packets are also hexdumped |
| 418 | lfilter: a truth function that decides whether a packet must be displayed""" # noqa: E501 |
| 419 | for i, res in enumerate(self.res): |
| 420 | p = self._elt2pkt(res) |
| 421 | if lfilter is not None and not lfilter(p): |
| 422 | continue |
| 423 | print("%s %s %s" % (conf.color_theme.id(i, fmt="%04i"), |
| 424 | p.sprintf("%.time%"), |
| 425 | self._elt2sum(res))) |
| 426 | hexdump(p) |
| 427 | |
| 428 | def padding(self, lfilter=None): |
| 429 | # type: (Optional[Callable[..., bool]]) -> None |