Open 3brahimi opened 3 years ago
Not sure it it's still the case, but once upon a time Libtins would add FCS by default -- and then RTL8812 driver would add another FCS on top of that, because it didn't parse injected packet radiotap headers to determine if it already had an FCS or not. Result was 4 extra bytes of garbage on injected frames.
Solution was to tell Libtins to not add FCS: RadioTap().flags((RadioTap::FrameFlags)0)
I also have a script that shows issues with packet. don't have time now though.
Also saw the issue using libtins
Issue: Garbage accompanies the transmitted packets. Severity: functionality of the driver
Description:
Packets crafted by
libtins
(pulled today Mon 8. Mar 2021) andscapy
are accompanied with some garbage when transmitted over. Below you can find more information about the issue I am facing. Anyone there to help? @aircrack-ng @kimocoderOS
Linux kali 5.10.0-kali3-amd64 #1 SMP Debian 5.10.13-1kali1 (2021-02-08) x86_64 GNU/Linux
.WLAN Adapter
ALFA AWUS036ACH with driver version
5.6.4.2
and5.7.0
ALFA AWUS036H with Kali's driver works fine.Compiler
g++ (Debian 10.2.1-6) 10.2.1 20210110
cmake version 3.18.4
Dependancies
tcpdump version 5.0.0-PRE-GIT
libpcap version 1.11.0-PRE-GIT (with TPACKET_V3)
OpenSSL 1.1.1j 16 Feb 2021
bison (GNU Bison) 3.7.5
flex++ 2.6.4
Code to craft an open authentication packet:
Dot11Authentication auth( ap_addr, sta_addr );
auth.addr3( ap_addr );
auth.auth_algorithm( 0 );
auth.auth_seq_number( 0x0001 );
auth.status_code( 0x0000 );
auto radio = RadioTap() / auth;
Code to send the packet:
PacketSender sender( iface );
sender.send( radio );
Code to save the packet:
PacketWriter w( "auth.pcap", PacketWriter::RADIOTAP );
w.write( radio );
Dumped packet in Wireshark:
Frame 1: 60 bytes on wire (480 bits), 60 bytes captured (480 bits)
Transmitted packet captured by Wireshark
Frame 18: 63 bytes on wire (504 bits), 63 bytes captured (504 bits) on interface XXXXXXX, id N