Browse Source

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
master
kn 4 years ago
parent
commit
f752bda1d0
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      src/etc/netstart

+ 2
- 2
src/etc/netstart View File

@ -1,6 +1,6 @@
#!/bin/sh -
#
# $OpenBSD: netstart,v 1.202 2020/01/15 00:19:40 kn Exp $
# $OpenBSD: netstart,v 1.203 2020/05/21 11:54:41 kn Exp $
# Turn off Strict Bourne shell mode.
set +o sh
@ -134,7 +134,7 @@ ifstart() {
# Parse the hostname.if(5) file and fill _cmds array with interface
# configuration commands.
set -o noglob
while IFS= read -- _line; do
while IFS= read -r -- _line; do
parse_hn_line $_line
done <$_hn


Loading…
Cancel
Save