A MACField that displays the address type depending on the 802.11 flags
| 673 | |
| 674 | |
| 675 | class _Dot11MacField(MACField): |
| 676 | """ |
| 677 | A MACField that displays the address type depending on the |
| 678 | 802.11 flags |
| 679 | """ |
| 680 | __slots__ = ["index"] |
| 681 | |
| 682 | def __init__(self, name, default, index): |
| 683 | self.index = index |
| 684 | super(_Dot11MacField, self).__init__(name, default) |
| 685 | |
| 686 | def i2repr(self, pkt, val): |
| 687 | s = super(_Dot11MacField, self).i2repr(pkt, val) |
| 688 | meaning = pkt.address_meaning(self.index) |
| 689 | if meaning: |
| 690 | return "%s (%s)" % (s, meaning) |
| 691 | return s |
| 692 | |
| 693 | |
| 694 | # 802.11-2020 9.2.4.1.1 |
no outgoing calls
no test coverage detected
searching dependent graphs…