summaryrefslogtreecommitdiff
path: root/usr.sbin/ldpd
AgeCommit message (Collapse)Author
2010-04-15Log recieved notifications in a human understanable way. Makes debuggingClaudio Jeker
a bit easier. OK michele@
2010-04-15Cleanup the interface FSM by removing most of the ospfd specific statesClaudio Jeker
that have nothing to do with LDP. OK michele@
2010-04-15session_shutdown() issues a NBR_EVT_CLOSE_SESSION and therefore aClaudio Jeker
session_close() which does the event_del(&nbr->rev) so no need to do it twice. There is also no need to send two S_SHUTDOWN messages. OK michele@
2010-04-15Fix fd leak in error case.Claudio Jeker
OK michele@
2010-04-15Instead of having three ways of setting fds non-blocking useClaudio Jeker
session_socket_blockmode() everywhere. Additionally make two fatal() distinguishable. OK michele@
2010-04-15struct ldp_hdr has probably the worst possible layout (ending with a singleClaudio Jeker
u_int16_t) and must therefor be __packed or sizeof() returns a to large size and causes some very nasty issues. "embrace __packed" dlg@ OK michele@ While there add new notification status types defined in RFC5036
2010-04-15Even though label withdraw, release, and abort requests are not fullyClaudio Jeker
implemented use a correct return value so that ldpd has a chance to survive when one of those messages are received. OK michele@
2010-04-13When a prefix has a implicit null label associated, force pop operation.Michele Marchetto
This allow us to correcly do penultimate hop popping. From Thomas Habets. Thanks. ok claudio@
2010-04-07Remove XXX comment and just close received fd if calloc() fails.Nicholas Marriott
If this happens the imsg may no longer be usable as there may be queued messages, but this is a) already the case with the code now, and b) would be the case if recvmsg() fails anyway, so we can document that -1 from imsg_read() invalidates the struct imsgbuf. discussed with and ok eric
2010-03-26Never call close(nbr->fd) when the neighbor session was fully established,Claudio Jeker
call session_close(nbr) instead since only that will do all needed cleanup. Still not prefect but at least the lde is no longer eating all CPU when a session times out. OK michele@
2010-03-26event_del() the read event when hitting a read error or when closing theClaudio Jeker
file descriptor. If not done, we will loop forever on this event. OK michele@
2010-03-25Kroute updates from the LDE are per FEC so do the lookup in kroute withClaudio Jeker
prefix/len and nexthop but do not consider the priority. send_rtmsg() needs to use the kroute element and not the one sent from the LDE since that one has no priority set (which is needed). This seems to solve a problem where ldpd modified the wrong routes. OK michele
2010-03-24We need to set the rtm_priority when changing a route so that we do notClaudio Jeker
modify a possible better route instead. A bit more is still needed. OK michele@
2010-03-03Rework the kroute code by stealing some code from ospfd and massaging itClaudio Jeker
a lot more. Main reason for this is to add priority support. Additionally add some additional NO_LABEL fixes. OK michele@
2010-03-01nitpicking, NULL instead of 0 in lde_imsg_compose_ldpe() call.Claudio Jeker
2010-02-25One more substitution of label 0 with NO_LABEL.Michele Marchetto
ok claudio@
2010-02-25Whitespaces cleanup.Michele Marchetto
2010-02-25NO_LABEL (instead of zero) must be used to mean that no labels are associatedMichele Marchetto
with the prefix. ok claudio@
2010-02-25Do not use bufferevent for something that's already covered in the imsgClaudio Jeker
buffer API. This fixes a few possible problems in session_read and does some further cleanup in various places. Wrap msgbuf into evbuf to add libevent functionality and use buf_read to handle the read side of a session. OK michele@ and dlg@ did not see anything evil
2010-02-24sort SEE ALSO;Jason McIntyre
2010-02-23Fix .Oo .Xo .Oc .Xc mis-nesting by just dropping the .Xo and .Xc which,Ingo Schwarze
in these cases, is useless anyway. Found by and fixing the build with mandoc; still fine with both old and new groff. ok jmc@
2010-02-22Correctly encode FEC prefixes. This makes my test setup much happyer.Claudio Jeker
OK michele
2010-02-21Kill double declaration of control_imsg_relay().Michele Marchetto
From Christiano F. Haesbaert. ok claudio@
2010-02-21Check bufferevent_new() return value. If it is NULL print an error messageMichele Marchetto
and return. From Martin Hedenfalk. ok claudio@
2010-02-20Make send_* functions return void (and not int) as they can just succeedMichele Marchetto
or fatal(). ok claudio@
2010-02-20Remove unneeded abstraction in neighbor fsm.Michele Marchetto
ok claudio@
2010-02-19Oups, unbreak build.Claudio Jeker
2010-02-19Cleanup a bit, remove unneeded dummy neighbor and initialize queue headsClaudio Jeker
in the correct place. Queue mappings ordered by inserting at tail. OK michele
2010-02-19If a neighbor goes down we need to cleanup the LIB from all FEC that pointClaudio Jeker
via that neighbor. Fixes a use after free and an additional NULL dereference in a log_debug is fixed as well. OK michele
2010-02-19Do not double free a knode when kroute_insert() fails. kroute_insert()Claudio Jeker
will free the node if something fails. OK michele
2010-02-18Make the output of printconf() look like a real config file.Claudio Jeker
OK michele@
2010-02-18Set the correct defaults for label advertisement, retention and distribution.Michele Marchetto
ok claudio@
2010-02-18We need to set SO_REUSEADDR before doing the bind() of the tcp socket.Claudio Jeker
It does not help to set SO_REUSEPORT after doing the bind. Fixes failures to start ldpd because of TIME_WAIT sessions. OK michele
2010-02-18Remove some debug messages that are too verbose and no longer needed.Claudio Jeker
OK michele@
2010-02-18Close a fd leak when opening the tcp connection to the neighbor.Claudio Jeker
OK michele
2010-02-16Make ldpd less verbose.Michele Marchetto
ok claudio@
2010-02-16Plug a memory leak in pushfile().Michele Marchetto
ok claudio@
2010-01-19Don't fatalx() when a static route is deleted.Michele Marchetto
ok claudio@
2010-01-08Implement section A.1.6 of RFC 5036: "Recognize new FEC".Michele Marchetto
When a new prefix is learnt, redistribute the local label associated with it to the other connected peers. ok claudio@
2010-01-02sort SEE ALSO;Jason McIntyre
2010-01-02The .Rs macro must be followed by .Re, and empty .Rs is useless anyway.Ingo Schwarze
Markup syntax error found by mandoc(1), also required to fix the mandoc build. ok jmc@ sobrado@
2010-01-02In the "ldpctl show lib" output print every known label and make clear if itMichele Marchetto
is currently in use or not. ok claudio@
2009-12-30Correctly parse the host address in the FEC TLV.Michele Marchetto
ok claudio@
2009-12-10Length of the host address in the FEC TLV must be encoded in numberMichele Marchetto
of octets. ok claudio@
2009-12-09Enable parsing of the optional Transport Address TLV in the helloMichele Marchetto
message. ok claudio@
2009-12-08porcesses -> processesJonathan Gray
2009-12-06During the session's initialization, when playing the passive role, sendMichele Marchetto
the initialization message before the keepalive. This fixes session initialazion failures noticed by Christophe Fillot. ok claudio@
2009-12-02log_warn() consistency.Michael Knudsen
`OK' claudio
2009-11-02More IMSG_CTL_LOG_VERBOSE, still doing the same toggeling of log_debug().Claudio Jeker
2009-11-01Initialize "len" before using it in accept(2).Michele Marchetto
Found by Christophe Fillot ok claudio@