Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | tun-device: Use next free TUN device on FreeBSD | Tobias Brunner | 2017-05-19 | 1 | -3/+18 |
| | | | | | | | | | | | While this API is documented as legacy (and there is a sysctl option to disable it) the documentation also mentions that it will probably stay enabled by default due to compatibility issues with existing applications. With the previous approach only 255 devices could be opened then the daemon had to be restarted. Fixes #2313. | ||||
* | tun-device: TUN devices are not supported on iOS | Tobias Brunner | 2017-05-19 | 1 | -1/+10 |
| | |||||
* | Use standard unsigned integer types | Andreas Steffen | 2016-03-24 | 1 | -8/+8 |
| | |||||
* | tun-device: Read from tun to buffer on stack to avoid over-allocation of packets | Martin Willi | 2014-11-21 | 1 | -8/+6 |
| | | | | | | | Instead of allocating MTU-sized buffers for each packet, read to a stack buffer and copy to an allocation of the actual packet size. While it requires an additional copy on non-Apple platforms, this should make allocation more efficient for small packets. | ||||
* | tun-device: Remove the superfluous use of select() before read() | Martin Willi | 2014-11-21 | 1 | -16/+5 |
| | |||||
* | tun-device: Rearrange headers to build properly when tun devices not supported | Martin Willi | 2014-06-03 | 1 | -19/+13 |
| | |||||
* | tun-device: Use SIOCAIFADDR to set IP address on FreeBSD 10 | Tobias Brunner | 2014-04-25 | 1 | -2/+90 |
| | | | | | | | | FreeBSD 10 deprecated the SIOCSIFADDR etc. commands, so we use this newer command to set the address and netmask. A destination address is now also required. Fixes #566. | ||||
* | tun-device: Include system headers before our own | Tobias Brunner | 2013-12-20 | 1 | -2/+5 |
| | | | | | | | | | | | | | On CentOS 6.5 the sys/capability.h header file defines _LINUX_TYPES_H without actually including that header, preventing its later inclusion here. As library.h (via which the capabilities headers are included) is not actually required in tun_device.[ch], moving the inclusion of tun_device.h would not strictly be necessary. But it's probably a good idea to include our own headers after system headers anyway, for if one of the recursively included files at a later point includes library.h we'd have the same problem again. | ||||
* | tun-device: Include <linux/types.h> before <linux/if_tun.h> | Martin Willi | 2013-11-22 | 1 | -0/+1 |
| | | | | Fixes a build error on CentOS 6.4. | ||||
* | tun_device: Add warning if TUN devices are not supported by platform | Tobias Brunner | 2013-09-12 | 1 | -2/+16 |
| | |||||
* | tun-device: Packets sent over utun devices on Mac OS X have the protocol ↵ | Tobias Brunner | 2013-06-21 | 1 | -0/+11 |
| | | | | family prepended | ||||
* | tun-device: Avoid opening /dev/tunX multiple times (e.g. on FreeBSD) | Tobias Brunner | 2013-06-21 | 1 | -2/+6 |
| | |||||
* | tun_device: add a getter for the address previously passed to set_address() | Martin Willi | 2013-05-06 | 1 | -0/+24 |
| | |||||
* | tun_device: add a getter for the underlying file descriptor | Martin Willi | 2013-05-06 | 1 | -0/+7 |
| | |||||
* | tun-device: use host_create_netmask() to calculate interface netmask | Martin Willi | 2013-05-06 | 1 | -49/+12 |
| | |||||
* | Set sockaddr family on ifreq instead of casted familiy specific sockaddr | Martin Willi | 2013-02-06 | 1 | -2/+2 |
| | | | | Fixes a strict-aliasing rule compiler warning with older gcc. | ||||
* | Moved debug.[ch] to utils folder | Tobias Brunner | 2012-10-24 | 1 | -1/+1 |
| | |||||
* | Moved packet_t and tun_device_t to networking folder | Tobias Brunner | 2012-10-24 | 1 | -0/+461 |