Repository navigation
Commit 76a56eb
mac80211_hwsim: Fix radiotap header for ACK frames
The earlier addition of rt_tsft to struct hwsim_radiotap_hdr updated
only mac80211_hwsim_monitor_tx() to fill in the new field.
mac80211_hwsim_monitor_ack() did not set the rt_tsft field and as such,
leaked eight bytes of kernel memory to user space. In addition, the
resulting radiotap header is invalid since the field offsets do not
match. Fix these issues by defining a separate radiotap header structure
for the ACK frame case which does not use all the fields.
Signed-off-by: Jouni Malinen <j@w1.fi>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>1 parent 2d3db21 commit 76a56eb
1 file changed
Lines changed: 11 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
383 | 383 | | |
384 | 384 | | |
385 | 385 | | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
386 | 394 | | |
387 | 395 | | |
388 | 396 | | |
| |||
500 | 508 | | |
501 | 509 | | |
502 | 510 | | |
503 | | - | |
| 511 | + | |
504 | 512 | | |
505 | 513 | | |
506 | 514 | | |
| |||
511 | 519 | | |
512 | 520 | | |
513 | 521 | | |
514 | | - | |
| 522 | + | |
515 | 523 | | |
516 | 524 | | |
517 | 525 | | |
518 | 526 | | |
519 | 527 | | |
520 | 528 | | |
521 | | - | |
| 529 | + | |
522 | 530 | | |
523 | 531 | | |
524 | 532 | | |
| |||
0 commit comments