Guus Sliepen
3730156165
Only free members of connection_t that have been allocated.
2007-03-12 17:55:43 +00:00
Scott Lamb
38c25d62c2
Convert to libevent.
...
This is a quick initial conversion that doesn't yet show much advantage:
- We roll our own timeouts.
- We roll our own signal handling.
- We build up the meta connection fd events on each loop rather than
on state changes.
2007-02-27 01:57:01 +00:00
Guus Sliepen
eb391c52ee
Do not break strict aliasing of status_t structs.
2006-08-08 13:21:08 +00:00
Guus Sliepen
de78d79db8
Update copyright notices, remove Ivo's email address.
2006-04-26 13:52:58 +00:00
Guus Sliepen
228e7a5c8f
Apply patch from Scott Lamb adding an output buffer for the TCP sockets.
...
This helps coalescing multiple send_meta() commands into one TCP packet.
Also limit the size of the output buffer before dropping PACKETs.
2006-01-19 17:13:18 +00:00
Guus Sliepen
df3220a154
Update copyright notices.
2005-05-04 18:09:30 +00:00
Guus Sliepen
56c36a14d8
Use the proper free function.
2004-12-03 13:27:33 +00:00
Guus Sliepen
18c617ecf2
Free memory used by connection_t after it is deleted from the connection tree.
2004-12-03 13:22:18 +00:00
Guus Sliepen
7926a156e5
Update copyrights, links, email addresses and let Subversion update $Id$ keywords.
2004-03-21 14:21:22 +00:00
Guus Sliepen
6c5f3d8b74
We don't have to tell GCC how to cast.
2003-08-28 21:05:11 +00:00
Guus Sliepen
714fb32d03
Fix compile errors and warnings.
2003-07-29 10:50:15 +00:00
Guus Sliepen
83263b7446
Sprinkle around a lot of const and some C99 initialisers.
2003-07-24 12:08:16 +00:00
Guus Sliepen
eefa28059a
Use bools and enums where appropriate.
2003-07-22 20:55:21 +00:00
Guus Sliepen
e449d94cae
Big header file cleanup: everything that has to do with standard system
...
libraries is moved to system.h.
2003-07-17 15:06:27 +00:00
Guus Sliepen
5db596c684
Simplify logging, update copyrights and some minor cleanups.
2003-07-12 17:41:48 +00:00
Guus Sliepen
1401faf608
Sprinkling the source with static and attributes.
2003-07-06 23:16:29 +00:00
Guus Sliepen
0b9175e998
Define logger(), cleans up source code and allows us to write log entries
...
to a separate file.
2003-07-06 22:11:37 +00:00
Guus Sliepen
6c7172d694
This subtle pointer arithmetic thingy is (I'm very sure of it) the cause
...
of the lingering connections problem. Hopefully it is fixed now...
2003-06-25 20:55:05 +00:00
Guus Sliepen
eaf1208e9d
Fix placement of #include "config.h"
2002-09-10 22:13:01 +00:00
Guus Sliepen
6f9f6779e6
Remove redundant spaces.
2002-09-09 22:33:31 +00:00
Guus Sliepen
f75dcef72a
Switch to K&R style indentation.
2002-09-09 21:25:28 +00:00
Guus Sliepen
5fc1ed17f4
Cleanups:
...
- Convert cp to cp(); so that automatic indenters work.
- Convert constructions like if(x == NULL) to if(!x).
- Move all assignments out of conditions.
2002-09-09 19:40:12 +00:00
Guus Sliepen
8b2b67e26c
Generalized request broadcasting/forwarding.
2002-09-04 16:26:45 +00:00
Guus Sliepen
627f7c22b4
s/sliepen.warande.net/sliepen.eu.org/g
...
s/itimmermans@bigfoot.com/ivo@o2w.nl/g
2002-06-21 10:11:37 +00:00
Guus Sliepen
3c5655f59e
Fix compiler warnings, strictly use long int and %lx for options.
2002-03-22 13:31:18 +00:00
Guus Sliepen
c2b9c06062
- Non-blocking connect()s.
...
- Socket handling revamped to use sockaddr_t.
- tinc can now tunnel over IPv6.
- Handle all addresses and subnets in network byte order.
Only convert them when they need to be printed.
- IPv6 subnets bigger than /128 now work.
- Use %s and strerror(errno) instead of %m.
2002-02-18 16:25:19 +00:00
Guus Sliepen
f0aa9641e8
Merging of the entire pre5 branch.
2002-02-10 21:57:54 +00:00
Ivo Timmermans
6cf744e4b2
Don't include netutl.h.
2001-11-16 12:22:02 +00:00
Ivo Timmermans
3ef15f2554
Changed lookup_connection to use struct addrinfo
2001-11-16 12:02:17 +00:00
Guus Sliepen
2165931c62
More updates to protocol handlers and reimplemented terminate_connection().
2001-10-30 16:34:32 +00:00
Guus Sliepen
b6298e2c08
- More changes needed for Kruskal's algorithm
...
- Implemented a breadth-first search algorithm as a cheap substitution for a
single-source shortest path algorithm.
2001-10-28 22:42:49 +00:00
Guus Sliepen
94497336ef
What was I thinking? s/vertex/edge/g.
2001-10-28 08:41:19 +00:00
Guus Sliepen
b98d9787fd
Various small fixes to make tinc runnable again.
2001-10-27 15:19:13 +00:00
Guus Sliepen
82e3837109
Big bad commit:
...
- Transition to new node/vertex/connection structures
- Use new configuration handling everywhere
- Linux tun/tap device handling cleanup
- Start of IPv6 support in route.c
It compiles, but it won't link.
2001-10-27 12:13:17 +00:00
Guus Sliepen
0bbace18e9
More updates to new node/vertex/connection combo.
2001-10-10 20:35:10 +00:00
Guus Sliepen
5904806dc8
Removed everything from connection.c that has already been moved to node.c and
...
vertex.c.
2001-10-10 09:42:29 +00:00
Guus Sliepen
21027b1d57
- Renamed lastbutonehop to prevhop.
...
- Added connection_t *via to connection_t, this keeps record of where
to send UDP packets to.
2001-10-08 11:47:55 +00:00
Guus Sliepen
4d3de3b6a9
Show next- and lastbutonehop when dumping connectionlist to syslog.
2001-09-24 14:16:29 +00:00
Guus Sliepen
acb853205d
Updated terminate_connection() so you can choose if DEL_HOSTs should be
...
sent or not.
2001-07-21 15:34:18 +00:00
Guus Sliepen
12f6b80429
Added purge_tree for connection_t's which are no longer in the connection,
...
active or id trees, but which may still be referenced. This tree is flushed
when it is safe, this replaces purge_connection_tree().
Also lots of bugfixes related to the new trees.
2001-07-20 20:25:10 +00:00
Guus Sliepen
319e0cb48e
Split connection list into two lists:
...
- one list to handle all incoming/outgoing TCP connections
- another list to handle all UDP connections
This will prevent race conditions.
2001-07-15 18:07:31 +00:00
Guus Sliepen
c9591bd1de
Fix gcc 3.0 warnings.
2001-06-29 13:09:55 +00:00
Guus Sliepen
4f9dad0972
- tinc can now act as a switch or a hub too (as opposed to a router only)
...
- cleaner initialisation of "UNKNOWN" and "MYSELF" names
2001-06-05 16:09:55 +00:00
Guus Sliepen
34f9e6cf2d
- route.c is now used to determine destination
...
- flags are removed, since they were not used at all. Use options instead.
- indirectdata works now, tcponly almost...
- made functions that don't return useful information void
2001-03-04 13:59:32 +00:00
Guus Sliepen
d3f889c807
- It's 2001, all copyright notices are updated.
2001-01-07 17:09:07 +00:00
Guus Sliepen
07a08f5539
- Reinstated a queue for outgoing packets.
2001-01-07 15:25:49 +00:00
Guus Sliepen
e924096f62
- Let user choose whether keys are in the config files or separate
...
- Use AVL trees instead of RBL trees
- Fixed a lot of annoying subtle bugs! Thanks to gdb...
2001-01-05 23:53:53 +00:00
Guus Sliepen
cf49b2c064
Another big & bad commit:
...
- Added some extra search functions to rbl routines
- Fix subnet_lookup()
- Reorder some syslog messages to make more sense
- daemon() is back
- Don't let scripts execute in parallel (gives race conditions, and
anyway something MIGHT just be configured which is necessary for further
execution of tinc itself)
- Accidently merged check_child() with execute_script().
- Small fixes
2000-11-24 23:13:07 +00:00
Guus Sliepen
dac256505e
- Fixed all (except 2) compiler warnings gcc -Wall gave.
2000-11-22 22:18:03 +00:00
Guus Sliepen
f8b4a000d0
- Cleaned up and checked for some more NULL pointers in rbl.c
...
- Two connection lists: one for incoming connections, sorted on ip/port,
one for connections whose identity we know, sorted on id ofcourse...
2000-11-22 18:54:08 +00:00
Guus Sliepen
3a6200c1e3
- Various small fixes.
2000-11-20 22:13:14 +00:00
Guus Sliepen
1857b3c97c
- Proper initialization of rbltree structures.
2000-11-20 19:41:13 +00:00
Guus Sliepen
408ca91766
- Integrate rbl trees into tinc.
2000-11-20 19:12:17 +00:00