OpenBSD CVS

CVS log for src/usr.sbin/rad/engine.c


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

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.22 / (download) - annotate - [select for diffs], Thu Dec 14 11:09:34 2023 UTC (5 months, 3 weeks ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, HEAD
Changes since 1.21: +2 -2 lines
Diff to previous 1.21 (colored)

Use imsg_get_fd() to access the file descriptor passed in the imsg.
OK tb@

Revision 1.21 / (download) - annotate - [select for diffs], Sat Oct 15 13:26:15 2022 UTC (19 months, 3 weeks ago) by florian
Branch: MAIN
CVS Tags: OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3
Changes since 1.20: +16 -1 lines
Diff to previous 1.20 (colored)

Implement RFC 8781 PREF64 router advertisement option.

With this clients can learn the presence and used prefix for Network
Address and Protocol Translation between IPv6 and IPv4 (NAT64).

Apparently there is support in mobile devices as well as in macOS.

This option, together with the the dhcp "IPv6-only preferred"
option (108) enables the Customer-side transLATor (CLAT) on macOS so
IPv4 literals can be used in IPv6-only networks.

Input & OK kn

Revision 1.20 / (download) - annotate - [select for diffs], Wed Mar 23 15:26:08 2022 UTC (2 years, 2 months ago) by florian
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1
Changes since 1.19: +42 -9 lines
Diff to previous 1.19 (colored)

Rate limit router advertisements according to RFC 4861 6.2.6. In
particular make sure to send at most one multicast advertisement every
three seconds.
input & OK deraadt

Revision 1.19 / (download) - annotate - [select for diffs], Thu May 13 11:22:15 2021 UTC (3 years ago) by florian
Branch: MAIN
CVS Tags: OPENBSD_7_0_BASE, OPENBSD_7_0
Changes since 1.18: +4 -3 lines
Diff to previous 1.18 (colored)

RFC 4861 4.1 allows router solicitations from the unspecified address
(::). A short survey suggests that some systems respond with a
multicast router advertisement and other don't.

Andrew Forgue pointed out a usecase for this, booting a UEFI system
over http in an IPv6 network only. ("IPv6 support for UEFI IPv6
booting" on bugs@ a long time ago)

There is also no downside in allowing this, any host on the layer 2
network can solicit a router advertisement.

OK phessler

Revision 1.18 / (download) - annotate - [select for diffs], Tue Jan 19 16:54:48 2021 UTC (3 years, 4 months ago) by florian
Branch: MAIN
CVS Tags: OPENBSD_6_9_BASE, OPENBSD_6_9
Changes since 1.17: +4 -4 lines
Diff to previous 1.17 (colored)

Make imsg event structs static to fix -fno-common.
Follows claudio's lead in ospfd et al.
Problem reported by mortimer.

Revision 1.17 / (download) - annotate - [select for diffs], Tue Jan 19 16:53:27 2021 UTC (3 years, 4 months ago) by florian
Branch: MAIN
Changes since 1.16: +3 -4 lines
Diff to previous 1.16 (colored)

No need for a global rad_process; unbreaks -fno-common.
Problem reported by mortimer

Revision 1.16 / (download) - annotate - [select for diffs], Wed May 20 10:37:02 2020 UTC (4 years ago) by claudio
Branch: MAIN
CVS Tags: OPENBSD_6_8_BASE, OPENBSD_6_8
Changes since 1.15: +3 -2 lines
Diff to previous 1.15 (colored)

Include interface name in warning when a RA is recieved from a non-link-local
address
OK sthen@ florian@ benno@

Revision 1.15 / (download) - annotate - [select for diffs], Fri Mar 15 16:47:19 2019 UTC (5 years, 2 months ago) by florian
Branch: MAIN
CVS Tags: OPENBSD_6_7_BASE, OPENBSD_6_7, OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5
Changes since 1.14: +7 -1 lines
Diff to previous 1.14 (colored)

Correctly interlock config reloads imsgs.
Only accept a new config reload if it's not currently running and
on accept a config reload end if one is currently running.
OK pamela

Revision 1.14 / (download) - annotate - [select for diffs], Tue Mar 12 19:40:01 2019 UTC (5 years, 2 months ago) by pamela
Branch: MAIN
Changes since 1.13: +3 -2 lines
Diff to previous 1.13 (colored)

fix line break
OK florian@

Revision 1.13 / (download) - annotate - [select for diffs], Tue Mar 12 18:47:57 2019 UTC (5 years, 2 months ago) by pamela
Branch: MAIN
Changes since 1.12: +33 -10 lines
Diff to previous 1.12 (colored)

In the manner of recent changes to unwind(8) and slaacd(8), make imsg
processing more paranoid. Call fatalx() for imsg size mismatches or
unexpected/missing imsg fd.
OK florian@

Revision 1.12 / (download) - annotate - [select for diffs], Mon Mar 11 16:03:20 2019 UTC (5 years, 3 months ago) by pamela
Branch: MAIN
Changes since 1.11: +4 -4 lines
Diff to previous 1.11 (colored)

Change fatal() to fatalx() where errno is not set.
tweak and OK florian@

Revision 1.11 / (download) - annotate - [select for diffs], Sat Mar 2 03:40:45 2019 UTC (5 years, 3 months ago) by pamela
Branch: MAIN
Changes since 1.10: +10 -10 lines
Diff to previous 1.10 (colored)

Introduce the IMSG_DATA_SIZE() macro to replace recurring math on imsg.hdr.len to shorten and simplify code.
OK florian@

Revision 1.10 / (download) - annotate - [select for diffs], Tue Jan 29 15:43:33 2019 UTC (5 years, 4 months ago) by florian
Branch: MAIN
Changes since 1.9: +1 -4 lines
Diff to previous 1.9 (colored)

We don't need IMSG_SHUTDOWN, we can just close the sockets.
pointed out by deraadt

Revision 1.9 / (download) - annotate - [select for diffs], Fri Aug 3 13:14:46 2018 UTC (5 years, 10 months ago) by florian
Branch: MAIN
CVS Tags: OPENBSD_6_4_BASE, OPENBSD_6_4
Changes since 1.8: +10 -5 lines
Diff to previous 1.8 (colored)

Move dns settings to global options so that they don't need to be
repeated in every interface block - they can still be overwritten
on a per interface basis.
Pointed out by, tweaks & OK sthen

Revision 1.8 / (download) - annotate - [select for diffs], Fri Jul 20 20:35:00 2018 UTC (5 years, 10 months ago) by florian
Branch: MAIN
Changes since 1.7: +1 -4 lines
Diff to previous 1.7 (colored)

No need to copy rdns_lifetime around with an IMSG, it gets send to the
engine end frontend as part of ra_iface_conf.

Spotted after explaining to bket@ that a similar pattern is not needed
for the mtu option.

Revision 1.7 / (download) - annotate - [select for diffs], Sun Jul 15 09:28:21 2018 UTC (5 years, 10 months ago) by florian
Branch: MAIN
Changes since 1.6: +26 -4 lines
Diff to previous 1.6 (colored)

Implement RFC 8106: IPv6 Router Advertisement Options for DNS
Configuration.

Revision 1.6 / (download) - annotate - [select for diffs], Wed Jul 11 19:05:25 2018 UTC (5 years, 10 months ago) by florian
Branch: MAIN
Changes since 1.5: +4 -1 lines
Diff to previous 1.5 (colored)

cleanly shutdown by sending advertisement with lifetime 0

Revision 1.5 / (download) - annotate - [select for diffs], Wed Jul 11 17:32:05 2018 UTC (5 years, 10 months ago) by florian
Branch: MAIN
Changes since 1.4: +42 -4 lines
Diff to previous 1.4 (colored)

Send a RA with router lifetime of 0 when an interface is removed from
the config.

RFC 4861, 6.2.5:
[...] the router SHOULD transmit one or more (but not more than
MAX_FINAL_RTR_ADVERTISEMENTS) final multicast Router Advertisements on
the interface with a Router Lifetime field of zero.

Revision 1.4 / (download) - annotate - [select for diffs], Wed Jul 11 14:03:13 2018 UTC (5 years, 10 months ago) by florian
Branch: MAIN
Changes since 1.3: +82 -8 lines
Diff to previous 1.3 (colored)

Detect when a router advertisement packet changes due to config
change and if it does send a new advertisement.

The way this is implemented gives us various things for free:
- periodic sending of router advertisements
- send initial advertisement for every interface on startup

Revision 1.3 / (download) - annotate - [select for diffs], Tue Jul 10 22:14:19 2018 UTC (5 years, 11 months ago) by florian
Branch: MAIN
Changes since 1.2: +1 -35 lines
Diff to previous 1.2 (colored)

remove newd control leftovers

Revision 1.2 / (download) - annotate - [select for diffs], Tue Jul 10 22:13:16 2018 UTC (5 years, 11 months ago) by florian
Branch: MAIN
Changes since 1.1: +1 -2 lines
Diff to previous 1.1 (colored)

remove unused variable; pointed out by llvm

Revision 1.1 / (download) - annotate - [select for diffs], Tue Jul 10 16:39:54 2018 UTC (5 years, 11 months ago) by florian
Branch: MAIN

Import rad(8).
It's a Router Advertisement Daemon written using the standard 3
process privsep pattern and a parse.y based config file.
Commit early to continue work in tree.
OK jca
"it's totally rad" phessler@
"usr.sbin never runs out of space" deraadt@

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.