OpenBSD CVS

CVS log for src/usr.sbin/ripd/ripe.c


[BACK] Up to [local] / src / usr.sbin / ripd

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.31 / (download) - annotate - [select for diffs], Wed Mar 8 04:43:15 2023 UTC (15 months ago) by guenther
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, HEAD
Changes since 1.30: +1 -4 lines
Diff to previous 1.30 (colored)

Delete obsolete /* ARGSUSED */ lint comments.

ok miod@ millert@

Revision 1.30 / (download) - annotate - [select for diffs], Tue Jan 19 10:20:47 2021 UTC (3 years, 4 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9
Changes since 1.29: +3 -3 lines
Diff to previous 1.29 (colored)

Make the struct imsgev structs static and with that ripd -fno-common clean.

Revision 1.29 / (download) - annotate - [select for diffs], Tue Jan 19 10:18:56 2021 UTC (3 years, 4 months ago) by claudio
Branch: MAIN
Changes since 1.28: +2 -3 lines
Diff to previous 1.28 (colored)

Remove the PROC_* enums and ripd_process, they are no longer needed.
Instead assign the process name directly to log_procname which was
the last user of ripd_process.

Revision 1.28 / (download) - annotate - [select for diffs], Tue Jan 19 10:09:59 2021 UTC (3 years, 4 months ago) by claudio
Branch: MAIN
Changes since 1.27: +7 -3 lines
Diff to previous 1.27 (colored)

Move the interface demote out of if_del and into the only place where
it is needed (the if_del call in ripe.c). With this the ripd_process
check in ripe_demote_iface() can be removed.

Revision 1.27 / (download) - annotate - [select for diffs], Tue Jan 19 10:02:22 2021 UTC (3 years, 4 months ago) by claudio
Branch: MAIN
Changes since 1.26: +1 -5 lines
Diff to previous 1.26 (colored)

Like in ospfd make the pkt_ptr a local static buffer.

Revision 1.26 / (download) - annotate - [select for diffs], Tue Jan 19 10:00:36 2021 UTC (3 years, 4 months ago) by claudio
Branch: MAIN
Changes since 1.25: +1 -2 lines
Diff to previous 1.25 (colored)

Apply same cleanup to the control code as in ospfd.
Internalize control_state and ctl_conns.

Revision 1.25 / (download) - annotate - [select for diffs], Wed Dec 11 21:04:59 2019 UTC (4 years, 5 months ago) by remi
Branch: MAIN
CVS Tags: OPENBSD_6_8_BASE, OPENBSD_6_8, OPENBSD_6_7_BASE, OPENBSD_6_7
Changes since 1.24: +3 -1 lines
Diff to previous 1.24 (colored)

Fix 2 memory leaks in error paths and a double-free (kroute_insert already
frees kr if it detects a duplicate).

From Hiltjo Posthuma
OK benno@

Revision 1.24 / (download) - annotate - [select for diffs], Mon Dec 9 20:37:54 2019 UTC (4 years, 6 months ago) by remi
Branch: MAIN
Changes since 1.23: +1 -2 lines
Diff to previous 1.23 (colored)

iface is not used afterwards. It should have been removed in rev. 1.8.

OK claudio@

Revision 1.23 / (download) - annotate - [select for diffs], Sun Nov 4 07:52:55 2018 UTC (5 years, 7 months ago) by remi
Branch: MAIN
CVS Tags: OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5
Changes since 1.22: +4 -1 lines
Diff to previous 1.22 (colored)

Pledge ripe and rde.
Use unveil to remove file system access for the parent proc.

Also remove control_cleanup as discussed on tech@. It allows to fully remove
fs access (ripd does not support reload). It's not an issue for ripd and
ripctrl if an unused socket file is lying around.

reads OK for claudio@ and mestre@

Revision 1.22 / (download) - annotate - [select for diffs], Sat Sep 3 10:28:08 2016 UTC (7 years, 9 months ago) by renato
Branch: MAIN
CVS Tags: OPENBSD_6_4_BASE, OPENBSD_6_4, OPENBSD_6_3_BASE, OPENBSD_6_3, OPENBSD_6_2_BASE, OPENBSD_6_2, OPENBSD_6_1_BASE, OPENBSD_6_1
Changes since 1.21: +11 -7 lines
Diff to previous 1.21 (colored)

Simplify shutdown process.

On shutdown, there's no need to use kill(2) to kill the child
processes. Just closing the IPC sockets will make the children receive
an EOF, break out from the event loop and then exit.

Tha advantages of this "pipe teardown" are:
* simpler code;
* no need to pledge "proc" in the parent process;
* removal of a (hard to trigger) PID reuse race condition.

ok benno@ claudio@

Revision 1.21 / (download) - annotate - [select for diffs], Fri Sep 2 14:07:52 2016 UTC (7 years, 9 months ago) by benno
Branch: MAIN
Changes since 1.20: +2 -1 lines
Diff to previous 1.20 (colored)

work on making log.c similar in all daemons:

move daemon-local functions into new logmsg.c, and reduce
the (mostly whitespace) differences so that log.c's can be diffed easily.

ok claudio@, feedback from henning@, deraadt@, reyk@

Revision 1.20 / (download) - annotate - [select for diffs], Tue Aug 2 16:05:32 2016 UTC (7 years, 10 months ago) by jca
Branch: MAIN
Changes since 1.19: +2 -2 lines
Diff to previous 1.19 (colored)

Allow specifying an alternate socket path.

This allows one to run multiple ripd instances, for example to serve
multiple rdomains.  Diff from Nima GHOTBI, ok claudio@ florian@ benno@

Revision 1.19 / (download) - annotate - [select for diffs], Sat Dec 5 13:13:47 2015 UTC (8 years, 6 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE, OPENBSD_6_0, OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.18: +5 -5 lines
Diff to previous 1.18 (colored)

EAGAIN handling for imsg_read. OK henning@ benno@

Revision 1.18 / (download) - annotate - [select for diffs], Mon Feb 9 12:34:07 2015 UTC (9 years, 4 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8, OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.17: +3 -2 lines
Diff to previous 1.17 (colored)

Add SOCK_CLOEXEC | SOCK_NONBLOCK to two more socket calls.

Revision 1.17 / (download) - annotate - [select for diffs], Tue Nov 18 20:54:29 2014 UTC (9 years, 6 months ago) by krw
Branch: MAIN
Changes since 1.16: +1 -2 lines
Diff to previous 1.16 (colored)

Nuke more obvious #include duplications.

ok deraadt@ millert@ tedu@

Revision 1.16 / (download) - annotate - [select for diffs], Sat Jul 12 20:16:38 2014 UTC (9 years, 10 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.15: +7 -3 lines
Diff to previous 1.15 (colored)

Close connections when msgbuf_write() returns 0.

ok claudio@

Revision 1.15 / (download) - annotate - [select for diffs], Tue Nov 26 12:00:19 2013 UTC (10 years, 6 months ago) by henning
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5
Changes since 1.14: +3 -3 lines
Diff to previous 1.14 (colored)

msgbuf_write EAGAIN, ok gilles benno

Revision 1.14 / (download) - annotate - [select for diffs], Mon Jul 4 04:34:14 2011 UTC (12 years, 11 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_5_4_BASE, OPENBSD_5_4, OPENBSD_5_3_BASE, OPENBSD_5_3, OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1, OPENBSD_5_0_BASE, OPENBSD_5_0
Changes since 1.13: +2 -4 lines
Diff to previous 1.13 (colored)

LINK_STATE_IS_UP() cleanup userland part. There is no need to special
case carp(4) interfaces anymore. LINK_STATE_IS_UP() almost always does
the right job.
OK deraadt@ henning@

This needs a -current kernel or link state may be not reported correctly.

Revision 1.13 / (download) - annotate - [select for diffs], Wed May 26 13:56:08 2010 UTC (14 years ago) by nicm
Branch: MAIN
CVS Tags: OPENBSD_4_9_BASE, OPENBSD_4_9, OPENBSD_4_8_BASE, OPENBSD_4_8
Changes since 1.12: +2 -2 lines
Diff to previous 1.12 (colored)

Rename some imsg bits to make namespace collisions less likely buf to
ibuf, buf_read to ibuf_read, READ_BUF_SIZE to IBUF_READ_SIZE.

ok henning gilles claudio jacekm deraadt

Revision 1.12 / (download) - annotate - [select for diffs], Sat Jun 6 08:20:55 2009 UTC (15 years ago) by eric
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE, OPENBSD_4_7, OPENBSD_4_6_BASE, OPENBSD_4_6
Changes since 1.11: +40 -35 lines
Diff to previous 1.11 (colored)

make ripctl/ripd imsg-in-a-lib ready too.

ok pyr@

Revision 1.11 / (download) - annotate - [select for diffs], Sun May 31 20:30:15 2009 UTC (15 years ago) by jacekm
Branch: MAIN
Changes since 1.10: +1 -3 lines
Diff to previous 1.10 (colored)

Remove redundant imsg_event_add calls; ok claudio@

Revision 1.10 / (download) - annotate - [select for diffs], Sun May 31 17:06:01 2009 UTC (15 years ago) by claudio
Branch: MAIN
Changes since 1.9: +7 -15 lines
Diff to previous 1.9 (colored)

Better EV_READ and EV_WRITE handling in the libevent callbacks. Again mostly
the same ospfd diff applied with some fuzz.

Revision 1.9 / (download) - annotate - [select for diffs], Wed Mar 25 12:48:16 2009 UTC (15 years, 2 months ago) by michele
Branch: MAIN
Changes since 1.8: +6 -15 lines
Diff to previous 1.8 (colored)

With redistribute connected set, announce the prefix on the interface
with address belonging to that prefix. Don't skip it.

ok claudio@

Revision 1.8 / (download) - annotate - [select for diffs], Wed Dec 17 14:19:39 2008 UTC (15 years, 5 months ago) by michele
Branch: MAIN
CVS Tags: OPENBSD_4_5_BASE, OPENBSD_4_5
Changes since 1.7: +21 -1 lines
Diff to previous 1.7 (colored)

Add support for demotion counter.
When interfaces go up/down the demotion counter of the
specified group is decreased/increased.

ok henning@

Revision 1.7 / (download) - annotate - [select for diffs], Sun Nov 23 13:09:31 2008 UTC (15 years, 6 months ago) by michele
Branch: MAIN
Changes since 1.6: +3 -3 lines
Diff to previous 1.6 (colored)

Fix two error messages.

Revision 1.6 / (download) - annotate - [select for diffs], Wed Oct 24 19:05:06 2007 UTC (16 years, 7 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_4_4_BASE, OPENBSD_4_4, OPENBSD_4_3_BASE, OPENBSD_4_3
Changes since 1.5: +22 -8 lines
Diff to previous 1.5 (colored)

Sync a bit more with ospfd. Do not fatal if one of the pipes is closed,
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.

Revision 1.5 / (download) - annotate - [select for diffs], Mon Jan 8 13:01:10 2007 UTC (17 years, 5 months ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_4_2_BASE, OPENBSD_4_2, OPENBSD_4_1_BASE, OPENBSD_4_1
Changes since 1.4: +10 -3 lines
Diff to previous 1.4 (colored)

New redistribute code adapted from ospfd. It is now possible to do the same
redistribute setups as in ospfd (rtlables, per prefix, negation).
Tested, input and OK michele@

Revision 1.4 / (download) - annotate - [select for diffs], Tue Nov 28 19:21:16 2006 UTC (17 years, 6 months ago) by reyk
Branch: MAIN
Changes since 1.3: +2 -2 lines
Diff to previous 1.3 (colored)

add additional link states to report the half duplex / full duplex
state, if known by the driver. this is required to check the full
duplex state without depending on the ifmedia ioctl which can't be
called in the kernel without process context.

ok henning@, brad@

Revision 1.3 / (download) - annotate - [select for diffs], Tue Oct 31 23:43:11 2006 UTC (17 years, 7 months ago) by michele
Branch: MAIN
Changes since 1.2: +2 -1 lines
Diff to previous 1.2 (colored)

create a temporary neighbor instead of a permanent one when a request is received

Revision 1.2 / (download) - annotate - [select for diffs], Thu Oct 19 12:29:58 2006 UTC (17 years, 7 months ago) by mcbride
Branch: MAIN
Changes since 1.1: +3 -2 lines
Diff to previous 1.1 (colored)

Correct function name in log_debug() messages

Revision 1.1 / (download) - annotate - [select for diffs], Wed Oct 18 16:11:58 2006 UTC (17 years, 7 months ago) by norby
Branch: MAIN

Welcome ripd
started by Michele Marchetto some time ago by using the imsg/three process framework
of ospfd. He implemented most of the daemon with a little help and guidance from
Claudio and I.

Currently the daemon is more or less complete, with the exception of key lifetime
and rollover.

Not yet connected to the builds.
OK claudio@

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.