OpenBSD CVS

CVS log for src/etc/netstart


[BACK] Up to [local] / src / etc

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.234 / (download) - annotate - [select for diffs], Sun Dec 18 15:52:52 2022 UTC (16 months, 4 weeks ago) by kn
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.233: +3 -3 lines
Diff to previous 1.233 (colored)

Revert previous as it doesn't create additional lo(4) anymore

Reported by Andreas Bartelt on bugs@

Revision 1.233 / (download) - annotate - [select for diffs], Sun Dec 18 05:51:14 2022 UTC (16 months, 4 weeks ago) by kn
Branch: MAIN
Changes since 1.232: +3 -3 lines
Diff to previous 1.232 (colored)

Do not try to create physical interfaces

vifscreate() always creates all virtual interfaces up-front.

To check whether a given interface exists, ifstart() uses ifcreate()
which tries to create nonexistent ones.

Virtual ones are guaranteed to be present and physical ones cannot be
created, so replace the ifcreate() call with a simpler ifconfig test and
clarify the comment.

OK martijn afresh1

Revision 1.232 / (download) - annotate - [select for diffs], Fri Dec 16 17:57:39 2022 UTC (17 months ago) by kn
Branch: MAIN
Changes since 1.231: +2 -2 lines
Diff to previous 1.231 (colored)

zap double space and needless line break

Revision 1.231 / (download) - annotate - [select for diffs], Fri Dec 16 04:04:25 2022 UTC (17 months ago) by afresh1
Branch: MAIN
Changes since 1.230: +20 -15 lines
Diff to previous 1.230 (colored)

Prioritize lladdr over name/unit in hostname.if processing

When needed, lladdr is more precise and enduring.

Suggested by deraadt@
Many improvments and OK kn@

Revision 1.230 / (download) - annotate - [select for diffs], Mon Dec 5 20:12:00 2022 UTC (17 months, 1 week ago) by afresh1
Branch: MAIN
Changes since 1.229: +24 -6 lines
Diff to previous 1.229 (colored)

Add support configuring hostname.if(5) by lladdr

Original implementation by martijn@
Feedback and suggestions from kn@, sthen@, claudio@, florian@, and deraadt@.

ok deraadt

Revision 1.229 / (download) - annotate - [select for diffs], Sat Nov 5 12:06:05 2022 UTC (18 months, 1 week ago) by kn
Branch: MAIN
Changes since 1.228: +2 -2 lines
Diff to previous 1.228 (colored)

"need root privileges" is an error, print it on stderr"

Revision 1.228 / (download) - annotate - [select for diffs], Sat Nov 5 12:03:58 2022 UTC (18 months, 1 week ago) by kn
Branch: MAIN
Changes since 1.227: +2 -2 lines
Diff to previous 1.227 (colored)

Print full path in usage; OK jmc

Revision 1.227 / (download) - annotate - [select for diffs], Tue Nov 1 11:18:06 2022 UTC (18 months, 2 weeks ago) by kn
Branch: MAIN
Changes since 1.226: +5 -3 lines
Diff to previous 1.226 (colored)

Only load the SOII key if IPv6 is available

Possible now that IP6KERNERL is hoisted.
This also improves readability and zaps double negation logic.

Revision 1.226 / (download) - annotate - [select for diffs], Tue Nov 1 10:45:53 2022 UTC (18 months, 2 weeks ago) by kn
Branch: MAIN
Changes since 1.225: +15 -9 lines
Diff to previous 1.225 (colored)

Do not wait for DAD completion in dry-run mode

1. only do so when running without -n
2. move code to own wait_dad() helper like wait_autoconf_default() has it
3. use local _count as usual in both functions rather than the global count

Feedback OK claudio

Revision 1.225 / (download) - annotate - [select for diffs], Mon Oct 31 20:14:45 2022 UTC (18 months, 2 weeks ago) by kn
Branch: MAIN
Changes since 1.224: +5 -2 lines
Diff to previous 1.224 (colored)

Hoist only the feature check

Keep adding IPv6 routes after lo0 got an addres like before, meant to be
committed together with r1.223.

Revision 1.224 / (download) - annotate - [select for diffs], Mon Oct 31 19:48:50 2022 UTC (18 months, 2 weeks ago) by kn
Branch: MAIN
Changes since 1.223: +2 -2 lines
Diff to previous 1.223 (colored)

Fix comment:  IPv6 link local addresses do not use SOII anymore

sys/netinet6/in6_ifattach.c r1.114 limited it to SLAAC addresses in 2019.

Revision 1.223 / (download) - annotate - [select for diffs], Mon Oct 31 19:25:16 2022 UTC (18 months, 2 weeks ago) by kn
Branch: MAIN
Changes since 1.222: +8 -10 lines
Diff to previous 1.222 (colored)

Improve shell style wrt. variable naming/boolean convention

The mixed use of upper and lower case variables is neither obvious nor
consistent.

PRINT_ONLY is local to netstart.
ip6kernel is local to netstart.
multicast gets sourced from rc.subr(8).

1. uppercase ip6kernel as is common for global variables in base scripts
2. use the simpler true/false idiom and default with the rest of
   netstart-only variables, making it clearer that only `multicast=YES/NO'
   comes from the rc environment
3. hoist kernel feature detection such that a later diff can load the SOII
   key conditionally
4. zap obvious comment

OK aja

Revision 1.222 / (download) - annotate - [select for diffs], Mon Oct 24 20:51:07 2022 UTC (18 months, 3 weeks ago) by kn
Branch: MAIN
Changes since 1.221: +2 -2 lines
Diff to previous 1.221 (colored)

do not wait for autoconf in dry-run

If there is no default route but some interface has AUTOCONF, printing
what would be done still waits for... nothing to happen.

OK tb

Revision 1.221 / (download) - annotate - [select for diffs], Mon Oct 24 17:58:43 2022 UTC (18 months, 3 weeks ago) by kn
Branch: MAIN
Changes since 1.220: +2 -2 lines
Diff to previous 1.220 (colored)

Add required sh(1) to synopsis

Contrary to other scripts in base like rc.d(8) or MAKEDEV(8), netstart(8)
itself is not executable and must be passed as file to sh(1):
	$ man -h netstart
	/etc/netstart [-n] [interface ...]
	$ /etc/netstart
	ksh: /etc/netstart: cannot execute - Permission denied

Fix usage and synopsis to provide required usage:
	$ man -h netsart
	sh /etc/netstart [-n] [interface ...]

OK jmc

Revision 1.220 / (download) - annotate - [select for diffs], Fri Oct 21 12:04:51 2022 UTC (18 months, 3 weeks ago) by kn
Branch: MAIN
Changes since 1.219: +2 -2 lines
Diff to previous 1.219 (colored)

Fix synopsis, -n does not require an interface; OK jmc

Revision 1.219 / (download) - annotate - [select for diffs], Sun Jul 3 12:14:36 2022 UTC (22 months, 2 weeks ago) by kn
Branch: MAIN
CVS Tags: OPENBSD_7_2_BASE, OPENBSD_7_2
Changes since 1.218: +22 -2 lines
Diff to previous 1.218 (colored)

Create virtual interfaces upfront if specified on the command line

In cases like `sh /etc/netstart pair1 pair2', one of hostname.pair{1,2}
will contain a "patch pair{2,1}" command which expects the other interface
to exist.

If none exist, this would fail and netstart had to be run separately or
"patch"ed interface had to be manually created before.

There are other use cases where interfaces depend on each other, so before
(re)configuring an explicit list of interfaces, create all virtual ones
upfront so that a single netstart invocation will configure everything
correctly without having reflect dependencies in multiple ordered netstart
invocations.

Copy isin() from install.sub to help.

Feedback OK halex

Revision 1.218 / (download) - annotate - [select for diffs], Sun Jun 26 09:36:13 2022 UTC (22 months, 3 weeks ago) by florian
Branch: MAIN
Changes since 1.217: +15 -1 lines
Diff to previous 1.217 (colored)

Wait for autoconf interfaces to come up in netstart(8) instead of
rc(8). This makes tunnel interfaces work that depend on working
autoconf interfaces.
OK deraadt

Revision 1.217 / (download) - annotate - [select for diffs], Tue Feb 22 06:44:40 2022 UTC (2 years, 2 months ago) by dlg
Branch: MAIN
CVS Tags: OPENBSD_7_1_BASE, OPENBSD_7_1
Changes since 1.216: +3 -3 lines
Diff to previous 1.216 (colored)

add some more tunnels to the list of interfaces that rely on routing.

Revision 1.216 / (download) - annotate - [select for diffs], Thu Sep 2 19:38:20 2021 UTC (2 years, 8 months ago) by bluhm
Branch: MAIN
CVS Tags: OPENBSD_7_0_BASE, OPENBSD_7_0
Changes since 1.215: +4 -1 lines
Diff to previous 1.215 (colored)

Do not create loopback interfaces lo1, lo2, ...  upfront.  They are
automatically set up by the kernel when a routing domain is created.
An existing lo1 in rdomain 0 would prevent to add any interfaces
in rdomain 1.
OK kn@

Revision 1.215 / (download) - annotate - [select for diffs], Mon Aug 30 16:58:52 2021 UTC (2 years, 8 months ago) by bluhm
Branch: MAIN
Changes since 1.214: +82 -51 lines
Diff to previous 1.214 (colored)

Improve dubgging in /etc/netstart.  Enable print only in ifcreate.
Add debugging output for ipv6 routes.  Make localhost and multicast
code aware of the print only switch.  Allow netstart -n to work
also if no interface is given.
OK kn@

Revision 1.214 / (download) - annotate - [select for diffs], Fri Aug 6 07:06:35 2021 UTC (2 years, 9 months ago) by sthen
Branch: MAIN
Changes since 1.213: +4 -4 lines
Diff to previous 1.213 (colored)

As tim@ spotted, a use of V4_AUTOCONF crept in when the variable name
was actually V4_DHCPCONF from previous use. Rename all of the V4_DHCPCONF
to V4_AUTOCONF so everything uses the new name. ok and reminder about
the installer from tb@

Revision 1.213 / (download) - annotate - [select for diffs], Fri Jul 16 15:21:41 2021 UTC (2 years, 10 months ago) by florian
Branch: MAIN
Changes since 1.212: +3 -16 lines
Diff to previous 1.212 (colored)

switch to dhcpleased/resolvd in base
OK deraadt

Revision 1.212 / (download) - annotate - [select for diffs], Sun Jun 20 08:31:03 2021 UTC (2 years, 10 months ago) by florian
Branch: MAIN
Changes since 1.211: +6 -1 lines
Diff to previous 1.211 (colored)

Don't try to install a default route with route(8) later on if we are
using inet autoconf, like we do with "dhcp" and "inet6 autoconf".
OK kn

