skip to main content
10.1145/3558482.3581779acmconferencesArticle/Chapter ViewAbstractPublication PageswisecConference Proceedingsconference-collections
research-article

Testing and Improving the Correctness of Wi-Fi Frame Injection

Published:28 June 2023Publication History

ABSTRACT

Investigating the security of Wi-Fi devices often requires writing scripts that send unexpected or malformed frames, to subsequently monitor how the devices respond. Such tests generally use Linux and off-the-self Wi-Fi dongles. Typically, the dongle is put into monitor mode to get access to the raw content of received Wi-Fi frames and to inject, i.e., transmit, customized frames. In this paper, we demonstrate that monitor mode on Linux may, unbeknownst to the user, mistakenly inject Wi-Fi frames or even drop selected frames instead of sending them. We discuss cases where this causes security testing tools to misbehave, making users to believe that a device under test is secure while in reality it is vulnerable to an attack. To remedy this problem, we create a script to test raw frame injection, and we extend the Radiotap standard to gain more control over frame injection. Our extension is now part of the Radiotap standard and has been implemented in Linux. We tested it using commercial Wi-Fi dongles and using openwifi, which is an open implementation of Wi-Fi on top of software-defined radios. With our improved setup, we reproduced tests for the KRACK and FragAttack vulnerabilities, and discovered previously unknown vulnerabilities in three smartphones.

References

  1. John Bellardo and Stefan Savage. 2003. 802.11 Denial-of-Service Attacks: Real Vulnerabilities and Practical Solutions. In USENIX Security.Google ScholarGoogle Scholar
  2. Johannes Berg. 2022. Radiotap: De facto standard for 802.11 frame injection and reception. Retrieved 14 November 2022 from https://www.radiotap.org/.Google ScholarGoogle Scholar
  3. Bastian Bloessl, Michele Segata, Christoph Sommer, and Falko Dressler. 2013. Towards an Open Source IEEE 802.11 p stack: A full SDR-based transceiver in GNU Radio. In 2013 IEEE Vehicular Networking Conference. IEEE, 143--149.Google ScholarGoogle ScholarCross RefCross Ref
  4. Analog Devices. 2022. ADI-linux. Retrieved 17 November 2022 from https://github.com/analogdevicesinc/linux.Google ScholarGoogle Scholar
  5. Ryan Dobbins, Saul Garcia, and Brian Shaw. 2011. Software defined radio localization using 802.11-style communications. Bachelor's Thesis.Google ScholarGoogle Scholar
  6. Thomas d'Otreppe de Bouvette. 2017. aircrack-ng: iw monitor mode flags. Retrieved 15 November 2022 from https://aircrack-ng.blogspot.com/2017/02/monitor-mode-flags.html.Google ScholarGoogle Scholar
  7. Hamed Firooz. 2013. SPAN Lab. https://web.archive.org/web/20130412163400/http://span.ece.utah.edu/pmwiki/pmwiki.php?n=Main.80211bReceiver.Google ScholarGoogle Scholar
  8. Paul Fuxj"ager, A Costantini, D Valerio, P Castiglione, G Zacheo, T Zemen, and F Ricciato. 2010. IEEE 802.11p transmission using GNURadio. In 6th Karlsruhe Workshop on Software Radios (WSR). Karlsruhe Germany, 1--4.Google ScholarGoogle Scholar
  9. GNURadio. 2013. Projects -- The Comprehensive GNU Radio Archive Network (CGRAN). Retrieved 14 November 2022 from https://web.archive.org/web/20131108081814/https://www.cgran.org/wiki/Projects.Google ScholarGoogle Scholar
  10. Andy Green. 2022. How to use packet injection with mac80211. Retrieved 15 Nov. 2022 from hrefhttps://www.kernel.org/doc/html/v6.0/networking/mac80211-injection.htmlkernel.org/doc/html/v6.0/networking/mac80211-injection.html.Google ScholarGoogle Scholar
  11. Francesco Gringoli and Lorenzo Nava. 2022. OpenFWWF: Open FirmWare for WiFi networks. Retrieved 17 November 2022 from https://web.archive.org/web/20220121031132/http://netweb.ing.unibs.it/openfwwf/.Google ScholarGoogle Scholar
  12. Xianjun Jiao, Wei Liu, Michael Mehari, Muhammad Aslam, and Ingrid Moerman. 2020. openwifi: a free and open-source IEEE802. 11 SDR implementation on SoC. In 2020 IEEE 91st Vehicular Technology Conference (VTC2020-Spring). IEEE, 1--2.Google ScholarGoogle ScholarCross RefCross Ref
  13. Jouni Malinen. 2002. Fixed auth/assoc TX callback handling to really use information about whether the transmit was successful or not. Retrieved 15 November 2022 form https://w1.fi/cgit/hostap-history/commit/?id=095f76f19170.Google ScholarGoogle Scholar
  14. Nuand. 2022. bladeRF-wiphy. Retrieved 17 November 2022 from https://www.nuand.com/bladerf-wiphy/.Google ScholarGoogle Scholar
  15. Domien Schepers, Mathy Vanhoef, and Aanjhan Ranganathan. 2021. A framework to test and fuzz Wi-Fi devices. In ACM WiSec. 368--370.Google ScholarGoogle Scholar
  16. Matthias Schulz, Daniel Wegemer, and Matthias Hollick. 2017. Nexmon: The C-based Firmware Patching Framework. https://nexmon.orgGoogle ScholarGoogle Scholar
  17. twisteroidambassador. 2022. linux-ath-user-regd. Retrieved 17 November 2022 from https://github.com/twisteroidambassador/arch-linux-ath-user-regd.Google ScholarGoogle Scholar
  18. Mathy Vanhoef. 2021. Fragment and Forge: Breaking Wi-Fi Through Frame Aggregation and Fragmentation. In USENIX Security. USENIX Association.Google ScholarGoogle Scholar
  19. Mathy Vanhoef. 2023. Injection test script. hrefhttps://github.com/vanhoefm/wifi-injectiongithub.com/vanhoefm/wifi-injection.Google ScholarGoogle Scholar
  20. Mathy Vanhoef and Frank Piessens. 2014. Advanced Wi-Fi attacks using commodity hardware. In ACSAC. 256--265.Google ScholarGoogle Scholar
  21. Mathy Vanhoef and Frank Piessens. 2017. Key reinstallation attacks: Forcing nonce reuse in WPA2. In ACM CCS.Google ScholarGoogle Scholar
  22. Mathy Vanhoef and Eyal Ronen. 2020. Dragonblood: Analyzing the Dragonfly Handshake of WPA3 and EAP-pwd. In IEEE S&P. IEEE.Google ScholarGoogle Scholar

Index Terms

  1. Testing and Improving the Correctness of Wi-Fi Frame Injection

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in
      • Published in

        cover image ACM Conferences
        WiSec '23: Proceedings of the 16th ACM Conference on Security and Privacy in Wireless and Mobile Networks
        May 2023
        394 pages
        ISBN:9781450398596
        DOI:10.1145/3558482

        Copyright © 2023 ACM

        Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 28 June 2023

        Permissions

        Request permissions about this article.

        Request Permissions

        Check for updates

        Qualifiers

        • research-article

        Acceptance Rates

        Overall Acceptance Rate98of338submissions,29%

        Upcoming Conference

        WiSec '24
      • Article Metrics

        • Downloads (Last 12 months)79
        • Downloads (Last 6 weeks)11

        Other Metrics

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader