1
0
mirror of https://github.com/mfontanini/libtins synced 2026-01-23 02:35:57 +01:00
Commit Graph

174 Commits

Author SHA1 Message Date
Matias Fontanini
3e7d30e01c Don't include heavy STL headers like <algorithm> in header files
This provides a considerable compilation time reduction and most
of these were just using std::copy/fill which can be replaced by
memcpy/memset, as all of their uses were applied to POD types
2017-06-05 20:44:03 -07:00
Matias Fontanini
22c72955f5 Remove Storage template parameter from HWAddress, move impl to cpp
This is a breaking ABI change. This might break some forward
declarations and hopefully no one was actually using the
Storage type for anything.
2017-06-05 20:44:03 -07:00
Matias Fontanini
6f681f6519 Move smart_ptr definition into new file detail/smart_ptr.h 2017-06-05 20:44:03 -07:00
Matias Fontanini
c7273ddd30 Add PDU iterator class 2017-06-05 20:44:03 -07:00
Matias Fontanini
2c6ef2a5c0 Update license date to 2017 2017-06-05 20:44:03 -07:00
Matias Fontanini
4eb4dfe5fa Remove parent parameter from write_serialization
This is no longer needed as each PDU knows its parent PDU already
2017-06-05 20:44:03 -07:00
Matias Fontanini
8838ddf921 Add parent PDU member to PDU class
Now this is a bidirectional list of PDUs
2017-06-05 20:44:03 -07:00
Matias Fontanini
7f8644cb39 Merge branch 'develop' 2017-03-23 19:31:10 -07:00
Matias Fontanini
799ba2b4b6 Allow disabling pcap packet capture 2017-03-21 19:04:33 -07:00
Matias Fontanini
7607610cf9 Merge branch 'develop' 2017-01-31 21:37:41 -08:00
Kyle Fazzari
a71a3d29ff Fix -Wextra compiler warnings. (#184)
* Fix -Wextra compiler warnings.

Fix #183.

Signed-off-by: Kyle Fazzari <github@status.e4ward.com>

* Comment out unused parameters.

This is done everywhere possible instead of using Internals::unused().
Note that this involved moving some implementations into the
corresponding .cpp file.

Signed-off-by: Kyle Fazzari <github@status.e4ward.com>

* Fix warnings in tests as well.

Signed-off-by: Kyle Fazzari <github@status.e4ward.com>

* Leave IPv4Reassembler alone, it's growing.

Signed-off-by: Kyle Fazzari <github@status.e4ward.com>
2017-01-25 13:26:11 -08:00
Ed Catmur
9051197603 Use actual payload length to construct inner PDU. (#179)
Fixes #178
2017-01-16 09:36:33 -08:00
Matias Fontanini
c69ea0c1fb Keep original out of order callback on recovery mode 2016-10-30 13:08:17 -07:00
Matias Fontanini
a63387f85e Add Stream recovery mode 2016-10-30 11:38:50 -07:00
Matias Fontanini
df7e7b391d Add flag to Stream to know whether it was attached 2016-10-30 10:31:16 -07:00
Matias Fontanini
5d6431d2d9 Allow enabling attachment to partial streams 2016-10-30 10:21:58 -07:00
Patrick Michel
aaba3dd46a Feature - Skipping ahead in TCP flows. (#163)
* Skipping forward in TCP streams, from an out-of-order callback.

- Added the ability to skip forward in a flow to a sequence number, with the intention of doing so in an out of order callback.
- Re-ordered Flow packet processing, to allow skipTo in out of order callback on stream start (flow sequence number is 0).
- Fixed missing seq_compare in flow code.

* Renamed skipTo to advance_sequence.
2016-10-23 09:47:56 -07:00
Matias Fontanini
e82b72e931 Use relative include for config.h 2016-09-27 22:06:09 -07:00
Matias Fontanini
fdc6ccdf5c Only enable TCP stream's custom data if boost.any is found 2016-09-27 21:46:38 -07:00
Patrick Michel
52b389afe8 Allow setting custom user data to each TCP stream 2016-09-27 21:33:10 -07:00
Matias Fontanini
a192e814bf Allow configuring pcap timestamp precision 2016-06-17 09:20:43 -07:00
Jacob Parker
1552e33c67 Add helper function to create StreamIdentifier from const Stream& (#152) 2016-06-07 13:19:55 -07:00
Wouter Overmeire
8afc784956 Fix typo in arp.h comment (#151) 2016-06-06 10:36:36 -07:00
Rolf Winter
5b00916f83 fixed: superfluous includes, docu (#148) 2016-05-26 09:11:48 -07:00
Matias Fontanini
8cf367d68c Make Timestamp::current_time work on Windows 2016-05-08 10:26:57 -07:00
Matias Fontanini
d070978a54 Add TINS_API to DataTracker and AckTracker classes 2016-05-08 09:38:52 -07:00
Matias Fontanini
7f30efab38 Fix typo in macros.h
[ci skip]
2016-05-05 12:40:11 -07:00
Matias Fontanini
d7fed87ebb Use recvfrom on BSD/OSX when capturing layer 3 packets
Fixes #147
2016-05-03 19:35:24 -07:00
Matias Fontanini
269ac164ed Use exception strings on std::runtime_error's constructor
Fixes #146
2016-05-03 14:50:28 -07:00
Matias Fontanini
55edf31aa6 Move TCP data tracking into a separate class 2016-05-03 14:50:28 -07:00
Matias Fontanini
8d52d73968 Allow disabling TCPIP classes 2016-04-02 09:35:42 -07:00
Matias Fontanini
48022d3a3f Rename and undef symbols that conflict with macro names on DNS
The undefs are a temporary fix until we get rid of the old,
conflicting, names

Fixes #141
Fixes #58
2016-04-02 09:16:28 -07:00
Matias Fontanini
ec1634d6d8 Move stream_id into a new file and rename it to StreamIdentifier 2016-03-28 21:38:43 -07:00
Matias Fontanini
a70ce10bed Add IPv4Address::from_prefix_length 2016-03-19 16:26:00 -07:00
Matias Fontanini
3773443fc8 Allow masking IPv4/6 and HW addresses 2016-03-19 15:44:55 -07:00
Matias Fontanini
1f4be63d08 Properly handle MLDv1 on ICMP 2016-03-17 21:49:06 -07:00
Matias Fontanini
8b125d31f2 Add TINS_API to operator<< for IPv4Address 2016-03-16 20:51:37 -07:00
stubbfel
d70536f9ab add first_address_from_mask in internals and call them from addressrange::from_mask 2016-03-16 22:28:21 +01:00
Matias Fontanini
97e24131c6 Fix issues pointed out by scan.coverity 2016-03-07 20:29:12 -08:00
Matias Fontanini
42b6c40433 Add Utils::route6_entries on OSX/BSD 2016-03-07 19:40:38 -08:00
Matias Fontanini
4dcef0f15d Add Utils::route6_entries 2016-03-06 19:18:33 -08:00
Matias Fontanini
c082dfad67 Minor changes on TCPIP::StreamFollower 2016-03-06 13:40:10 -08:00
Matias Fontanini
e15ef0d837 Add info members directly into NetworkInterface 2016-03-05 10:33:50 -08:00
Matias Fontanini
3a99213c0b Rename IPv6AddressPrefix to IPv6Prefix 2016-03-02 21:34:21 -08:00
Matias Fontanini
ad71158268 Add IPv6 addresses to NetworkInterface::Info 2016-03-02 21:13:50 -08:00
Matias Fontanini
cfbf88bb5f Make *MemoryStream use size_t rather than uint32_t 2016-02-28 08:12:05 -08:00
Matias Fontanini
1681981fe8 Add WPA2Decrypter callback interface 2016-02-28 08:01:04 -08:00
Matias Fontanini
92f0249d2b Cleanup IPv4Reassembler 2016-02-21 18:20:06 -08:00
Matias Fontanini
fa4178de09 Fix flag value for sniffer's immediate mode 2016-02-21 14:42:24 -08:00
Matias Fontanini
8812153491 Remove extra include on tins.h 2016-02-21 09:14:14 -08:00