Revision 1.211 / (download) - annotate - [select for diffs], Wed Dec 23 17:22:07 2020 UTC (3 years, 4 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_9_BASE, OPENBSD_6_9
Changes since 1.210: +16 -5 lines
Diff to previous 1.210 (colored)

Allow the provision of dhclient(8) options on 'dhcp' lines in hostname.if(5)
files.

Usual man page help & ok jmc@

Revision 1.210 / (download) - annotate - [select for diffs], Mon Dec 21 16:52:49 2020 UTC (3 years, 4 months ago) by krw
Branch: MAIN
Changes since 1.209: +4 -3 lines
Diff to previous 1.209 (colored)

Avoid issuing pointless 'ifconfig <if> up' when processing 'dhcp' in
hostname.if files. dhclient(8) does that itself. Part of the
"further script optimizations" promised in r1.200 of netstart.

Tested & ok gnezdo@

Revision 1.209 / (download) - annotate - [select for diffs], Sun Nov 29 20:54:33 2020 UTC (3 years, 5 months ago) by tb
Branch: MAIN
Changes since 1.208: +11 -10 lines
Diff to previous 1.208 (colored)

Fix previous: use correct version of netstart and installer bits.

Revision 1.208 / (download) - annotate - [select for diffs], Sun Nov 29 20:14:06 2020 UTC (3 years, 5 months ago) by deraadt
Branch: MAIN
Changes since 1.207: +21 -19 lines
Diff to previous 1.207 (colored)

Add support for !command to mygate, so that netstart has a late opportunity
to perform network configuration (for example, "!route source -ifp em0")
Split mygate and myname manual pages (how did anyone ever believe these
are related), and perform hostname configuration much earlier in rc.
discussed with benno, claudio, jmc, etc etc, last version of !command
parser by tb

Revision 1.207 / (download) - annotate - [select for diffs], Sun Nov 8 16:51:43 2020 UTC (3 years, 6 months ago) by jmc
Branch: MAIN
Changes since 1.206: +3 -3 lines
Diff to previous 1.206 (colored)

no more mobileip;
ok claudio deraadt

Revision 1.206 / (download) - annotate - [select for diffs], Sun Jun 21 12:28:13 2020 UTC (3 years, 10 months ago) by dlg
Branch: MAIN
CVS Tags: OPENBSD_6_8_BASE, OPENBSD_6_8
Changes since 1.205: +3 -3 lines
Diff to previous 1.205 (colored)

start wg with the other interfaces that rely on routing being up.

from Matt Dunwoodie and Jason A. Donenfeld

ok deraadt@

Revision 1.205 / (download) - annotate - [select for diffs], Fri May 22 13:38:44 2020 UTC (3 years, 11 months ago) by kn
Branch: MAIN
Changes since 1.204: +2 -2 lines
Diff to previous 1.204 (colored)

Revert the following commit as it breaks hostname.if(5) lines with a
backslash at the end for line continuation

Breaking long lines into multiple ones must still be possible and does
require to treat the backslash as an escape character.

Breakage reported by Mark Patruck <mark at wrapped dot cx >, thanks!

---
distrib/miniroot/install.sub revision 1.1151
etc/netstart revision 1.203
date: 2020/05/21 11:54:41;  author: kn;  state: Exp;  lines: +2 -2;
Do not treat backslashe as an escape character in hostname.if(5) lines

ifstart() should always pass such lines unaltered, especially if they
contain "nwid" or "description" lines with arbitrary strings.

<bsdlisten at gmail dot com> reported SSIDs such as "Mike's" during
installation end as broken;  this was because the installer escaped
the single quote using backslashes which ended up being treated as
escape characters much later during hostname.if parsing in netstart(8).

Ok deraadt

Revision 1.204 / (download) - annotate - [select for diffs], Thu May 21 13:42:02 2020 UTC (3 years, 11 months ago) by kn
Branch: MAIN
Changes since 1.203: +2 -3 lines
Diff to previous 1.203 (colored)

Fix stripcom() description wrt. comments not on their own line

Neither netstart's nor install.sub's (subtly different) implementations
remove trailing comments on lines not starting as a comment, e.g.,
lines like "up #not down" go through unaltered and without "#not down"
being removed.

Only lines *beginning* with the comment sign ("#") are stripped.

No functional change, just updating function descriptions.

Revision 1.203 / (download) - annotate - [select for diffs], Thu May 21 11:54:41 2020 UTC (3 years, 11 months ago) by kn
Branch: MAIN
Changes since 1.202: +2 -2 lines
Diff to previous 1.202 (colored)

Do not treat backslashe as an escape character in hostname.if(5) lines

ifstart() should always pass such lines unaltered, especially if they
contain "nwid" or "description" lines with arbitrary strings.

<bsdlisten at gmail dot com> reported SSIDs such as "Mike's" during
installation end as broken;  this was because the installer escaped
the single quote using backslashes which ended up being treated as
escape characters much later during hostname.if parsing in netstart(8).

Ok deraadt

Revision 1.202 / (download) - annotate - [select for diffs], Wed Jan 15 00:19:40 2020 UTC (4 years, 4 months ago) by kn
Branch: MAIN
CVS Tags: OPENBSD_6_7_BASE, OPENBSD_6_7
Changes since 1.201: +11 -11 lines
Diff to previous 1.201 (colored)

Do not redirect already quiet stdout for IPv6 reject routes

"route -q" already silences all standard output;  if it still prints
something, that's a bug to fix in route.

OK bluhm

Revision 1.201 / (download) - annotate - [select for diffs], Fri Oct 25 06:01:27 2019 UTC (4 years, 6 months ago) by dlg
Branch: MAIN
Changes since 1.200: +4 -4 lines
Diff to previous 1.200 (colored)

handle aggr(4) in the same way as trunk(4)

from brad@
ok bluhm@ claudio@ deraadt@

Revision 1.200 / (download) - annotate - [select for diffs], Wed Aug 29 11:30:48 2018 UTC (5 years, 8 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_6_6_BASE, OPENBSD_6_6, OPENBSD_6_5_BASE, OPENBSD_6_5, OPENBSD_6_4_BASE, OPENBSD_6_4
Changes since 1.199: +2 -2 lines
Diff to previous 1.199 (colored)

Historically /etc/netstart (and the equivalent code in the install
script) did 'ifconfig <if> down' before starting dhclient(8). This was
a way of ensuring old running copies of dhclient were killed before a
new one started. Current dhclient does not need this assist, so change
"ifconfig <if> down" to "ifconfig <if> up" pending further script
optimizations.

Similar to a 2014 attempt by halex@. Prompted by a misc@ report
from Kristjan Komlosi reporting hanging diskless setups.

ok halex@ kn@

Revision 1.199 / (download) - annotate - [select for diffs], Sun Jul 8 20:10:26 2018 UTC (5 years, 10 months ago) by tb
Branch: MAIN
Changes since 1.198: +8 -1 lines
Diff to previous 1.198 (colored)

netstart is used during system start, but also interactively.
Show proper error message if a regular user executes netstart.
Only do the privilege check if the id binary is available,
which might not be the case during diskless system startup.

ok deraadt, jasper, jca, krw, rpe (who wrote the same diff), sthen

Revision 1.198 / (download) - annotate - [select for diffs], Sat Apr 28 22:38:32 2018 UTC (6 years ago) by rpe
Branch: MAIN
Changes since 1.197: +9 -7 lines
Diff to previous 1.197 (colored)

Add a proper usage() function.

Suggested by and OK jmc.
OK tb

Revision 1.197 / (download) - annotate - [select for diffs], Sun Mar 4 10:12:26 2018 UTC (6 years, 2 months ago) by jmc
Branch: MAIN
CVS Tags: OPENBSD_6_3_BASE, OPENBSD_6_3
Changes since 1.196: +2 -2 lines
Diff to previous 1.196 (colored)

when -n is used, no need to spit out "Missing parameters." before
displaying usage();

ok tb

Revision 1.196 / (download) - annotate - [select for diffs], Sat Mar 3 07:34:19 2018 UTC (6 years, 2 months ago) by landry
Branch: MAIN
Changes since 1.195: +2 -2 lines
Diff to previous 1.195 (colored)

Lowercase 'usage' and group -n with interface in it.
From jmc@, ok tb@

Revision 1.195 / (download) - annotate - [select for diffs], Wed Feb 21 19:57:21 2018 UTC (6 years, 2 months ago) by rpe
Branch: MAIN
Changes since 1.194: +10 -6 lines
Diff to previous 1.194 (colored)

Tweak comments.

OK tb

Revision 1.194 / (download) - annotate - [select for diffs], Mon Feb 19 23:42:29 2018 UTC (6 years, 2 months ago) by rpe
Branch: MAIN
Changes since 1.193: +4 -4 lines
Diff to previous 1.193 (colored)

Write warning/error messages to stderr and end them with a fullstop.

OK tb

Revision 1.193 / (download) - annotate - [select for diffs], Mon Feb 19 21:47:43 2018 UTC (6 years, 2 months ago) by rpe
Branch: MAIN
Changes since 1.192: +7 -5 lines
Diff to previous 1.192 (colored)

- use specific patterns when looping over /etc/hostname.if files
  to skip backup or temp files.
- test if the patterns matched actual files
- warn if ifcreate() fails on an interface and continue with the
  subsequent interfaces in the list instead of return'ing

OK dlg sthen tb

Revision 1.192 / (download) - annotate - [select for diffs], Sat Feb 17 13:11:03 2018 UTC (6 years, 3 months ago) by rpe
Branch: MAIN
Changes since 1.191: +6 -5 lines
Diff to previous 1.191 (colored)

- Add descriptions for the new functions ifcreate() and vifscreate()
- In ifcreate() use the exit code of the {} block directly
- In vifscreate(), use the ifconfig -C output directly in the for _vif loop
- Remove superfluous and somewhat confusing comment

OK dlg kn sthen

Revision 1.191 / (download) - annotate - [select for diffs], Wed Feb 14 22:08:45 2018 UTC (6 years, 3 months ago) by dlg
Branch: MAIN
Changes since 1.190: +29 -11 lines
Diff to previous 1.190 (colored)

create virtual interfaces before starting all interface config.

this resolves an ordering problem when adding pseudo interfaces to bridges

tweaks from kn@
ok mpi@ sthen@

Revision 1.190 / (download) - annotate - [select for diffs], Sat Feb 10 08:46:10 2018 UTC (6 years, 3 months ago) by claudio
Branch: MAIN
Changes since 1.189: +1 -7 lines
Diff to previous 1.189 (colored)

Remove some special IPv4 in IPv6 mapped prefixes that are already rejected
by the ::0.0.0.0/96 reject route added to deny all IPv4 mapped addresses.
Makes the inet6 routing table almost fit in one screen.
OK benno@

Revision 1.189 / (download) - annotate - [select for diffs], Sat Feb 10 05:56:47 2018 UTC (6 years, 3 months ago) by florian
Branch: MAIN
Changes since 1.188: +4 -1 lines
Diff to previous 1.188 (colored)

Load RFC 7217 key material and generate if it does not already exist.

Add soii.key to changelist (pointed out by semarie) and mtree/special
(suggest by Craig Skinner).

OK naddy, sthen, rpe, tb

Revision 1.188 / (download) - annotate - [select for diffs], Tue Feb 6 19:53:50 2018 UTC (6 years, 3 months ago) by tb
Branch: MAIN
Changes since 1.187: +15 -3 lines
Diff to previous 1.187 (colored)

If -n is given, the netstart script should not (try to) set the default
route(s). Simply print the command(s) to be issued instead.

tweak & ok rpe

Revision 1.187 / (download) - annotate - [select for diffs], Sun Nov 12 21:58:00 2017 UTC (6 years, 6 months ago) by tb
Branch: MAIN
Changes since 1.186: +2 -3 lines
Diff to previous 1.186 (colored)

Remove HN_DIR variable and expand it in the only place it was used. It
currently serves no purpose.

ok rpe, agreement from deraadt and halex

Revision 1.186 / (download) - annotate - [select for diffs], Tue Jul 25 21:17:11 2017 UTC (6 years, 9 months ago) by rpe
Branch: MAIN
CVS Tags: OPENBSD_6_2_BASE, OPENBSD_6_2
Changes since 1.185: +1 -8 lines
Diff to previous 1.185 (colored)

Finally remove backwards compat code to support the 'rtsol' keyword
in hostname.if(5)

OK mpi@ deraadt@ florian@
OK jmc@ from doc perspective

Revision 1.185 / (download) - annotate - [select for diffs], Fri Jul 21 20:22:13 2017 UTC (6 years, 9 months ago) by rpe
Branch: MAIN
Changes since 1.184: +9 -9 lines
Diff to previous 1.184 (colored)

Align ifstart() in netstart and install.sub.

- in netstart, rename _file to _hn referencing hostname.if files
- in install.sub switch ifstart() to be used with _if instead of
  _hn as parameter

ok krw@ tb@

Revision 1.184 / (download) - annotate - [select for diffs], Sun May 28 08:07:33 2017 UTC (6 years, 11 months ago) by awolk
Branch: MAIN
Changes since 1.183: +2 -2 lines
Diff to previous 1.183 (colored)

etc/netstart: use colon separator instead of dot with chown

OK jung@, deraadt@, jmc@

Revision 1.183 / (download) - annotate - [select for diffs], Sun May 7 09:40:15 2017 UTC (7 years ago) by rpe
Branch: MAIN
Changes since 1.182: +2 -2 lines
Diff to previous 1.182 (colored)

Change test from [] to [[]] and simplify pattern.

OK tb@, krw@ (for [[]])
Feedback and OK halex@

Revision 1.182 / (download) - annotate - [select for diffs], Sun May 7 07:55:17 2017 UTC (7 years ago) by rpe
Branch: MAIN
Changes since 1.181: +2 -2 lines
Diff to previous 1.181 (colored)

Replace hardcoded script name with ${0##*/}

OK tb@ halex@

Revision 1.181 / (download) - annotate - [select for diffs], Mon May 1 16:23:42 2017 UTC (7 years ago) by rpe
Branch: MAIN
Changes since 1.180: +1 -7 lines
Diff to previous 1.180 (colored)

Revert r1.170 and remove the id==0 check.
The id binary is not available in nfs diskless setups at this point.

reported by Andreas Kusalananda, thanks.
discussed with deraadt@

Revision 1.180 / (download) - annotate - [select for diffs], Mon May 1 14:23:29 2017 UTC (7 years ago) by rpe
Branch: MAIN
Changes since 1.179: +15 -30 lines
Diff to previous 1.179 (colored)

Remove last remnants of rtsol. IPv6 autoconfiguration of interfaces is now
done in ifstart(). Remove ipv6autoconf() and replace rtsolif with a boolean
variable V6_AUTOCONF. Replace dhcpif with a boolean variable V4_DHCPCONF.
Both are later used in defaultroute() to decide whether or not to configre
defaultroutes from /etc/mygate.

OK krw@

Revision 1.179 / (download) - annotate - [select for diffs], Sun Apr 30 19:37:13 2017 UTC (7 years ago) by mpi
Branch: MAIN
Changes since 1.178: +1 -3 lines
Diff to previous 1.178 (colored)

Do not try to delete a default route before adding it.

Now that route are automatically G/C with the address they are attached
to there's no reason to duplicate the kernel's job.

Fix a regression introduced with multipath default routes.

ok deraadt@

Revision 1.178 / (download) - annotate - [select for diffs], Tue Apr 25 19:17:33 2017 UTC (7 years ago) by rpe
Branch: MAIN
Changes since 1.177: +3 -1 lines
Diff to previous 1.177 (colored)

Unbreak netstart for multiple inteface configurations like trunk
or carp. Ensure that the noglob option is disabled at the end of
parse_hn_line() and ifstart().

Reported by Christer Solskogen and Stefan Wollny, thanks!

Revision 1.177 / (download) - annotate - [select for diffs], Mon Apr 24 20:31:48 2017 UTC (7 years ago) by rpe
Branch: MAIN
Changes since 1.176: +102 -93 lines
Diff to previous 1.176 (colored)

Introduce a new function parse_hn_line() that replaces the existing
hostname.if(5) parsing code in ifstart().
Add a -n option to netstart to only print the interface configuration
commands instead of executing them.
Add a HN_DIR variable, that points to the directory of the hostname.if
files (default /etc) that allows for future regression tests.

- add new parse_hn_line() function
- change ifstart()
  - rename $if to $_if
  - don't ifconfig or ifconfig create if -n option is used
  - replace hostname.if(5) parsing code with new parse_hn_line()
  - just print configuration commands if -n option is used
- autoconf now happens in ifstart(), remove ifv6autoconf()
- introduce HN_DIR variable for the hostname.if file location
- add handling of the -n option to only print config commands
- ensure -n is only used if interfaces are specified as parameters

Discussed with and positive feedback from many
'commit' deraadt@
OK sthen@

Revision 1.176 / (download) - annotate - [select for diffs], Sat Apr 8 08:33:05 2017 UTC (7 years, 1 month ago) by rpe
Branch: MAIN
Changes since 1.175: +10 -11 lines
Diff to previous 1.175 (colored)

- localize the if, file and stat variables which also ensures that
  variables are not named like commands.
- change test from [] to [[]]

OK tb@ halex@

Revision 1.175 / (download) - annotate - [select for diffs], Fri Apr 7 22:53:25 2017 UTC (7 years, 1 month ago) by rpe
Branch: MAIN
Changes since 1.174: +6 -5 lines
Diff to previous 1.174 (colored)

Minimize differences in ifstart() function between netstart and
install.sub which makes it easier to spot changes in the future.

- comments and formatting
- quotes on assignments are not needed (netstart)
- remove stray space in test (netstart)
- use $file variable with while-loop (netstart)
- although valid, instead of i use $i in arithmetic test (install.sub)

OK krw@, tb@
Looks good deraadt@

Revision 1.174 / (download) - annotate - [select for diffs], Fri Apr 7 22:15:17 2017 UTC (7 years, 1 month ago) by rpe
Branch: MAIN
Changes since 1.173: +4 -1 lines
Diff to previous 1.173 (colored)

Align comments of ifstart() function in netstart and install.sub.

Revision 1.173 / (download) - annotate - [select for diffs], Fri Apr 7 21:44:07 2017 UTC (7 years, 1 month ago) by rpe
Branch: MAIN
Changes since 1.172: +4 -3 lines
Diff to previous 1.172 (colored)

Align comments of stripcom() function in netstart and install.sub.

Revision 1.172 / (download) - annotate - [select for diffs], Tue Dec 6 14:01:43 2016 UTC (7 years, 5 months ago) by mpi
Branch: MAIN
CVS Tags: OPENBSD_6_1_BASE, OPENBSD_6_1
Changes since 1.171: +19 -12 lines
Diff to previous 1.171 (colored)

Do not lose the default route when netstart(8) is run a second time on
the interface pointed to by the default route.

Since the kernel no longer keep routes with dangling address pointer,
netstart(8) has to re-add the default route when the corresponding ifa
has been deleted and re-created.

deraadt@ points out that even if the previous semantic was not necessarily
better, a script like netstart(8) cannot totally fix the default route
problem.

Regression reported by and fix tested by Hrvoje Popovski.

ksh foo checked by halex@

Revision 1.171 / (download) - annotate - [select for diffs], Tue Sep 27 09:19:11 2016 UTC (7 years, 7 months ago) by rzalamena
Branch: MAIN
Changes since 1.170: +3 -3 lines
Diff to previous 1.170 (colored)

Delay switch(4) interface start up so it can attach virtual interfaces
like vether(4).

nits from and ok benno@, phessler@

Revision 1.170 / (download) - annotate - [select for diffs], Fri Sep 9 19:48:16 2016 UTC (7 years, 8 months ago) by jasper
Branch: MAIN
Changes since 1.169: +7 -1 lines
Diff to previous 1.169 (colored)

print a clear error message when not ran as root instead of just falling
through and try whatever it can do with the invoking user's perms

feedback/ok aja@ rpe@

Revision 1.169 / (download) - annotate - [select for diffs], Tue Jul 19 08:03:01 2016 UTC (7 years, 10 months ago) by mpi
Branch: MAIN
CVS Tags: OPENBSD_6_0_BASE, OPENBSD_6_0
Changes since 1.168: +3 -3 lines
Diff to previous 1.168 (colored)

Do not consider tap(4) a special interface and start if before other
pseudo-interfaces.

This unbreak vlan(4) on top of tap(4) since the refactoring to turn it
MP-safe.

ok claudio@, deraadt@

Revision 1.168 / (download) - annotate - [select for diffs], Sun Mar 27 20:32:42 2016 UTC (8 years, 1 month ago) by sthen
Branch: MAIN
Changes since 1.167: +4 -3 lines
Diff to previous 1.167 (colored)

Don't delete the 224/4 route in netstart, unless it's being done to ensure that
a -reject route can be added. Restores the ability to set an interface route
before daemons are started, lost during the previous simplification.
ok millert mpi

Revision 1.167 / (download) - annotate - [select for diffs], Tue Dec 29 19:37:31 2015 UTC (8 years, 4 months ago) by rpe
Branch: MAIN
CVS Tags: OPENBSD_5_9_BASE, OPENBSD_5_9
Changes since 1.166: +2 -2 lines
Diff to previous 1.166 (colored)

Remove backslash, not necessary after '&&'

OK halex@

Revision 1.166 / (download) - annotate - [select for diffs], Tue Dec 29 19:33:43 2015 UTC (8 years, 4 months ago) by rpe
Branch: MAIN
Changes since 1.165: +2 -2 lines
Diff to previous 1.165 (colored)

Replace last remaining `` with $()

OK halex@

Revision 1.165 / (download) - annotate - [select for diffs], Fri Dec 18 08:49:53 2015 UTC (8 years, 5 months ago) by ajacoutot
Branch: MAIN
Changes since 1.164: +1 -7 lines
Diff to previous 1.164 (colored)

Drop the now useless multicast setup comment.

prodded by tim@, ok mpi@

Revision 1.164 / (download) - annotate - [select for diffs], Thu Dec 17 23:19:23 2015 UTC (8 years, 5 months ago) by ajacoutot
Branch: MAIN
Changes since 1.163: +2 -12 lines
Diff to previous 1.163 (colored)

Simplify multicast option handling (10 less lines) by matching /etc/rc behavior
towards other YES|NO options and drop the error warning.


with and ok tim@, ok rpe@ on an earlier diff

Revision 1.163 / (download) - annotate - [select for diffs], Sat Dec 5 18:43:12 2015 UTC (8 years, 5 months ago) by mpi
Branch: MAIN
Changes since 1.162: +9 -28 lines
Diff to previous 1.162 (colored)

It does not make sense to insert a specific route for 224/4 when the
default one is good enough.

So merge rc.conf(8)'s 'multicast_router' and 'multicast_host' into a
single 'multicast'.  If set to YES the reject route for 224/4 is not
inserted by netstart(8).

Manual bits from jmc@

ok henning@, ajacoutot@

Revision 1.162 / (download) - annotate - [select for diffs], Thu Nov 12 23:11:11 2015 UTC (8 years, 6 months ago) by rpe
Branch: MAIN
Changes since 1.161: +13 -11 lines
Diff to previous 1.161 (colored)

Changes to ifautostart():
- Rename function to ifv6autoconf() to make IPv6 relation clearer
- Localize and rename variables

OK krw@

Revision 1.161 / (download) - annotate - [select for diffs], Thu Nov 12 23:00:13 2015 UTC (8 years, 6 months ago) by rpe
Branch: MAIN
Changes since 1.160: +13 -15 lines
Diff to previous 1.160 (colored)

Changes to ifmstart():
- Change comments to make it clearer that ifmstart() takes two lists
  of interface driver names (of which the second is optional) and not
  the actual interface instances.
- Use localized variables and use slightly more verbose names.
- Use continue 2 to skip to the next hostname.if file.
- Use shell pattern @() instead of testing _sif individually.

OK krw@

Revision 1.160 / (download) - annotate - [select for diffs], Thu Nov 12 22:50:46 2015 UTC (8 years, 6 months ago) by rpe
Branch: MAIN
Changes since 1.159: +13 -9 lines
Diff to previous 1.159 (colored)

Changes to stripcom():
- Align comments with /etc/rc version
- Use localized variables
- Use safer "print -r --" instead of plain echo

Changes to ifstart():
- Tweak comment
- Add usage

OK krw@

Revision 1.159 / (download) - annotate - [select for diffs], Sun Nov 1 15:37:18 2015 UTC (8 years, 6 months ago) by rpe
Branch: MAIN
Changes since 1.158: +9 -17 lines
Diff to previous 1.158 (colored)

Start the rework of the /etc/netstart shell script.

General changes:
- apply a similar 'style' as used in the installer scripts
- improve comments to be more to the point, remove where code is obvious
- document usage of functions if they have arguments
- rename variables where it improves readability
- replace really old-school shell code with more contemporary idioms

Other changes:
- No need to care about "autoboot" because netstart doesn't inherit the
  positional parameters from /etc/rc anymore. /etc/rc executes netstart
  instead of sourcing it since r1.439.
- Use simpler for-loop to process list of interfaces with ifstart.

OK halex@

Revision 1.158 / (download) - annotate - [select for diffs], Mon Oct 26 19:24:04 2015 UTC (8 years, 6 months ago) by rpe
Branch: MAIN
Changes since 1.157: +2 -5 lines
Diff to previous 1.157 (colored)

The hostname variable is not used since r1.99. Remove it and use
stripcom() output directly with the hostname command.

OK deraadt@ krw@

Revision 1.157 / (download) - annotate - [select for diffs], Fri Oct 23 15:22:49 2015 UTC (8 years, 6 months ago) by claudio
Branch: MAIN
Changes since 1.156: +3 -3 lines
Diff to previous 1.156 (colored)

netstart bits for tap(4)

Revision 1.156 / (download) - annotate - [select for diffs], Sun Sep 27 20:32:33 2015 UTC (8 years, 7 months ago) by sthen
Branch: MAIN
Changes since 1.155: +7 -12 lines
Diff to previous 1.155 (colored)

Don't print output when setting autoconf on interfaces. Suggested by deraadt,
ok florian@ rpe@

Revision 1.155 / (download) - annotate - [select for diffs], Sun Sep 13 13:51:57 2015 UTC (8 years, 8 months ago) by sthen
Branch: MAIN
Changes since 1.154: +12 -10 lines
Diff to previous 1.154 (colored)

only print the "IPv6 autoconf" line if there are interfaces to configure
feedback/ok rpe

Revision 1.154 / (download) - annotate - [select for diffs], Fri Sep 11 12:21:52 2015 UTC (8 years, 8 months ago) by sthen
Branch: MAIN
Changes since 1.153: +19 -5 lines
Diff to previous 1.153 (colored)

Set "inet6 autoconf" individually on interfaces that have rtsol set in
hostname.if, previously netstart tried to configure them all at once
("ifconfig if0 if1 if2 inet6 autoconf").  From Delan Azabani, ok phessler@

Revision 1.153 / (download) - annotate - [select for diffs], Mon Jul 20 06:59:39 2015 UTC (8 years, 10 months ago) by rpe
Branch: MAIN
CVS Tags: OPENBSD_5_8_BASE, OPENBSD_5_8
Changes since 1.152: +4 -1 lines
Diff to previous 1.152 (colored)

Disable Strict Bourne shell mode for /etc/rc and /etc/netstart to be
able to use ksh syntax within these scripts. This way init doesn't
need to be changed, which starts /etc/rc using /bin/sh and people
can still use "sh /etc/netstart ifname".

Idea from and OK halex@
OK deraadt@ krw@ guenther@

Revision 1.152 / (download) - annotate - [select for diffs], Sun Jul 19 23:42:58 2015 UTC (8 years, 10 months ago) by florian
Branch: MAIN
Changes since 1.151: +7 -6 lines
Diff to previous 1.151 (colored)

Bring up pflow last as it might send with a source address that is on
any of the other interfaces.
OK deraadt, phessler, benno

Revision 1.151 / (download) - annotate - [select for diffs], Sun Jul 19 19:52:36 2015 UTC (8 years, 10 months ago) by rpe
Branch: MAIN
Changes since 1.150: +3 -3 lines
Diff to previous 1.150 (colored)

Always source rc.subr to be able to use the rc.conf parsing routine
to get the network related vars from rc.conf. This is even necessary
if netstart is run from within /etc/rc. Remove test of $INRC which
unintentionally evaluated always to true.

problem with previous change found by nigel@
OK sthen@ aja@ halex@

Revision 1.150 / (download) - annotate - [select for diffs], Sun Jul 19 14:17:21 2015 UTC (8 years, 10 months ago) by ajacoutot
Branch: MAIN
Changes since 1.149: +4 -6 lines
Diff to previous 1.149 (colored)

Revert 1.148 for now until I can talk to rpe@
It introduced a regression reported by nigel@

Revision 1.149 / (download) - annotate - [select for diffs], Sun Jul 19 04:44:36 2015 UTC (8 years, 10 months ago) by rpe
Branch: MAIN
Changes since 1.148: +6 -7 lines
Diff to previous 1.148 (colored)

Replace test command with [].

OK halex@ krw@

Revision 1.148 / (download) - annotate - [select for diffs], Sun Jul 19 01:37:45 2015 UTC (8 years, 10 months ago) by rpe
Branch: MAIN
Changes since 1.147: +6 -4 lines
Diff to previous 1.147 (colored)

Ensure, that we source rc.subr and parse rc.conf ONLY if we are not
inside /etc/rc.

With help from and OK halex@, ajacoutot@

Revision 1.147 / (download) - annotate - [select for diffs], Sat Jul 18 00:37:23 2015 UTC (8 years, 10 months ago) by rpe
Branch: MAIN
Changes since 1.146: +25 -25 lines
Diff to previous 1.146 (colored)

- remove trailing blanks introduced in previous commit
- no space in redirections like </foo or >$bar
- few other minor whitespaces

OK krw@

Revision 1.146 / (download) - annotate - [select for diffs], Sat Jul 18 00:03:34 2015 UTC (8 years, 10 months ago) by rpe
Branch: MAIN
Changes since 1.145: +24 -21 lines
Diff to previous 1.145 (colored)

Improve comments
- Add comments for functions
- Start comments with capital letters
- End comments with a full stop
- Allow comments to extend up to column 80

OK krw@

Revision 1.145 / (download) - annotate - [select for diffs], Sat Jun 6 13:13:07 2015 UTC (8 years, 11 months ago) by florian
Branch: MAIN
Changes since 1.144: +3 -8 lines
Diff to previous 1.144 (colored)

Allow rtsol keyword in hostname.if(5) with net.inet6.ip6.forwarding=1.
"inet6 autoconf" was working before and rtsol should behave the same.
OK phessler

Revision 1.144 / (download) - annotate - [select for diffs], Wed Dec 3 19:55:49 2014 UTC (9 years, 5 months ago) by florian
Branch: MAIN
CVS Tags: OPENBSD_5_7_BASE, OPENBSD_5_7
Changes since 1.143: +2 -2 lines
Diff to previous 1.143 (colored)

The kernel handles rtsol(8) functionality since some time now.
Treat rtsol in hostname.if as a keyword like dhcp and call ifconfig
inet6 autoconf.
"reads good" todd@
OK krw@ (who is *not* an IPv6 person), but I recruited him in his
capacity as an installer person.

Revision 1.143 / (download) - annotate - [select for diffs], Sun Sep 28 12:58:02 2014 UTC (9 years, 7 months ago) by claudio
Branch: MAIN
Changes since 1.142: +2 -2 lines
Diff to previous 1.142 (colored)

Revert 1.142. Without the down netstart will just print the ifconfig
output because it may end up just calling 'ifconfig $if'. This needs
to be done better and properly tested.

Revision 1.142 / (download) - annotate - [select for diffs], Fri Sep 26 15:18:01 2014 UTC (9 years, 7 months ago) by halex
Branch: MAIN
Changes since 1.141: +2 -2 lines
Diff to previous 1.141 (colored)

remove explicit 'down' of an interface before starting a dhcp request, thereby
avoiding annoying delays for some switch configurations

ok claudio@ deraadt@

i would add ok phessler@, but it was not valid without an ok krw@

Revision 1.141 / (download) - annotate - [select for diffs], Sat Jul 12 14:39:31 2014 UTC (9 years, 10 months ago) by stsp
Branch: MAIN
CVS Tags: OPENBSD_5_6_BASE, OPENBSD_5_6
Changes since 1.140: +3 -4 lines
Diff to previous 1.140 (colored)

Fix netstart after autoconf6 change so 'rtsol' lines in hostname.if work again.
found by pelikan@; ok pelikan@ henning@

Revision 1.140 / (download) - annotate - [select for diffs], Sat Jul 12 10:14:03 2014 UTC (9 years, 10 months ago) by robert
Branch: MAIN
Changes since 1.139: +4 -3 lines
Diff to previous 1.139 (colored)

Make rc.conf a parsed configuration file and stop sourcing it as a shell
script.
From now on rc.conf has a fixed syntax (key=val) and it is not allowed
to add anything to it besides the supported syntax, it all going to be
ignored.

discussed with and help from deraadt@ and halex@

Revision 1.139 / (download) - annotate - [select for diffs], Thu Aug 22 07:53:11 2013 UTC (10 years, 8 months ago) by mpi
Branch: MAIN
CVS Tags: OPENBSD_5_5_BASE, OPENBSD_5_5
Changes since 1.138: +2 -3 lines
Diff to previous 1.138 (colored)

Like for dhclient, do no create a route to alias addresses via 127.0.0.1.
Our stack is able to tell if the address is local or not.

ok todd@, krw@

Revision 1.138 / (download) - annotate - [select for diffs], Wed Mar 20 15:26:28 2013 UTC (11 years, 2 months ago) by todd
Branch: MAIN
CVS Tags: OPENBSD_5_4_BASE, OPENBSD_5_4
Changes since 1.137: +2 -3 lines
Diff to previous 1.137 (colored)

fix lies in netstart; replacement wording from halex@
pointed out by Ryan Kavannagh rak at debian dot org

Revision 1.137 / (download) - annotate - [select for diffs], Wed Dec 5 07:08:38 2012 UTC (11 years, 5 months ago) by rpe
Branch: MAIN
CVS Tags: OPENBSD_5_3_BASE, OPENBSD_5_3
Changes since 1.136: +2 -5 lines
Diff to previous 1.136 (colored)

remove "Invalid interface name" message
requested by krw@

ok halex@

Revision 1.136 / (download) - annotate - [select for diffs], Sun Dec 2 21:02:45 2012 UTC (11 years, 5 months ago) by rpe
Branch: MAIN
Changes since 1.135: +3 -7 lines
Diff to previous 1.135 (colored)

use the more compact version of the check for ifconfig'able interfaces
from install.sub

with feedback from and ok halex

Revision 1.135 / (download) - annotate - [select for diffs], Sun Dec 2 16:19:18 2012 UTC (11 years, 5 months ago) by rpe
Branch: MAIN
Changes since 1.134: +4 -17 lines
Diff to previous 1.134 (colored)

- remove isalphanumeric() and replace it with a shell pattern, that
  tries a bit harder to identify invalid interface names and in
  this case emit an error message.
- use [[ $1 == autoboot ]] to avoid a shell error message due to
  possible spaces in first argument
- no change in functionality

discussed with krw and halex
ok ("I like this") krw

Revision 1.134 / (download) - annotate - [select for diffs], Fri Oct 7 16:36:26 2011 UTC (12 years, 7 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_5_2_BASE, OPENBSD_5_2, OPENBSD_5_1_BASE, OPENBSD_5_1
Changes since 1.133: +1 -5 lines
Diff to previous 1.133 (colored)

The new ypbind changes requires that the domainname be set before
rc.conf is run.  There's no real downside.
ok aja

Revision 1.133 / (download) - annotate - [select for diffs], Thu Jul 7 23:09:46 2011 UTC (12 years, 10 months ago) by guenther
Branch: MAIN
CVS Tags: OPENBSD_5_0_BASE, OPENBSD_5_0
Changes since 1.132: +3 -5 lines
Diff to previous 1.132 (colored)

Eliminate some $? tests by rolling the command into the condition

ok halex@

Revision 1.132 / (download) - annotate - [select for diffs], Thu May 26 15:22:53 2011 UTC (12 years, 11 months ago) by mpf
Branch: MAIN
Changes since 1.131: +4 -4 lines
Diff to previous 1.131 (colored)

Add svlan(4) startup bits.
From markus@. OK naddy, claudio, reyk.

Revision 1.131 / (download) - annotate - [select for diffs], Wed Feb 9 17:22:06 2011 UTC (13 years, 3 months ago) by sobrado
Branch: MAIN
CVS Tags: OPENBSD_4_9_BASE, OPENBSD_4_9
Changes since 1.130: +3 -3 lines
Diff to previous 1.130 (colored)

fix an unbalanced parenthesis in a comment; while here, split the comment
in a better place to make it more readable.

ok jmc@ and miod@

Revision 1.130 / (download) - annotate - [select for diffs], Wed Jun 16 23:45:57 2010 UTC (13 years, 11 months ago) by todd
Branch: MAIN
CVS Tags: OPENBSD_4_8_BASE, OPENBSD_4_8
Changes since 1.129: +2 -2 lines
Diff to previous 1.129 (colored)

permit e.g. -inet6 syntax by slurping all lines not just some
noticed by rhsv6 at hushmail dot com, ok sthen@

Revision 1.129 / (download) - annotate - [select for diffs], Tue Jan 12 07:43:41 2010 UTC (14 years, 4 months ago) by henning
Branch: MAIN
CVS Tags: OPENBSD_4_7_BASE, OPENBSD_4_7
Changes since 1.128: +2 -2 lines
Diff to previous 1.128 (colored)

when setting up lo0 use 127.0.0.1/8 instead of 127.0.0.1 for clarity and
correctness. it's not 1992 any more, kids. ok mcbride dlg krw

Revision 1.128 / (download) - annotate - [select for diffs], Thu Dec 10 00:51:55 2009 UTC (14 years, 5 months ago) by todd
Branch: MAIN
Changes since 1.127: +11 -11 lines
Diff to previous 1.127 (colored)

o stop reordering ifconfig arguments (e.g. after 'up ..')
o only stop processing if inet or inet6 lines are malformed
o everything not a specially handled bit is passed to ifconfig unmangled
noticed by several after the move from bridgename.bridge0 -> hostname.bridge0
prodded by deraadt@, tested by and feedback from several
man page bits 'look fine' jmc@

Revision 1.127 / (download) - annotate - [select for diffs], Sun Nov 22 23:09:50 2009 UTC (14 years, 5 months ago) by deraadt
Branch: MAIN
Changes since 1.126: +5 -55 lines
Diff to previous 1.126 (colored)

Stop supporting bridgename.bridge* files, and move to hostname.bridge*
files.  To cope with this change, read about the mv command.
ok claudio todd

Revision 1.126 / (download) - annotate - [select for diffs], Thu Sep 17 08:22:22 2009 UTC (14 years, 8 months ago) by simon
Branch: MAIN
Changes since 1.125: +2 -2 lines
Diff to previous 1.125 (colored)

change variable i to $i in an expression of ifstart() for consistency
with the rest of the file.  no functional change.

feedback from sthen@, ok krw@

Revision 1.125 / (download) - annotate - [select for diffs], Fri Jul 10 19:08:08 2009 UTC (14 years, 10 months ago) by jdixon
Branch: MAIN
Changes since 1.124: +6 -5 lines
Diff to previous 1.124 (colored)

Delay creation of tun(4) interfaces until the underlying interface and
routes are available.  This fixes usage for some OpenVPN users that start
it from hostname.tun*.

Tested by Johan Huldtgren.  ok sthen@, johan@.

Revision 1.124 / (download) - annotate - [select for diffs], Tue Nov 25 12:11:44 2008 UTC (15 years, 5 months ago) by markus
Branch: MAIN
CVS Tags: OPENBSD_4_6_BASE, OPENBSD_4_6, OPENBSD_4_5_BASE, OPENBSD_4_5
Changes since 1.123: +5 -2 lines
Diff to previous 1.123 (colored)

delay /etc/netstart until IPv6-DAD (dup-address-detection) is completed.
ok fries, hshoexer, claudio

Revision 1.123 / (download) - annotate - [select for diffs], Thu Aug 14 00:59:50 2008 UTC (15 years, 9 months ago) by sthen
Branch: MAIN
Changes since 1.122: +4 -2 lines
Diff to previous 1.122 (colored)

Tools from /usr may not be used in netstart since it may be NFS-mounted
and not available at that time. Rewrite the hostname.if permission check
to use only /bin/ls and the shell. Requested by deraadt.

ok todd, "Twisted." deraadt

Revision 1.122 / (download) - annotate - [select for diffs], Wed Jul 23 16:05:47 2008 UTC (15 years, 9 months ago) by sthen
Branch: MAIN
CVS Tags: OPENBSD_4_4_BASE, OPENBSD_4_4
Changes since 1.121: +4 -4 lines
Diff to previous 1.121 (colored)

Prevent warning about insecure hostnames where no /etc/hostname.*
exists. From wcmaier@.

Check target of symbolic links to avoid noise at boot and in
seucrity output where you have several interfaces symlinked to one
config file.

"If you think this is the right thing to do" deraadt@

Revision 1.121 / (download) - annotate - [select for diffs], Mon Jun 9 22:56:42 2008 UTC (15 years, 11 months ago) by todd
Branch: MAIN
Changes since 1.120: +5 -1 lines
Diff to previous 1.120 (colored)

warn once not 3 times in case of a non existent file, discussed with deraadt
originally pointed out by Johan Torin

Revision 1.120 / (download) - annotate - [select for diffs], Mon Jun 9 22:46:42 2008 UTC (15 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.119: +3 -2 lines
Diff to previous 1.119 (colored)

Ensure that hostname.* files are also re-chowned to root.wheel at each
boot as discussed with claudio while eating tasty donairs.  ok todd

Revision 1.119 / (download) - annotate - [select for diffs], Thu Apr 17 19:03:25 2008 UTC (16 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.118: +6 -1 lines
Diff to previous 1.118 (colored)

before using them, force hostname.* files to be unreadable by world
first version from todd, ok millert

Revision 1.118 / (download) - annotate - [select for diffs], Thu Jan 17 12:36:33 2008 UTC (16 years, 4 months ago) by brad
Branch: MAIN
CVS Tags: OPENBSD_4_3_BASE, OPENBSD_4_3
Changes since 1.117: +6 -6 lines
Diff to previous 1.117 (colored)

Execute rtsol after turning up trunk(4) and vlan(4) interfaces so they're
taken into consideration for rtsol.

ok reyk@ dlg@

Revision 1.117 / (download) - annotate - [select for diffs], Wed Jan 9 21:38:19 2008 UTC (16 years, 4 months ago) by mpf
Branch: MAIN
Changes since 1.116: +3 -5 lines
Diff to previous 1.116 (colored)

Do not bring up pfsync(4) before the working ruleset
has been loaded. Otherwise, states that are received during the
initial bulk update mismatch the correct pf-checksum and
do not attach to the rules.
Problem identified by david@. Fix done in collaboration.
OK henning@

Revision 1.116 / (download) - annotate - [select for diffs], Thu Aug 2 03:19:10 2007 UTC (16 years, 9 months ago) by david
Branch: MAIN
CVS Tags: OPENBSD_4_2_BASE, OPENBSD_4_2
Changes since 1.115: +6 -5 lines
Diff to previous 1.115 (colored)

move the delay for IPv6 DAD to after all interfaces have started
fixes problems with daemons being unable to bind to all addreses at boot
ok itojun@ hshoexer@

Revision 1.115 / (download) - annotate - [select for diffs], Wed Nov 15 06:28:33 2006 UTC (17 years, 6 months ago) by itojun
Branch: MAIN
CVS Tags: OPENBSD_4_1_BASE, OPENBSD_4_1
Changes since 1.114: +5 -1 lines
Diff to previous 1.114 (colored)

reject multicast packet without scope identifier specified.

Revision 1.114 / (download) - annotate - [select for diffs], Thu Jun 29 17:23:28 2006 UTC (17 years, 10 months ago) by todd
Branch: MAIN
CVS Tags: OPENBSD_4_0_BASE, OPENBSD_4_0
Changes since 1.113: +2 -2 lines
Diff to previous 1.113 (colored)

do not add an extra space; nwid and description come out wrong
fix as proposed by maja@, thanks!

Revision 1.113 / (download) - annotate - [select for diffs], Wed Dec 28 04:55:35 2005 UTC (18 years, 4 months ago) by david
Branch: MAIN
CVS Tags: OPENBSD_3_9_BASE, OPENBSD_3_9
Changes since 1.112: +3 -3 lines
Diff to previous 1.112 (colored)

nuke extra whitespace

Revision 1.112 / (download) - annotate - [select for diffs], Tue Dec 6 17:24:18 2005 UTC (18 years, 5 months ago) by reyk
Branch: MAIN
Changes since 1.111: +11 -4 lines
Diff to previous 1.111 (colored)

multicast_host=YES only works if a valid default gateway is available.
validate this condition and reject multicast traffic on failure.

ok todd@ naddy@

Revision 1.111 / (download) - annotate - [select for diffs], Wed Nov 2 18:45:26 2005 UTC (18 years, 6 months ago) by todd
Branch: MAIN
Changes since 1.110: +2 -2 lines
Diff to previous 1.110 (colored)

fix inspired by pr#4590
ok krw@

Revision 1.110 / (download) - annotate - [select for diffs], Tue Oct 25 14:18:38 2005 UTC (18 years, 6 months ago) by todd
Branch: MAIN
Changes since 1.109: +13 -14 lines
Diff to previous 1.109 (colored)

better logic from krw@:
- do not process mygate for v4 if dhcp
- do not process mygate for v6 if rtsol
this also makes the mygate processing logic more readable
ok krw@

Revision 1.109 / (download) - annotate - [select for diffs], Fri Oct 14 15:46:41 2005 UTC (18 years, 7 months ago) by todd
Branch: MAIN
Changes since 1.108: +10 -2 lines
Diff to previous 1.108 (colored)

add v6 support for /etc/mygate
ok deraadt@ mickey@ krw@
same functionality tested/ok'ed by by mickey, brad, matthieu, and me
with this one may now put a v6 IP in /etc/mygate on a separate line from
the v4 default gateway and netstart will do the right thing

Revision 1.108 / (download) - annotate - [select for diffs], Wed Oct 12 13:11:55 2005 UTC (18 years, 7 months ago) by todd
Branch: MAIN
Changes since 1.107: +5 -11 lines
Diff to previous 1.107 (colored)

shrink stripcom(), sync with install.sub
ok krw@

Revision 1.107 / (download) - annotate - [select for diffs], Tue Oct 4 12:50:15 2005 UTC (18 years, 7 months ago) by todd
Branch: MAIN
Changes since 1.106: +6 -4 lines
Diff to previous 1.106 (colored)

trunk must be started after physical ethernet devices, but before vlan.
populate ifmstart lines accordingly.
prodded/tested by brad@
ok reyk@

Revision 1.106 / (download) - annotate - [select for diffs], Wed Sep 28 17:40:30 2005 UTC (18 years, 7 months ago) by todd
Branch: MAIN
Changes since 1.105: +4 -5 lines
Diff to previous 1.105 (colored)

use eval consistently, fixes description quotes on rtsol and dhcp
fix inspired by and closes pr 4495
ok krw@

Revision 1.105 / (download) - annotate - [select for diffs], Sun May 22 08:56:08 2005 UTC (19 years ago) by todd
Branch: MAIN
CVS Tags: OPENBSD_3_8_BASE, OPENBSD_3_8
Changes since 1.104: +35 -54 lines
Diff to previous 1.104 (colored)

Introduce 'ifmstart' to deal with starting multiple interfaces minus a list
of interfaces.

This reduces the netstart script by 174 chars, 13 words, and 19 lines, but
more importantly, makes it more simple and less cluttered should more special
case/orderings be needed.

ok brad@ and pr 4197 submitter, inspired by and closes pr 4197

Revision 1.104 / (download) - annotate - [select for diffs], Mon Apr 4 04:26:27 2005 UTC (19 years, 1 month ago) by djm
Branch: MAIN
Changes since 1.103: +2 -2 lines
Diff to previous 1.103 (colored)

unbreak; ok pval@

Revision 1.103 / (download) - annotate - [select for diffs], Sun Apr 3 19:39:31 2005 UTC (19 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.102: +3 -2 lines
Diff to previous 1.102 (colored)

if dhcp is used to get an address on any interface, ignore /etc/mygate
ok krw
(this lets us do something rather cool with the zaurus in particular)

Revision 1.102 / (download) - annotate - [select for diffs], Tue Jan 4 15:40:53 2005 UTC (19 years, 4 months ago) by mcbride
Branch: MAIN
CVS Tags: OPENBSD_3_7_BASE, OPENBSD_3_7
Changes since 1.101: +26 -8 lines
Diff to previous 1.101 (colored)

Bring up the carp(4) interface before default route.

ok pascoe@ mpf@

Revision 1.101 / (download) - annotate - [select for diffs], Thu Dec 30 17:33:59 2004 UTC (19 years, 4 months ago) by millert
Branch: MAIN
Changes since 1.100: +16 -1 lines
Diff to previous 1.100 (colored)

Add a copy of stripcom so /etc/netstart can be run standalone again.
OK deraadt@

Revision 1.100 / (download) - annotate - [select for diffs], Sun Dec 19 15:37:58 2004 UTC (19 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.99: +4 -4 lines
Diff to previous 1.99 (colored)

Allow comments in /etc/{myname,mygate,defaultdomain}; OK deraadt@

Revision 1.99 / (download) - annotate - [select for diffs], Sat Dec 4 00:17:05 2004 UTC (19 years, 5 months ago) by itojun
Branch: MAIN
Changes since 1.98: +2 -3 lines
Diff to previous 1.98 (colored)

remove "route $hostname 127.0.0.1" line.  deraadt ok
*** please update /etc/netstart and test if it works ok for you ***

Revision 1.98 / (download) - annotate - [select for diffs], Wed Oct 20 21:17:34 2004 UTC (19 years, 7 months ago) by deraadt
Branch: MAIN
Changes since 1.97: +13 -13 lines
Diff to previous 1.97 (colored)

make all route commands use -qn; ok mcbride henning

Revision 1.97 / (download) - annotate - [select for diffs], Sat May 29 07:01:03 2004 UTC (19 years, 11 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_6_BASE, OPENBSD_3_6
Changes since 1.96: +2 -2 lines
Diff to previous 1.96 (colored)

one last route command lacking -qn

Revision 1.96 / (download) - annotate - [select for diffs], Mon Mar 22 04:31:42 2004 UTC (20 years, 2 months ago) by mcbride
Branch: MAIN
CVS Tags: OPENBSD_3_5_BASE, OPENBSD_3_5
Changes since 1.95: +8 -3 lines
Diff to previous 1.95 (colored)

Make sure pfsync is brought up before carp.

ok deraadt@

Revision 1.95 / (download) - annotate - [select for diffs], Sat Mar 13 00:59:02 2004 UTC (20 years, 2 months ago) by mcbride
Branch: MAIN
Changes since 1.94: +5 -5 lines
Diff to previous 1.94 (colored)

Delay pfsync(4) configuration, as the syncif has to be configured in
advance. From Thorsten Lockert.

Revision 1.94 / (download) - annotate - [select for diffs], Wed Jan 14 04:41:02 2004 UTC (20 years, 4 months ago) by deraadt
Branch: MAIN
Changes since 1.93: +1 -2 lines
Diff to previous 1.93 (colored)

ok, it took quite a bit of prodding but itojun finally explained why the
extra sleep 1 is in here, and we came to the conclusion it is safe to
delete it.  whee.

Revision 1.93 / (download) - annotate - [select for diffs], Tue Jan 13 08:36:57 2004 UTC (20 years, 4 months ago) by deraadt
Branch: MAIN
Changes since 1.92: +3 -3 lines
Diff to previous 1.92 (colored)

repair v6 lo0 documentation

Revision 1.92 / (download) - annotate - [select for diffs], Sun Jan 11 06:07:16 2004 UTC (20 years, 4 months ago) by deraadt
Branch: MAIN
Changes since 1.91: +6 -6 lines
Diff to previous 1.91 (colored)

add loopback routes late

Revision 1.91 / (download) - annotate - [select for diffs], Fri Jan 9 10:02:23 2004 UTC (20 years, 4 months ago) by deraadt
Branch: MAIN
Changes since 1.90: +21 -21 lines
Diff to previous 1.90 (colored)

create all routes with -q; markus ok

Revision 1.90 / (download) - annotate - [select for diffs], Thu Dec 4 01:19:37 2003 UTC (20 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.89: +6 -2 lines
Diff to previous 1.89 (colored)

Need to do "ifconfig create" for bridge interfaces too.

Revision 1.89 / (download) - annotate - [select for diffs], Wed Dec 3 13:28:36 2003 UTC (20 years, 5 months ago) by markus
Branch: MAIN
Changes since 1.88: +6 -2 lines
Diff to previous 1.88 (colored)

add support for ifconfig clone; from netbsd; ok deraadt, henning

Revision 1.88 / (download) - annotate - [select for diffs], Mon Oct 20 17:53:32 2003 UTC (20 years, 7 months ago) by david
Branch: MAIN
Changes since 1.87: +6 -6 lines
Diff to previous 1.87 (colored)

delay carp initialization until after physical interfaces are configured
ok mcbride@ henning@ deraadt@ todd@

Revision 1.87 / (download) - annotate - [select for diffs], Wed Aug 27 11:49:36 2003 UTC (20 years, 8 months ago) by henning
Branch: MAIN
CVS Tags: OPENBSD_3_4_BASE, OPENBSD_3_4
Changes since 1.86: +8 -3 lines
Diff to previous 1.86 (colored)

only try to set hostname to what /etc/myname says if that file actually exists,
otherwise preserve `hostname`
netbooted machines can live perfectly fine without it; they get their hostname
earlier.

ok krw@ cedric@

Revision 1.86 / (download) - annotate - [select for diffs], Sun Feb 16 23:25:40 2003 UTC (21 years, 3 months ago) by krw
Branch: MAIN
CVS Tags: OPENBSD_3_3_BASE, OPENBSD_3_3
Changes since 1.85: +2 -1 lines
Diff to previous 1.85 (colored)

Fix up some DNS verbiage to make it consistant.

Fix up default route selection by

a) Forcing user to explicitly chose 'dhcp' as a mechanism for
specifying a default route, rather than guessing based on one or more
interfaces being configured by dhcp.

b) If the user specified default route does not work, re-present the
existing default route rather than losing it.

c) Move default route selection to after nameserver activation so the
user can specify a hostname as the default route.

Change /etc/netstart so that /etc/mygate wins if a default route was
already specified (i.e. by dhcp).

ok deraadt@.

Revision 1.85 / (download) - annotate - [select for diffs], Thu May 16 20:48:25 2002 UTC (22 years ago) by todd
Branch: MAIN
CVS Tags: OPENBSD_3_2_BASE, OPENBSD_3_2
Changes since 1.84: +4 -1 lines
Diff to previous 1.84 (colored)

ignore non-existent cases where '$if' evaluates to '*'.
From André Lucas <andre@ae-35.com>, fixes pr # 2658.
'Looks good' from miod@, millert@, and krw@.

Revision 1.84 / (download) - annotate - [select for diffs], Sat Feb 23 01:55:24 2002 UTC (22 years, 2 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_3_1_BASE, OPENBSD_3_1
Changes since 1.83: +14 -13 lines
Diff to previous 1.83 (colored)

re-add support for $if expansion; hamajima@nagoya.ydc.co.jp

Revision 1.83 / (download) - annotate - [select for diffs], Thu Feb 21 02:32:01 2002 UTC (22 years, 3 months ago) by miod
Branch: MAIN
Changes since 1.82: +199 -140 lines
Diff to previous 1.82 (colored)

Change the network components initialization order.
Change from:
o all interfaces
o all bridges
o routes
to:
o physical interfaces
o routes
o gif and gre interfaces
o bridges

Fixeski PR #2400.
Manual page updates coming soon.
Ok angelos@ chris@ deraadt@

Revision 1.82 / (download) - annotate - [select for diffs], Tue Jul 31 08:27:35 2001 UTC (22 years, 9 months ago) by hugh
Branch: MAIN
CVS Tags: OPENBSD_3_0_BASE, OPENBSD_3_0
Changes since 1.81: +2 -2 lines
Diff to previous 1.81 (colored)

a space before a redirect

Revision 1.81 / (download) - annotate - [select for diffs], Fri Jul 6 05:53:17 2001 UTC (22 years, 10 months ago) by angelos
Branch: MAIN
Changes since 1.80: +4 -1 lines
Diff to previous 1.80 (colored)

Also, source /etc/rc.conf so we can pull in the
multicast_host/multicast_router settings; this is useful if one
flushes the routing table and re-initializes.

We really need a netconfig tool of sorts.

Revision 1.80 / (download) - annotate - [select for diffs], Fri Jul 6 05:44:40 2001 UTC (22 years, 10 months ago) by angelos
Branch: MAIN
Changes since 1.79: +2 -2 lines
Diff to previous 1.79 (colored)

Use "route -n show -inet" to determine the default multicast iface.

Revision 1.79 / (download) - annotate - [select for diffs], Tue Jul 3 03:28:19 2001 UTC (22 years, 10 months ago) by deraadt
Branch: MAIN
Changes since 1.78: +1 -4 lines
Diff to previous 1.78 (colored)

pull in rc.conf early so that pf(1) startup is right; tested by jasoni, comments from millert

Revision 1.78 / (download) - annotate - [select for diffs], Wed May 30 02:11:08 2001 UTC (22 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.77: +1 -17 lines
Diff to previous 1.77 (colored)

Remove ipf.  Darren Reed has interpreted his (old, new, whichever)
licence in a way that makes ipf not free according to the rules we
established over 5 years ago, at www.openbsd.org/goals.html (and those
same basic rules govern the other *BSD projects too).  Specifically,
Darren says that modified versions are not permitted.  But software
which OpenBSD uses and redistributes must be free to all (be they
people or companies), for any purpose they wish to use it, including
modification, use, peeing on, or even integration into baby mulching
machines or atomic bombs to be dropped on Australia.  Furthermore, we
know of a number of companies using ipf with modification like us, who
are now in the same situation, and we hope that some of them will work
with us to fill this gap that now exists in OpenBSD (temporarily, we
hope).

Revision 1.77 / (download) - annotate - [select for diffs], Tue Mar 13 21:15:09 2001 UTC (23 years, 2 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_9_BASE, OPENBSD_2_9
Changes since 1.76: +5 -5 lines
Diff to previous 1.76 (colored)

spelling; maurice@maurice.wan.nl

Revision 1.76 / (download) - annotate - [select for diffs], Tue Feb 6 23:05:45 2001 UTC (23 years, 3 months ago) by todd
Branch: MAIN
Changes since 1.75: +2 -2 lines
Diff to previous 1.75 (colored)

ignore blank lines in addition to comments
fixes pr#1660 from wilfried@telia.com .. Thanks!

Revision 1.75 / (download) - annotate - [select for diffs], Wed Jan 10 22:17:10 2001 UTC (23 years, 4 months ago) by jason
Branch: MAIN
Changes since 1.74: +10 -2 lines
Diff to previous 1.74 (colored)

support !command in bridgename.if files, too

Revision 1.74 / (download) - annotate - [select for diffs], Mon Nov 27 17:14:00 2000 UTC (23 years, 5 months ago) by millert
Branch: MAIN
Changes since 1.73: +2 -2 lines
Diff to previous 1.73 (colored)

Use -n to test if a variable is non-zero.  Otherwise, if the variable's
contents start with a '-' test becomes unhappy (since it interprets it
as another option).

Revision 1.73 / (download) - annotate - [select for diffs], Wed Nov 8 19:09:29 2000 UTC (23 years, 6 months ago) by todd
Branch: MAIN
Changes since 1.72: +5 -3 lines
Diff to previous 1.72 (colored)

This fixes pr 1481, we now handle args > 6 in /etc/hostname.if in the
cases where we did not previously handle them.
Thanks to Scott Atwood <atwood@cs.stanford.edu> for reminding us of this.

Revision 1.72 / (download) - annotate - [select for diffs], Sat Sep 2 15:59:29 2000 UTC (23 years, 8 months ago) by todd
Branch: MAIN
CVS Tags: OPENBSD_2_8_BASE, OPENBSD_2_8
Changes since 1.71: +3 -1 lines
Diff to previous 1.71 (colored)


subtle bug .. global variables in a while loop need reset 'just incase'
With:
	hostname.fxp0 having a last line of:
		inet6 alias 3ffe:...
	and hostname.gif0 having a first two lines of:
		giftunnel 1.2.3.4
		dest 1.2.4.3
	We end up with the command:
		ifconfig gif0 giftunnel alias 1.2.3.4  1.2.4.3
.. which is clearly wrong and fixed by this change

Revision 1.71 / (download) - annotate - [select for diffs], Sun Jun 18 19:02:24 2000 UTC (23 years, 11 months ago) by todd
Branch: MAIN
Changes since 1.70: +1 -4 lines
Diff to previous 1.70 (colored)

rc.conf now parses ${local_rcconf} internally; closes pr 1259

Revision 1.70 / (download) - annotate - [select for diffs], Mon May 8 21:44:39 2000 UTC (24 years ago) by todd
Branch: MAIN
CVS Tags: OPENBSD_2_7_BASE, OPENBSD_2_7
Changes since 1.69: +3 -0 lines
Diff to previous 1.69 (colored)

fix dhcp 'NONE' ness from install to allow media parsing to work
.. ok deraadt@, millert@

Revision 1.69 / (download) - annotate - [select for diffs], Fri Apr 21 21:27:34 2000 UTC (24 years, 1 month ago) by deraadt
Branch: MAIN
Changes since 1.68: +4 -1 lines
Diff to previous 1.68 (colored)

rc.conf.local support, inspired by chuck yerkes

Revision 1.68 / (download) - annotate - [select for diffs], Tue Apr 4 13:44:51 2000 UTC (24 years, 1 month ago) by millert
Branch: MAIN
Changes since 1.67: +2 -2 lines
Diff to previous 1.67 (colored)

Remove the -E flag from ipf as it is implicitly enabled and using
the -E flag here causes the kernel to printf 'IP Filter: already
initialized'.

Revision 1.67 / (download) - annotate - [select for diffs], Sat Mar 18 19:45:45 2000 UTC (24 years, 2 months ago) by deraadt
Branch: MAIN
Changes since 1.66: +21 -18 lines
Diff to previous 1.66 (colored)

silence all extra route addition printouts

Revision 1.66 / (download) - annotate - [select for diffs], Fri Mar 17 17:40:31 2000 UTC (24 years, 2 months ago) by itojun
Branch: MAIN
Changes since 1.65: +34 -7 lines
Diff to previous 1.65 (colored)

correct reject route installations for IPv6.  improve comments.

Revision 1.65 / (download) - annotate - [select for diffs], Sun Mar 12 04:18:47 2000 UTC (24 years, 2 months ago) by itojun
Branch: MAIN
Changes since 1.64: +6 -1 lines
Diff to previous 1.64 (colored)

disallow packets to malicious 6to4 prefix, based on
http://playground.iijlab.net/i-d/draft-itojun-ipv6-transition-abuse-00.txt

Revision 1.64 / (download) - annotate - [select for diffs], Fri Mar 10 13:21:51 2000 UTC (24 years, 2 months ago) by todd
Branch: MAIN
Changes since 1.63: +3 -3 lines
Diff to previous 1.63 (colored)

fix non behavior
with this `!' lines in /etc/hostname.* run even without certain lines
(like a comment) preceeding it.

Revision 1.63 / (download) - annotate - [select for diffs], Mon Jan 10 02:04:07 2000 UTC (24 years, 4 months ago) by todd
Branch: MAIN
Changes since 1.62: +9 -4 lines
Diff to previous 1.62 (colored)

allow arbitrary commands in /etc/hostname.* files if the line starts with '!'

Revision 1.62 / (download) - annotate - [select for diffs], Sun Jan 2 06:50:09 2000 UTC (24 years, 4 months ago) by deraadt
Branch: MAIN
Changes since 1.61: +2 -2 lines
Diff to previous 1.61 (colored)

rtsol case can configure the interface up, since it would be nice to finish
DAD before the actual rtsol(8) run happens later.  and since it will rtsol,
it is going to be up in any case.

Revision 1.61 / (download) - annotate - [select for diffs], Sun Jan 2 06:43:42 2000 UTC (24 years, 4 months ago) by itojun
Branch: MAIN
Changes since 1.60: +2 -2 lines
Diff to previous 1.60 (colored)

one more indentation fix.

Revision 1.60 / (download) - annotate - [select for diffs], Sun Jan 2 06:42:13 2000 UTC (24 years, 4 months ago) by itojun
Branch: MAIN
Changes since 1.59: +12 -12 lines
Diff to previous 1.59 (colored)

indentation fix (todd's part)

Revision 1.59 / (download) - annotate - [select for diffs], Sun Jan 2 06:39:08 2000 UTC (24 years, 4 months ago) by todd
Branch: MAIN
Changes since 1.58: +2 -1 lines
Diff to previous 1.58 (colored)

fix rtsold case, reset cmd for each iteration!

Revision 1.58 / (download) - annotate - [select for diffs], Sun Jan 2 06:32:44 2000 UTC (24 years, 4 months ago) by itojun
Branch: MAIN
Changes since 1.57: +2 -1 lines
Diff to previous 1.57 (colored)

allow options after "rtsol".
XXX both "dhcp" and "rtsol" has keyword *down* at the end.  is it okay?

Revision 1.57 / (download) - annotate - [select for diffs], Sun Jan 2 05:21:55 2000 UTC (24 years, 4 months ago) by itojun
Branch: MAIN
Changes since 1.56: +7 -1 lines
Diff to previous 1.56 (colored)

echo "IPv6 autoconf: interfaces" before invoking rtsol.
sleep for net.inet6.ip6.dad_count seconds to ensure that IPv6 DAD is completed.
TODO: rtsold (rc.conf line), manpage

Revision 1.56 / (download) - annotate - [select for diffs], Sun Jan 2 05:14:52 2000 UTC (24 years, 4 months ago) by itojun
Branch: MAIN
Changes since 1.55: +17 -1 lines
Diff to previous 1.55 (colored)

ipv6 autoconf on hosts (non-routers).

to do this,
1. in sysctl.conf, add these lines:
	net.inet6.ip6.forwarding=0
	net.inet6.ip6.accept_rtadv=1
2. in hostname.foo, add
	rtsol

specifying two or more interfaces with "rtsol" may result in strange
behavior - ipv6 spec does not permit multi-interface node to be autoconfig'ed.

Revision 1.55 / (download) - annotate - [select for diffs], Sun Jan 2 04:38:17 2000 UTC (24 years, 4 months ago) by todd
Branch: MAIN
Changes since 1.54: +56 -24 lines
Diff to previous 1.54 (colored)

add to hostname.* parsing:
- multiple entries support (read: aliases)
- inet6 support
- support for comments (#)
(look for hostname.if(5) commit for syntax details)

Revision 1.54 / (download) - annotate - [select for diffs], Fri Dec 31 04:32:53 1999 UTC (24 years, 4 months ago) by itojun
Branch: MAIN
Changes since 1.53: +15 -9 lines
Diff to previous 1.53 (colored)

install IPv6 reject routes only if kernel is capable of IPv6.

Revision 1.53 / (download) - annotate - [select for diffs], Thu Dec 9 14:22:38 1999 UTC (24 years, 5 months ago) by itojun
Branch: MAIN
Changes since 1.52: +9 -1 lines
Diff to previous 1.52 (colored)

avoid transmitting invalid IPv6 packets out to the wire.

Revision 1.52 / (download) - annotate - [select for diffs], Thu Dec 9 13:59:57 1999 UTC (24 years, 5 months ago) by itojun
Branch: MAIN
Changes since 1.51: +2 -1 lines
Diff to previous 1.51 (colored)

do not perform IPv6 initialization for loopback interface.
MUST make lo0 up before any IPv6 operations.
it will be considered a pilot error if you don't.
(I prefer to have lo0 initialized automatically)

Revision 1.51 / (download) - annotate - [select for diffs], Wed Sep 1 18:07:34 1999 UTC (24 years, 8 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_6_BASE, OPENBSD_2_6
Changes since 1.50: +3 -2 lines
Diff to previous 1.50 (colored)

support # characters in bridgename.* files; millert

Revision 1.50 / (download) - annotate - [select for diffs], Wed Sep 1 05:07:50 1999 UTC (24 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.49: +33 -50 lines
Diff to previous 1.49 (colored)

cleanup parsing of hostname.* files, and seperate bridge control into
bridgename.* files; all documented in new hostname.if(5) and
bridgename.if(5) man pages

Revision 1.49 / (download) - annotate - [select for diffs], Mon Aug 9 21:49:04 1999 UTC (24 years, 9 months ago) by angelos
Branch: MAIN
Changes since 1.48: +7 -1 lines
Diff to previous 1.48 (colored)

Only parse/setup the hostname.foo file if interface foo exists (this
is useful for laptops with different ethernet cards etc.)

Revision 1.48 / (download) - annotate - [select for diffs], Mon Mar 29 22:09:58 1999 UTC (25 years, 1 month ago) by niklas
Branch: MAIN
CVS Tags: OPENBSD_2_5_BASE, OPENBSD_2_5
Changes since 1.47: +30 -7 lines
Diff to previous 1.47 (colored)

New multicast route setup style

Revision 1.47 / (download) - annotate - [select for diffs], Fri Mar 26 14:34:31 1999 UTC (25 years, 1 month ago) by niklas
Branch: MAIN
Changes since 1.46: +59 -44 lines
Diff to previous 1.46 (colored)

Add bridge interface handling

Revision 1.46 / (download) - annotate - [select for diffs], Mon Mar 1 05:04:24 1999 UTC (25 years, 2 months ago) by millert
Branch: MAIN
Changes since 1.45: +6 -3 lines
Diff to previous 1.45 (colored)

Add support in /etc/hostname.xxx for files of the format:
    up [options]
Any of the following may or may not be set:
    $name $mask $bcaddr $extras

Revision 1.45 / (download) - annotate - [select for diffs], Wed Oct 28 19:17:10 1998 UTC (25 years, 6 months ago) by millert
Branch: MAIN
Changes since 1.44: +30 -15 lines
Diff to previous 1.44 (colored)

Kill the awful hack used to match and split /etc/hostname.* We now use
a function, isalphanumeric, to determine whether an interface name is
likely to be valid.  This means that things like /etc/hostname.le0.bak,
/etc/hostname.le0#, /etc/hostname.le0~, etc. will be ignored as they
should.  There is no longer an implicate assumption that /etc/hostname.*
only contains a single '.'.

Revision 1.44 / (download) - annotate - [select for diffs], Tue Oct 6 23:25:21 1998 UTC (25 years, 7 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_4_BASE, OPENBSD_2_4
Changes since 1.43: +10 -11 lines
Diff to previous 1.43 (colored)

move ipnat to end of netstart, to support dhcp+ipnat

Revision 1.43 / (download) - annotate - [select for diffs], Fri Sep 18 18:42:10 1998 UTC (25 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.42: +2 -1 lines
Diff to previous 1.42 (colored)

apply media directives on dhcp interfaces

Revision 1.42 / (download) - annotate - [select for diffs], Thu Sep 10 16:01:32 1998 UTC (25 years, 8 months ago) by marc
Branch: MAIN
Changes since 1.41: +29 -21 lines
Diff to previous 1.41 (colored)

better way of handling dhcp client; Jason Ish <jbi130@mail.usask.ca>

Revision 1.41 / (download) - annotate - [select for diffs], Tue Sep 8 20:26:41 1998 UTC (25 years, 8 months ago) by marc
Branch: MAIN
Changes since 1.40: +10 -5 lines
Diff to previous 1.40 (colored)

dhcp client stuff. "Angelos D. Keromytis" <angelos@dsl.cis.upenn.edu>

Revision 1.40 / (download) - annotate - [select for diffs], Mon Aug 24 09:32:50 1998 UTC (25 years, 9 months ago) by downsj
Branch: MAIN
Changes since 1.39: +7 -4 lines
Diff to previous 1.39 (colored)

You can't use -interface default when there's no default gateway
set (yet).  Use -interface $hostname if mygate doesn't exist so that
this actually works on routers.

Revision 1.39 / (download) - annotate - [select for diffs], Sat Jul 4 13:55:51 1998 UTC (25 years, 10 months ago) by deraadt
Branch: MAIN
Changes since 1.38: +2 -2 lines
Diff to previous 1.38 (colored)

put 224 route on default, to avoid a hostname lookup

Revision 1.38 / (download) - annotate - [select for diffs], Fri May 22 04:25:50 1998 UTC (26 years ago) by deraadt
Branch: MAIN
Changes since 1.37: +5 -5 lines
Diff to previous 1.37 (colored)

use route -n, what the heck

Revision 1.37 / (download) - annotate - [select for diffs], Sat Mar 28 00:11:00 1998 UTC (26 years, 1 month ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_3_BASE, OPENBSD_2_3
Changes since 1.36: +4 -4 lines
Diff to previous 1.36 (colored)

s/^nat/ipnat/

Revision 1.36 / (download) - annotate - [select for diffs], Mon Feb 23 20:47:35 1998 UTC (26 years, 2 months ago) by niklas
Branch: MAIN
Changes since 1.35: +1 -2 lines
Diff to previous 1.35 (colored)

remove trailing blank line

Revision 1.35 / (download) - annotate - [select for diffs], Sat Feb 7 20:51:50 1998 UTC (26 years, 3 months ago) by deraadt
Branch: MAIN
Changes since 1.34: +1 -5 lines
Diff to previous 1.34 (colored)

ipforward is in sysctl.conf now

Revision 1.34 / (download) - annotate - [select for diffs], Sun Dec 21 01:17:21 1997 UTC (26 years, 5 months ago) by deraadt
Branch: MAIN
Changes since 1.33: +2 -2 lines
Diff to previous 1.33 (colored)

ugh

Revision 1.33 / (download) - annotate - [select for diffs], Sat Dec 20 23:19:30 1997 UTC (26 years, 5 months ago) by deraadt
Branch: MAIN
Changes since 1.32: +5 -1 lines
Diff to previous 1.32 (colored)

ipforwarding option in rc.conf

Revision 1.32 / (download) - annotate - [select for diffs], Sat Nov 29 02:03:43 1997 UTC (26 years, 5 months ago) by kstailey
Branch: MAIN
Changes since 1.31: +2 -2 lines
Diff to previous 1.31 (colored)

NAT requires IPF

Revision 1.31 / (download) - annotate - [select for diffs], Tue Nov 4 09:15:31 1997 UTC (26 years, 6 months ago) by deraadt
Branch: MAIN
Changes since 1.30: +2 -2 lines
Diff to previous 1.30 (colored)

kill spaces at ends of lines; m4

Revision 1.30 / (download) - annotate - [select for diffs], Tue Oct 14 20:34:55 1997 UTC (26 years, 7 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_2_BASE, OPENBSD_2_2
Changes since 1.29: +4 -4 lines
Diff to previous 1.29 (colored)

set hostname/domainname before running rc.conf; m4@umn.edu

Revision 1.29 / (download) - annotate - [select for diffs], Thu Sep 4 01:12:23 1997 UTC (26 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.28: +3 -39 lines
Diff to previous 1.28 (colored)

fork netstart; new child is rc.conf

Revision 1.28 / (download) - annotate - [select for diffs], Mon Aug 25 20:50:37 1997 UTC (26 years, 8 months ago) by millert
Branch: MAIN
Changes since 1.27: +3 -3 lines
Diff to previous 1.27 (colored)

Explicately pass -host flag to route(8) to avoid confusion with networks.

Revision 1.27 / (download) - annotate - [select for diffs], Tue Aug 19 21:55:15 1997 UTC (26 years, 9 months ago) by niklas
Branch: MAIN
Changes since 1.26: +3 -1 lines
Diff to previous 1.26 (colored)

Add hook for rpc.lockd, make nfsd flags settable in netstart

Revision 1.26 / (download) - annotate - [select for diffs], Thu Jul 31 02:23:46 1997 UTC (26 years, 9 months ago) by downsj
Branch: MAIN
Changes since 1.25: +2 -1 lines
Diff to previous 1.25 (colored)

Make quotas optional; wedged into netstart for the time being.
/etc/rc.conf, anyone?

Revision 1.25 / (download) - annotate - [select for diffs], Wed Jul 30 21:35:15 1997 UTC (26 years, 9 months ago) by deraadt
Branch: MAIN
Changes since 1.24: +2 -2 lines
Diff to previous 1.24 (colored)

do not run routed by default

Revision 1.24 / (download) - annotate - [select for diffs], Mon Jul 28 19:31:47 1997 UTC (26 years, 9 months ago) by kstailey
Branch: MAIN
Changes since 1.23: +8 -9 lines
Diff to previous 1.23 (colored)

Move configuration of loopback interface to before all other interfaces.
Allows the use of local caching-only nameserver with no "nameserver"
entry in /etc/resolv.conf to configure a route between the hostname
and loopback.

Revision 1.23 / (download) - annotate - [select for diffs], Fri Jul 25 00:06:03 1997 UTC (26 years, 10 months ago) by provos
Branch: MAIN
Changes since 1.22: +2 -2 lines
Diff to previous 1.22 (colored)

earlier start of keymanagement

Revision 1.22 / (download) - annotate - [select for diffs], Thu Jul 24 22:11:59 1997 UTC (26 years, 10 months ago) by deraadt
Branch: MAIN
Changes since 1.21: +2 -2 lines
Diff to previous 1.21 (colored)

make amd use /tmp_mnt by default

Revision 1.21 / (download) - annotate - [select for diffs], Tue Jul 22 10:02:47 1997 UTC (26 years, 10 months ago) by provos
Branch: MAIN
Changes since 1.20: +2 -1 lines
Diff to previous 1.20 (colored)

start the photuris daemon per default. hilfe.

Revision 1.20 / (download) - annotate - [select for diffs], Tue Jun 17 13:13:48 1997 UTC (26 years, 11 months ago) by niklas
Branch: MAIN
Changes since 1.19: +2 -1 lines
Diff to previous 1.19 (colored)

Put in hooks to start ypserv with flags

Revision 1.19 / (download) - annotate - [select for diffs], Tue Jun 17 10:20:06 1997 UTC (26 years, 11 months ago) by niklas
Branch: MAIN
Changes since 1.18: +2 -1 lines
Diff to previous 1.18 (colored)

Put in hooks to start rpc.yppasswdd with flags

Revision 1.18 / (download) - annotate - [select for diffs], Tue Apr 15 09:42:33 1997 UTC (27 years, 1 month ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_1_BASE, OPENBSD_2_1
Changes since 1.17: +1 -3 lines
Diff to previous 1.17 (colored)

kill route flush until .. hmm kernel routing socket bug or something

Revision 1.17 / (download) - annotate - [select for diffs], Wed Apr 9 03:00:05 1997 UTC (27 years, 1 month ago) by kstailey
Branch: MAIN
Changes since 1.16: +13 -1 lines
Diff to previous 1.16 (colored)

add NAT startup

Revision 1.16 / (download) - annotate - [select for diffs], Mon Apr 7 22:18:05 1997 UTC (27 years, 1 month ago) by rees
Branch: MAIN
Changes since 1.15: +3 -1 lines
Diff to previous 1.15 (colored)

flush all old routes before adding new interfaces or routes.
ref: netbsd pr3228/misc, Matthias Scheler

Revision 1.15 / (download) - annotate - [select for diffs], Mon Mar 3 01:13:11 1997 UTC (27 years, 2 months ago) by downsj
Branch: MAIN
Changes since 1.14: +2 -2 lines
Diff to previous 1.14 (colored)

fix typo

Revision 1.14 / (download) - annotate - [select for diffs], Tue Feb 11 18:46:08 1997 UTC (27 years, 3 months ago) by deraadt
Branch: MAIN
Changes since 1.13: +7 -6 lines
Diff to previous 1.13 (colored)

add default route before fiddling with loopback route to avoid DNS problems; m4@umn.edu, #97

Revision 1.13 / (download) - annotate - [select for diffs], Mon Feb 3 12:04:44 1997 UTC (27 years, 3 months ago) by deraadt
Branch: MAIN
Changes since 1.12: +1 -18 lines
Diff to previous 1.12 (colored)

do ifaliases after /usr/bin exists in nfs diskless env; pr#77, matthieu@laas.fr

Revision 1.12 / (download) - annotate - [select for diffs], Sat Nov 2 00:52:02 1996 UTC (27 years, 6 months ago) by deraadt
Branch: MAIN
Changes since 1.11: +2 -2 lines
Diff to previous 1.11 (colored)

timed off by default

Revision 1.11 / (download) - annotate - [select for diffs], Mon Sep 23 13:06:37 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
CVS Tags: OPENBSD_2_0_BASE, OPENBSD_2_0
Changes since 1.10: +2 -1 lines
Diff to previous 1.10 (colored)

rfc1323 variable

Revision 1.10 / (download) - annotate - [select for diffs], Wed Sep 4 10:25:55 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.9: +4 -1 lines
Diff to previous 1.9 (colored)

control portmap, inetd, and lpd from netstart; idea from tqbf@enteract.com

Revision 1.9 / (download) - annotate - [select for diffs], Tue Aug 27 11:46:20 1996 UTC (27 years, 8 months ago) by deraadt
Branch: MAIN
Changes since 1.8: +2 -2 lines
Diff to previous 1.8 (colored)

224.0.0.0 not 0.0.0.224; from peter@demon.net

Revision 1.8 / (download) - annotate - [select for diffs], Tue Jun 18 15:30:02 1996 UTC (27 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.7: +2 -2 lines
Diff to previous 1.7 (colored)

move std stuff from rc.local to rc

Revision 1.7 / (download) - annotate - [select for diffs], Sun Jun 16 12:57:31 1996 UTC (27 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.6: +8 -7 lines
Diff to previous 1.6 (colored)

install sample commented /etc/ifaliases file; which can now contain #
comments and blank lines. new format is "interface address netmask"
(yes, i changed the order of the entries). inspired by netbsd pr#2474;
gillhaa@ghost.whirlpool.com

Revision 1.6 / (download) - annotate - [select for diffs], Sun Jun 2 21:17:58 1996 UTC (27 years, 11 months ago) by tholo
Branch: MAIN
Changes since 1.5: +5 -1 lines
Diff to previous 1.5 (colored)

Install a multicast route by default

Revision 1.5 / (download) - annotate - [select for diffs], Sun May 26 10:25:24 1996 UTC (27 years, 11 months ago) by deraadt
Branch: MAIN
Changes since 1.4: +1 -2 lines
Diff to previous 1.4 (colored)

sync & label

Revision 1.4 / (download) - annotate - [select for diffs], Tue Jan 9 09:29:27 1996 UTC (28 years, 4 months ago) by dm
Branch: MAIN
Changes since 1.3: +12 -0 lines
Diff to previous 1.3 (colored)

added IP filter to netstat/rc and put examples in /usr/share/ipf

Revision 1.3 / (download) - annotate - [select for diffs], Sat Dec 30 23:38:21 1995 UTC (28 years, 4 months ago) by deraadt
Branch: MAIN
Changes since 1.2: +2 -1 lines
Diff to previous 1.2 (colored)

from netbsd: start mrouted like routed

Revision 1.2 / (download) - annotate - [select for diffs], Mon Dec 18 16:37:10 1995 UTC (28 years, 5 months ago) by deraadt
Branch: MAIN
Changes since 1.1: +17 -1 lines
Diff to previous 1.1 (colored)

/etc/ifaliases support by randy@zyzzyva.com

Revision 1.1.1.1 / (download) - annotate - [select for diffs] (vendor branch), Wed Oct 18 08:37:57 1995 UTC (28 years, 7 months ago) by deraadt
CVS Tags: netbsd_1_1
Changes since 1.1: +0 -0 lines
Diff to previous 1.1 (colored)

initial import of NetBSD tree

Revision 1.1 / (download) - annotate - [select for diffs], Wed Oct 18 08:37:57 1995 UTC (28 years, 7 months ago) by deraadt
Branch: MAIN

Initial revision

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.