Skip to content

Inaccurate parsing of 802.11 element "RSN Information" #2683

@giladbeeri

Description

@giladbeeri

I'm parsing an 802.11 frame that contains some tag elements, specifically, "RSN Information" (48).

"RSN Information" is parsed with a conditional field of PMKID, but I think the condition is not accurate, and in addition, there's another field afterwards called "Group Management Cipher Suite" (4 bytes).
https://github.com/secdev/scapy/blob/master/scapy/layers/dot11.py#L880

Steps to Reproduce

python -c "from scapy.all import rdpcap; f = rdpcap('scapy.pcap'); p = f[0]; beacon = p.getlayer(5); print(beacon.network_stats()['ssid'])"

Actual result

(some garbage which is data from the packet)

���\xdd�P\xf2���\x81�\xa4'\xa4BT^a2/��\xdd\xa0\xc6���

Expected result

The real SSID: ROUTE-821E295

correct_ssid

Related resources

The frame that reproduces the issue:

scapy.pcap.zip

Wireshark's parsing of the RSN Information element:

correct_rsn_info

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions