summaryrefslogtreecommitdiff
path: root/usr.sbin/ripd
AgeCommit message (Collapse)Author
2009-06-08revert this change by eric@:David Gwynne
Make the imsg protocol network-safe. it might be network safe, but half the imsg based daemons on my firewalls dont run anymore.
2009-06-07Change the way fds passed over a socket are retreived on the receiving side.Eric Faurot
Currently the receiver fetches an imsg via imsg_get() and if he expects an fd, he then calls imsg_get_fd() to fetch the next fd queued on the imsgbuf from which the imsg came. This changes hides the fd queueing mechanism to the API user. When closing an imsg with an fd, the message is flagged so that the receiving end knows it must dequeue the fd in imsg_get() and return it with the imsg structure. This way there is no (less) possible screw up from imsg_get_fd() not being called directly after imsg_get() by the user. The retreived imsg is self-contained. ok pyr@, "I like that" henning@
2009-06-07Make the imsg protocol network-safe.Eric Faurot
ok pyr@
2009-06-06change the imsg header fields a bit to prepare for upcoming changes.Eric Faurot
add a flag field, use u_int32_t for pid_t and extend type to 32 bits for padding. ok pyr@
2009-06-06Get ready for including imsg.h from a lib, when it comes along.Pierre-Yves Ritschard
2009-06-06make ripctl/ripd imsg-in-a-lib ready too.Eric Faurot
ok pyr@
2009-06-05rtm->rtm_hdrlen conversionChris Cappuccio
ok claudio@, henning@
2009-06-02Same reject and blackhole route handling as in ospfd. Allow those routesClaudio Jeker
to be redistributed even though they point to 127.0.0.1. OK michele@
2009-05-31Remove redundant imsg_event_add calls; ok claudio@Jacek Masiulaniec
2009-05-31Better EV_READ and EV_WRITE handling in the libevent callbacks. Again mostlyClaudio Jeker
the same ospfd diff applied with some fuzz.
2009-03-31Fixed memory leaks which would occur if the second of two memoryTobias Stoeckmann
allocations fails. looks right deraadt, krw ok henning
2009-03-31Assign the correct metric to the routes learned from the kernel while ripd isMichele Marchetto
running. Issue spotted and diff tested by Steven Surdock. ok claudio@
2009-03-27Allow the announcement of default route also via redistribute 0.0.0.0/0Michele Marchetto
and route labels. ok claudio@
2009-03-25With redistribute connected set, announce the prefix on the interfaceMichele Marchetto
with address belonging to that prefix. Don't skip it. ok claudio@
2009-03-24Change the behaviour of redistribute default.Michele Marchetto
Now a default route have to be present in the fib to be correctly advertised. Spotted and tested by Steven Surdok on ripd. ok claudio@
2009-03-04typo;Michele Marchetto
unknon -> unknown
2009-02-25Fix an invalid pointer dereference in control_close(). If control_connbyfd()Claudio Jeker
fails -- which should never happen -- the function does not return and is accession the NULL set control pointer later on. Found by Matthew Haub. OK deraadt@
2008-12-17sort;Jason McIntyre
2008-12-17Add support for demotion counter.Michele Marchetto
When interfaces go up/down the demotion counter of the specified group is decreased/increased. ok henning@
2008-11-23Fix two error messages.Michele Marchetto
2008-10-17bring in the findeol() fix from pfctl. list of affected parsers by sthenHenning Brauer
2008-08-05Do not advertise the default route with wrong metric of 0. Set it to 1Claudio Jeker
by default. Reminded to commit this brad@, OK deraadt@
2008-05-12Error out with usage line if additional arguments are given after thePierre-Yves Ritschard
option parsing. Found out the hard way by jdixon on ifstated. ok sobrado@, jdixon@, millert@
2008-05-09prio RTP_RIP for inserted routesHenning Brauer
2008-04-13Use arc4random_buf() when requesting more than a single word of outputDamien Miller
Use arc4random_uniform() when the desired random number upper bound is not a power of two ok deraadt@ millert@
2008-03-24msg_controllen has to be CMSG_SPACE so that the kernel can account forTheo de Raadt
each cmsg_len (ie. msg_controllen = sum of CMSG_ALIGN(cmsg_len). This works now that kernel fd passing has been fixed to accept a bit of sloppiness because of this ABI repair. lots of discussion with kettenis
2008-03-15Repair more msg_controllen dealing with structures or arrays ofTheo de Raadt
descriptors; ok hshoexer, also looked at by kettenis and henning
2008-03-13Correct CMSG_SPACE and CMSG_LEN usage everywhere in the tree. Due toTheo de Raadt
an extensive discussion with otto, kettenis, millert, and hshoexer
2008-02-27Unbreak parser by initializing topfile correctly.Marco Pfatschbacher
I got fooled by patch(1). Sorry.
2008-02-26Have popfile() also close the main config file,Marco Pfatschbacher
but only do the final popfile call after yyparse() is done. This also fixes config reload on SIGHUP for some daemons. Spotted by otto@. OK deraadt@
2008-01-31use a hyphen for "interface-specific" as a compound term. this isJason McIntyre
not a hard and fast rule (actually it's a form i abuse) but hostname.if.5 currently uses two conflicting forms and this keeps it consistent;
2008-01-31do not leak confd on malloc failure in control_accept()Henning Brauer
found by Igor Zinovik <zinovik@cs.karelia.ru>
2007-11-12Remove space/tab compression function from lgetc() and replaceMarco Pfatschbacher
it with a simple filter in the yylex() loop. The compression in lgetc() didn't happen for quoted strings, thus creating a regression when tabs were used in variables. Some testing by todd@ and pyr@ OK deraadt@
2007-10-24Make the packet buffer u_int8_t * everywhere. This is binary data and notClaudio Jeker
a string.
2007-10-24The metric is a 8bit value ranging from 1 to INFINITY (defined as a whoppingClaudio Jeker
16). So use u_int8_t everywhere.
2007-10-24An u_int8_t is enough as prefixlen. Another lint warning gone.Claudio Jeker
2007-10-24Document -D. Stolen from bgpd.8Claudio Jeker
2007-10-24Add the 5 needed lines to support -D makro=value option. Another surprisingClaudio Jeker
finding by lint.
2007-10-24Use an ssize_t instead of int like in all other imsg handlers. Hint by lintClaudio Jeker
2007-10-24The index should be unsigned int -- another lint findingClaudio Jeker
2007-10-24ctl_rt flags should be u_int16_t -- noticed by lintClaudio Jeker
2007-10-24Garbage collect unused stuff found by lint.Claudio Jeker
2007-10-24Sync a bit more with ospfd. Do not fatal if one of the pipes is closed,Claudio Jeker
instead do a "nice" shutdown. Ignore SIGHUP in the childs even though we have no reload support (yet). Remove some redundant code and clean up some types.
2007-10-24Don't use inet_ntoa() twice in a printf like function. So instead ofClaudio Jeker
using inet_ntoa() on the netmask use mask2prefixlen().
2007-10-20Sync parse.y with recent enhancements in hoststated.Pierre-Yves Ritschard
Fix behavior when running -n. henning@
2007-10-18spacingTheo de Raadt
2007-10-18Massive cleanup in the authentication code. the simple auth_key and the cryptClaudio Jeker
keys are not strings so a) use u_int8_t instead of char and b) uses memcpy to copy the full MAX_SIMPLE_AUTH_LEN resp. MD5_DIGEST_LENGTH bytes around. The parser needs some special code to ensure that the string is not to long and if it is shorter then the buffer the rest needs to be zero padded. Avoid to use strncpy() instead use a bzero(); memcpy() combo. with and OK deraadt@
2007-10-18Add missing bits for auth crypt and cleanup a bit. OK deraadt@Claudio Jeker
2007-10-17wrong type for digest; ok claudioTheo de Raadt
2007-10-17Add missing RTM_VERSION checks.Claudio Jeker