3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-10-03 18:08:42 +02:00
Commit Graph

32 Commits

Author SHA1 Message Date
Mat Martineau
0e108f9727 monitor: Remove GENL_ID_GENERATE
Kernel v4.10 and later no longer export GENL_ID_GENERATE (which was
defined as 0). iwd was using this symbol to check for unmodified local
values rather than to ask for a dynamically generated netlink ID anyway,
so it makes sense to use the value 0 directly. This will work with
kernels before and after the GENL_ID_GENERATE change.
2017-04-14 15:52:11 -05:00
Denis Kenzior
303490261f monitor: Add nortnl option to help output 2017-03-24 10:51:01 -05:00
Denis Kenzior
d6a9b0f85a monitor: Add option to not print rtnl output 2016-07-13 10:14:28 -05:00
Denis Kenzior
6de565db05 monitor: Update to new l_main api 2016-06-09 09:39:03 -05:00
Marcel Holtmann
75ec08df73 monitor: Define ARPHRD_NETLINK if it not provided by system headers 2014-12-19 01:44:49 +01:00
Ravi kumar Veeramally
deb80322ea monitor: Fix memory leak
Memory allocated l_timeout struct from l_timeout_create not being
freed.

==4184== HEAP SUMMARY:
==4184==     in use at exit: 32 bytes in 1 blocks
==4184==   total heap usage: 50 allocs, 49 frees, 39,902 bytes allocated
==4184==
==4184== 32 bytes in 1 blocks are definitely lost in loss record 1 of 1
==4184==    at 0x4C2ABA0: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==4184==    by 0x40706D: l_malloc (util.c:62)
==4184==    by 0x408D9A: l_timeout_create (timeout.c:117)
==4184==    by 0x40896A: signal_callback (signal.c:82)
==4184==    by 0x408692: l_main_run (main.c:346)
==4184==    by 0x402474: main (main.c:797)
==4184==
==4184== LEAK SUMMARY:
==4184==    definitely lost: 32 bytes in 1 blocks
==4184==    indirectly lost: 0 bytes in 0 blocks
==4184==      possibly lost: 0 bytes in 0 blocks
==4184==    still reachable: 0 bytes in 0 blocks
==4184==         suppressed: 0 bytes in 0 blocks
2014-12-16 08:56:57 -06:00
Denis Kenzior
d9768348d5 monitor: Always try to find an existing interface
Duplicate detection will happen when we try to create a new link.  The
newlink flags were updated to fail if the device already exists.
2014-10-04 21:31:58 -05:00
Denis Kenzior
046e49588e monitor: Fix minor coding style issues 2014-10-04 21:08:51 -05:00
Denis Kenzior
5fae2cc524 monitor: Fix whitespace
No spaces for indentation
2014-10-04 21:07:18 -05:00
Patrik Flykt
1d4ab8de47 monitor: Remove netlink monitor interface if created by iwmon
Send a RTM_DELLINK for the interface in use if it was created by iwmon.
As the main loop needs to be running when sending RTM_DELLINK, add a
timeout function for quitting the main loop.
2014-10-04 21:07:15 -05:00
Patrik Flykt
0b75b71555 monitor: Create netlink monitor interface if not found
If the netlink monitor interface is not found or did not have all needed
flags set, create one with the proper flags.
2014-10-04 20:58:46 -05:00
Denis Kenzior
73f5f0766d monitor: Fix memory leak
In the case that we use iwmon --interface nlmon
2014-10-04 20:50:16 -05:00
Denis Kenzior
38ab7511af monitor: minor coding style fix ups 2014-10-04 20:41:32 -05:00
Patrik Flykt
19e2132fce monitor: Lookup existing monitor interface via netlink
On startup, request a list of interfaces via netlink. Find out whether
an interface of type nlmon exists and use it if it has all the needed
flags set. The default name of the interface is 'nlmon', which can be
changed from the command line. If the interface name is in use and is
not an nlmon type, print out an error message and exit.
2014-10-04 19:56:01 -05:00
Marcel Holtmann
9fa506c237 monitor: Add option to provide nl80211 family identifier 2014-08-16 00:00:10 +02:00
Marcel Holtmann
18652f1f49 monitor: Add support for extracting family identifiers from traces 2014-08-15 23:38:37 +02:00
Marcel Holtmann
d3f37628b0 monitor: Add support for writing combined PCAP trace files 2014-08-12 19:35:59 -07:00
Marcel Holtmann
581f00171d monitor: Skip packet from PCAP file if it is truncated 2014-08-12 00:40:07 -07:00
Marcel Holtmann
a95c720d64 monitor: Decode the EAPoL packet headers of PAE frames 2014-08-10 20:20:13 -07:00
Marcel Holtmann
a2a59e78fa monitor: Extract PAE port traffic out of PCAP files and decode it 2014-08-10 18:32:11 -07:00
Marcel Holtmann
b4eb544355 monitor: Handle timestamp and real packet length information 2014-08-10 12:45:56 -07:00
Marcel Holtmann
b91bb55206 monitor: Use packet buffer of 16 kilobytes to allow large frames 2014-08-10 12:25:20 -07:00
Marcel Holtmann
7a1bb1e953 monitor: Improve message and attribute display handling 2014-08-09 22:59:42 -07:00
Marcel Holtmann
9635f317c0 monitor: Add support for builtin pager functionality 2014-08-09 19:29:48 -07:00
Marcel Holtmann
b5b292ee25 monitor: Terminate program when setup of netlink monitor failed 2014-08-09 12:32:29 -07:00
Marcel Holtmann
9694998f28 monitor: Minor typo fix in usage text 2014-08-08 15:20:24 -07:00
Marcel Holtmann
34f5c56199 monitor: Print program description and version 2014-08-07 01:01:28 +02:00
Marcel Holtmann
609cc86717 monitor: Do not abort when receiving unknown ARPHRD 2014-08-06 06:52:09 +02:00
Marcel Holtmann
d484715a17 monitor: Check that protocol type is set to generic netlink 2014-08-06 00:12:20 +02:00
Marcel Holtmann
d0068dcf4c monitor: Add support for reading traces from PCAP files 2014-08-05 22:40:43 +02:00
Marcel Holtmann
e260854da3 monitor: Add command line option for netlink monitor device 2014-08-05 21:39:54 +02:00
Marcel Holtmann
db60e4d48f monitor: Add initial version of iwmon utitlity 2014-08-03 06:03:53 +02:00