Bug 215681

Summary: Malicious advertising data showed in dmesg
Product: Drivers Reporter: Olivier JUDITH (gnulux)
Component: BluetoothAssignee: linux-bluetooth (linux-bluetooth)
Status: NEW ---    
Severity: normal    
Priority: P1    
Hardware: ARM   
OS: Linux   
Kernel Version: 5.10.95 Subsystem:
Regression: No Bisected commit-id:

Description Olivier JUDITH 2022-03-14 15:35:35 UTC
Hi, 

I have recently moved from Raspbian 9 to 10 which means kernel 4.19 to kernem 5.10 . 
I use an application that advertises permanently and scans ble devices. 
Since the upgrade i noticed plenty of messages in  dmesg output like this : 

[Mon Mar 14 15:16:44 2022] Bluetooth: hci0: Malicious advertising data. Stopping processing

This kind of messages were not displayed with 4.19 kernel

Any suggestions, how I can disable this flooding message?
Comment 1 Artem S. Tashkinov 2022-03-15 15:41:09 UTC
If you can compile the kernel, please do.

Find the code which prints it and patch it this way:

https://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git/commit/?id=2d4b37b67cacbbad6fdb8621333f5ce48ae0e5fd
Comment 2 Olivier JUDITH 2022-03-16 16:55:22 UTC

Hi, 

Yes i compiled before and i can do it again. 
In the meanwhile i tried 5.15 and i've no Malicious messages displayed.

i'll we apply you suggestion

The issue come from hci_le_adv_report_evt in hci_event.h. i noticed that this function is a bit different in 5.15. 

i also understood that the change was to evict flow of messages but the real cause seems to be a packet size is exceeded. Does this mean that my advertising is not correct ?