summaryrefslogtreecommitdiff
path: root/usr.sbin/eigrpd
AgeCommit message (Collapse)Author
14 hoursConvert simple stuff in usr.sbin over to new imsgbuf_init behaviourClaudio Jeker
OK tb@
14 hoursConvert the common imsgbuf_read calls to the post EAGAIN world.Claudio Jeker
OK tb@
14 hoursUse imsgbuf_queuelen() instead of accessing the w.queue member.Claudio Jeker
OK tb@
14 hoursUse imsgbuf_clear() where appropriate instead of msgbuf_clear().Claudio Jeker
OK tb@
14 hoursRename imsg_init, imsg_clear, imsg_read, imsg_write and imsg_flush toClaudio Jeker
imsgbuf_init, imsgbuf_clear, imsgbuf_read, imsgbuf_write and imsgbuf_flush. This separates the imsgbuf API from the per-imsg API. OK tb@
14 hoursConvert imsg_write() callers to the new simplified return logic.Claudio Jeker
OK tb@
14 hoursIntroduce imsg_write() and use it instead of msgbuf_write().Claudio Jeker
imsg_write() is just a thin wrapper around msgbuf_write(). So this is mostly search and replace. OK tb@
2024-08-22inet_pton returns 0 and -1 for error.Florian Obser
Adjust the error check that is now wrong after the inet_aton -> inet_pton conversion. Noticed by & OK bluhm. OK tb
2024-08-21We can fully spell out IP addresses in config files.Florian Obser
OK claudio
2023-12-14Use imsg_get_fd() to access the file descriptor passed in the imsg.Claudio Jeker
OK tb@
2023-12-14Rewrite send_packet to update the eigrp header without using ibuf_seek.Claudio Jeker
There is a long term goal to remove ibuf_seek from the public ibuf API since the function is a bit tricky to use. OK tb@
2023-07-03Use ibuf_data() and ibuf_size() instead of accessing struct ibuf.Claudio Jeker
OK tb@
2023-06-26Start using the new ibuf API in eigrpd. One ibuf_seek() still left sinceClaudio Jeker
the change is not trivial and I don't have a eigrp testbed. OK tb@
2023-04-19remove duplicate includesJonathan Gray
2023-03-08Delete obsolete /* ARGSUSED */ lint comments.Philip Guenther
ok miod@ millert@
2023-03-02improve the Nd lines such that the format is consistent for theJason McIntyre
various *d, *conf, *ctl files (where relevant) and simple; also makes "man -k routing" more useful; help from claudio and florian ok claudio florian millert
2022-12-28spelling fixes; from paul tagliamonteJason McIntyre
any parts of his diff not taken are noted on tech
2022-05-06Relax the limitation of what is an acceptable unicast IP.Claudio Jeker
Remove the IN_BADCLASS() check which filters out the experimental IPv4 address space. Now there are no more experiments in IPv4 and so there is less reason for these network daemons to deny such an IP. Everything still disallows multicast IPs (224/4) and loopback (127/8) a few also disallow 0/8 but this is not consistent. In any case using 240/4 in production is a really bad idea but it is not up to this software to prevent you from being a fool. OK deraadt@ tb@
2022-01-20eigrpd: fix -Wunused-but-set-variable warningChristian Weisgerber
ok guenther@
2021-12-13including sys/cdefs.h manually started as a result of netbsd trying toTheo de Raadt
macro-build a replacement for sccsid, and was done without any concern for namespace damage. Unfortunately this practice started infecting other code as others were unaware they didn't need the file. ok millert guenther
2021-11-03use some sizeof, rather than INADDRSZ/IN6ADDRSZ; ok claudioTheo de Raadt
2021-10-15Don't declare variables as "unsigned char *" that are passed toChristian Weisgerber
functions that take "char *" arguments. Where such chars are assigned to int or passed to ctype functions, explicitly cast them to unsigned char. For OpenBSD's clang, -Wpointer-sign has been disabled by default, but when the parse.y code was built elsewhere, the compiler would complain. With help from millert@ ok benno@ deraadt@
2021-01-19Like dvrmpd there is no need for a static pkt buffer. Adjust code accordingly.Claudio Jeker
2021-01-19Kill global eigrpd_process and instead pass the proc to merge_config()Claudio Jeker
and config_clear(). Also set log_procname directly and remove the log_procnames array.
2021-01-19Use log_procname instead of log_procnames[eigrpd_process]. It should beClaudio Jeker
the same thing.
2021-01-19Same control cleanup that was done for ospfd and ripd. Move theClaudio Jeker
control_state and ctl_conns structs into control.c nothing else uses these structs.
2021-01-19Like in ospfd use a static pkt_ptr bufferClaudio Jeker
2020-12-30getifaddrs() can return entries where ifa_addr is NULL. Check for thisSebastian Benoit
before accessing anything in ifa_addr. ok claudio@
2020-05-16list example files in FILES with a short description: generally, "ExampleJason McIntyre
configuration file.", but occasionally something else fit better; at the same time, try to make the format for FILES more consistent; original diff from clematis
2020-04-23 ce examples of "Ar arg Ar arg" with "Ar arg arg" and stop the spread;Jason McIntyre
2020-02-10briefly mention /etc/examples/ in the FILES section of all theIngo Schwarze
manual pages that document the corresponding configuration files; OK jmc@, and general direction discussed with many
2019-11-10Consistently use _rcctl enable foo_ in examples, it's simpler and lessLandry Breuil
error prone than manually editing rc.conf.local, and also works to enable ipsec and accounting. tweak from schwarze@ to use the \(dq\(dq syntax for quotes in '.Dl foo_flags="" lines' instead of \&"\&". while at it, fix a reference to a bogus /dev/dhclient.conf file that recently snuck in. ok jmc@ deraadt@ schwarze@
2019-06-28When system calls indicate an error they return -1, not some arbitraryTheo de Raadt
value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
2019-03-31Avoid calling dup2(oldd, newd) when oldd == newd. In that case theYASUOKA Masahiko
descriptor keeps CLOEXEC flag then it will be closed unexpectedly by exec(). ok tedu florian
2019-02-13(unsigned) means (unsigned int) which on ptrdiff_t or size_t or otherTheo de Raadt
larger types really is a range reduction... Almost any cast to (unsigned) is a bug. ok millert tb benno
2018-12-07Be more strict in converting a netmask into a prefixlen. Make sureClaudio Jeker
the prefixlen is never bigger than 128 for inet6. OK remi@
2018-11-01- odd condition/test in PF lexerAlexandr Nedvedicky
(and other lexers too) This commit rectifies earlier change: in the lex... even inside quotes, a \ followed by space or tab should expand to space or tab, and a \ followed by newline should be ignored (as a line continuation). compatible with the needs of hoststated (which has the most strict quoted string requirements), and ifstated (where one commonly does line continuations in strings). OK deraadt@, OK millert@
2018-09-26Fix use-after-free by moving the free(3) of the configured interfaces to afterRicardo Mestre
the eigrp instances on shutdown. tried to contact renato@ but he didn't answer in almost 2 months OK benno@ claudio@
2018-09-07replace malloc()+strlcpy() with strndup() in cmdline_symset().miko
"looks good" gilles@ halex@
2018-08-05Remove now unused header which I forgot to commit on previous.Ricardo Mestre
2018-08-05Revert back previous and remove cpath pledge(2) promise entirely. We decidedRicardo Mestre
that not deleting the unix control sockets cause no harm and this way we close another attack surface by not allowing the daemon to create/delete any more files. tweak and OK florian@
2018-08-02Actually order the promises in their canonical form, missed that in myRicardo Mestre
previous commit. heads up and OK tb@
2018-08-02Currently when eigrpd(8) shuts down then its unix control socket is beingRicardo Mestre
unlink(2)ed from eigrpe engine process, the problem is that this proc is chrooted and therefore the socket will never be deleted. In order to solve it we need to bring control_cleanup() function, which calls unlink(2), into the main proc which is not chrooted. This is the way it's already done for several other daemons we have in our base. Additionally we also need to move the "cpath" pledge(2) promise from the child process to the main process in order for the latter to be allowed to delete the socket and while here shuffle the promises into their canonical form. OK florian@ and benno@
2018-07-11Do for most running out of memory err() what was done for most runningKenneth R Westerback
out of memory log_warn(). i.e. ("%s", __func__) instead of manual function names and redundant verbiage about which wrapper detected the out of memory condition. ok henning@
2018-07-10"%%s: s" -> "%s: %s" in log_warn()Kenneth R Westerback
2018-07-09No need to mention which memory allocation entry point failed (malloc,Kenneth R Westerback
calloc or strdup), we just need to log that we ran out of memory in a particular function. Recommended by florian@ and deraadt@ ok benno@ henning@ tb@
2018-06-18remove the SECTIONS header, since a one line DESCRIPTION is a bit silly;Jason McIntyre
use a more general text for the sections, and avoid the catchup issue that was trying to document how many there were; ok benno rob
2018-06-11Fix an off-by-one line count when using include statements.denis
Thanks to otto@ for the initial diff. OK benno@
2018-04-26Plug leak in error case of the common 'varset' implementations.Kenneth R Westerback
ok benno@
2018-02-08Bump the read sockbuf of the routing socket to 2MB, may help reduce some ofClaudio Jeker
the desync cases. OK benno@