From 71eb24f36a971fa54ab9c0d0607e19894746180b Mon Sep 17 00:00:00 2001 From: bapt Date: Sun, 4 Nov 2012 01:00:35 +0000 Subject: Change default prompt to show ~ again for the home directory Submitted by: flo Approved by: eadler --- etc/root/dot.cshrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/root/dot.cshrc b/etc/root/dot.cshrc index 8f75be4..5ce3e36 100644 --- a/etc/root/dot.cshrc +++ b/etc/root/dot.cshrc @@ -26,7 +26,7 @@ if ($?prompt) then if ($uid == 0) then set user = root endif - set prompt = "%n@%m:%/ %# " + set prompt = "%n@%m:%~ %# " set promptchars = "%#" set filec -- cgit v1.1 From 16d8c8419d49d31c013ab6c79dd235675cf4fedc Mon Sep 17 00:00:00 2001 From: marcel Date: Wed, 7 Nov 2012 00:19:30 +0000 Subject: The first line must contain "Content-Type:". Move the $FreeBSD$ keyword line to the comment block underneath. Submitted by: Garrett Cooper --- etc/atf/FreeBSD.conf | 2 +- etc/atf/common.conf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'etc') diff --git a/etc/atf/FreeBSD.conf b/etc/atf/FreeBSD.conf index 23c1fa1..e90a6dc 100644 --- a/etc/atf/FreeBSD.conf +++ b/etc/atf/FreeBSD.conf @@ -1,6 +1,6 @@ -# $FreeBSD$ Content-Type: application/X-atf-config; version="1" +# $FreeBSD$ # # Configuration file for the FreeBSD test suite. # diff --git a/etc/atf/common.conf b/etc/atf/common.conf index 2ac08da..392b57b 100644 --- a/etc/atf/common.conf +++ b/etc/atf/common.conf @@ -1,6 +1,6 @@ -# $FreeBSD$ Content-Type: application/X-atf-config; version="1" +# $FreeBSD$ # # Sample configuration file for properties affecting all test suites. # -- cgit v1.1 From 203d15d5232a6eced66bad7f6b56a18d8524dde7 Mon Sep 17 00:00:00 2001 From: n_hibma Date: Thu, 8 Nov 2012 20:34:12 +0000 Subject: Not only load pccard_ether settings, also load network settings. This is only a problem when a /etc/rc.conf.d/network file is being used. PR: conf/160373 Submitted by: n_hibma MFC after: 1 week --- etc/pccard_ether | 1 + 1 file changed, 1 insertion(+) (limited to 'etc') diff --git a/etc/pccard_ether b/etc/pccard_ether index 841c1a0..5bd9c33 100755 --- a/etc/pccard_ether +++ b/etc/pccard_ether @@ -123,4 +123,5 @@ else fi load_rc_config pccard_ether +load_rc_config network run_rc_command $args -- cgit v1.1 From 413379c5a87ac03f7f1da5ca0f2023b5d3c4e71c Mon Sep 17 00:00:00 2001 From: eadler Date: Thu, 15 Nov 2012 15:06:15 +0000 Subject: Only pass ip[46].addr when _addrl contains a value Submitted by: crees Reviewed by: Mike Jakubik Approved by: cperciva MFC after: 2 weeks --- etc/rc.d/jail | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.d/jail b/etc/rc.d/jail index 0718fa8..ff2f312 100755 --- a/etc/rc.d/jail +++ b/etc/rc.d/jail @@ -656,7 +656,8 @@ jail_start() done eval ${_setfib} jail -n ${_jail} ${_flags} -i -c path=${_rootdir} host.hostname=${_hostname} \ - ip4.addr=\"${_addrl}\" ip6.addr=\"${_addr6l}\" ${_parameters} command=${_exec_start} > ${_tmp_jail} 2>&1 \ + ${_addrl:+ip4.addr=\"${_addrl}\"} ${_addr6l:+ip6.addr=\"${_addr6l}\"} \ + ${_parameters} command=${_exec_start} > ${_tmp_jail} 2>&1 \ Date: Thu, 15 Nov 2012 20:37:38 +0000 Subject: Using set -x produces output on stderr instead of stdout. It also doesn't work with make -s. Prefer the use of builtin make features. PR: misc/126312 Reported by: Nejc Skoberne Submitted by: bdrewery Approved by: cperciva MFC after: 1 week --- etc/Makefile | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index bbb5018..c18908f 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -220,8 +220,7 @@ distribution: cd ${.CURDIR}; ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 0500 \ ${BSM_ETC_EXEC_FILES} ${BSM_ETC_DIR} .if ${MK_BIND_MTREE} != "no" - @if [ ! -e ${DESTDIR}/etc/namedb ]; then \ - set -x; \ + if [ ! -e ${DESTDIR}/etc/namedb ]; then \ ln -s ../var/named/etc/namedb ${DESTDIR}/etc/namedb; \ fi .endif @@ -267,9 +266,8 @@ distribution: .if ${MK_MAIL} != "no" cd ${.CURDIR}/mail; ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m 644 \ ${ETCMAIL} ${DESTDIR}/etc/mail - @if [ -d ${DESTDIR}/etc/mail -a -f ${DESTDIR}/etc/mail/aliases -a \ + if [ -d ${DESTDIR}/etc/mail -a -f ${DESTDIR}/etc/mail/aliases -a \ ! -f ${DESTDIR}/etc/aliases ]; then \ - set -x; \ ln -s mail/aliases ${DESTDIR}/etc/aliases; \ fi .endif -- cgit v1.1 From 8d33709c9bf9e25c5dbf6ec1719f8ddea127a96b Mon Sep 17 00:00:00 2001 From: eadler Date: Fri, 16 Nov 2012 04:25:35 +0000 Subject: dot.login is supposed to be for bourne shell, not csh Pointyhat to: me Approved by: cperciva (implicit) --- etc/root/dot.login | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/root/dot.login b/etc/root/dot.login index 3a011ea..3032ef9 100644 --- a/etc/root/dot.login +++ b/etc/root/dot.login @@ -6,4 +6,4 @@ # # Uncomment to display a random cookie each login: -# if ( -x /usr/games/fortune ) /usr/games/fortune -s +# [ -x /usr/games/fortune ] && /usr/games/fortune -s -- cgit v1.1 From fa8234872207f45a746159e4957384ee455825df Mon Sep 17 00:00:00 2001 From: eadler Date: Fri, 16 Nov 2012 14:25:13 +0000 Subject: last commit was a mistake Pointyhat to: me (for real) Approved by: cperciva (implicit) --- etc/root/dot.login | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/root/dot.login b/etc/root/dot.login index 3032ef9..3a011ea 100644 --- a/etc/root/dot.login +++ b/etc/root/dot.login @@ -6,4 +6,4 @@ # # Uncomment to display a random cookie each login: -# [ -x /usr/games/fortune ] && /usr/games/fortune -s +# if ( -x /usr/games/fortune ) /usr/games/fortune -s -- cgit v1.1 From c8437905c250b0fafca84b0a4b5978ecca12497e Mon Sep 17 00:00:00 2001 From: hrs Date: Sat, 17 Nov 2012 18:11:10 +0000 Subject: Add check_namevarlist() to check if ${name}_var is reserved in rc.subr or not. --- etc/rc.subr | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'etc') diff --git a/etc/rc.subr b/etc/rc.subr index 5c94097..bec5e7e 100644 --- a/etc/rc.subr +++ b/etc/rc.subr @@ -1724,6 +1724,23 @@ check_kern_features() fi } +# check_namevarlist var +# Return "0" if ${name}_var is reserved in rc.subr. + +_rc_namevarlist="program chroot chdir flags fib nice user group groups" +check_namevarlist() +{ + local _v + + for _v in $_rc_namevarlist; do + case $1 in + $_v) return 0 ;; + esac + done + + return 1 +} + # _echoonce var msg mode # mode=0: Echo $msg if ${$var} is empty. # After doing echo, a string is set to ${$var}. -- cgit v1.1 From 0f95bf629a65a1e244096455137c8bb58648107f Mon Sep 17 00:00:00 2001 From: hrs Date: Sat, 17 Nov 2012 21:44:02 +0000 Subject: Use -fib N modifier to add/delete a route to/from multiple FIBs. --- etc/rc.d/routing | 44 +++++++++++--------------------------------- 1 file changed, 11 insertions(+), 33 deletions(-) (limited to 'etc') diff --git a/etc/rc.d/routing b/etc/rc.d/routing index 7e4a8ff..2654b3d 100755 --- a/etc/rc.d/routing +++ b/etc/rc.d/routing @@ -139,29 +139,20 @@ static_inet() static_inet6() { - local _action i fibs + local _action fibmod fibs _action=$1 # get the number of FIBs supported. - fibs=`sysctl -n net.fibs` - : ${fibs:=1} + fibs=$((`${SYSCTL_N} net.fibs` - 1)) + if [ -n "$fibs" ]; then + fibmod="-fib 0-$fibs" + else + fibmod= + fi # disallow "internal" addresses to appear on the wire - route ${_action} -inet6 ::ffff:0.0.0.0 -prefixlen 96 ::1 -reject - route ${_action} -inet6 ::0.0.0.0 -prefixlen 96 ::1 -reject - i=1 - if test ${i} -lt ${fibs}; then - printf "Also installing reject routes for FIBs" - while test ${i} -lt ${fibs}; do - setfib -F ${i} route -q ${_action} \ - -inet6 ::ffff:0.0.0.0 -prefixlen 96 ::1 -reject - setfib -F ${i} route -q ${_action} \ - -inet6 ::0.0.0.0 -prefixlen 96 ::1 -reject - printf " %d" ${i} - i=$((i + 1)) - done - printf "\n" - fi + route ${_action} -inet6 ::ffff:0.0.0.0 -prefixlen 96 ::1 -reject ${fibmod} + route ${_action} -inet6 ::0.0.0.0 -prefixlen 96 ::1 -reject ${fibmod} case ${ipv6_defaultrouter} in [Nn][Oo] | '') @@ -233,21 +224,8 @@ static_inet6() # for the host case, you will allow to omit the identifiers. # Under this configuration, the packets will go to the default # interface. - route ${_action} -inet6 fe80:: -prefixlen 10 ::1 -reject - route ${_action} -inet6 ff02:: -prefixlen 16 ::1 -reject - i=1 - if test ${i} -lt ${fibs}; then - printf "Also installing reject routes for FIBs" - while test ${i} -lt ${fibs}; do - setfib -F ${i} route -q ${_action} \ - -inet6 fe80:: -prefixlen 10 ::1 -reject - setfib -F ${i} route -q ${_action} \ - -inet6 ff02:: -prefixlen 16 ::1 -reject - printf " %d" ${i} - i=$((i + 1)) - done - printf "\n" - fi + route ${_action} -inet6 fe80:: -prefixlen 10 ::1 -reject ${fibmod} + route ${_action} -inet6 ff02:: -prefixlen 16 ::1 -reject ${fibmod} case ${ipv6_default_interface} in '') -- cgit v1.1 From a65c6ba8dc4fe539c84c459e98c5c1ff37462b61 Mon Sep 17 00:00:00 2001 From: hrs Date: Sun, 18 Nov 2012 11:22:15 +0000 Subject: Fix condition to check if the maximum number of FIBs is greater than 0 or not. Spotted by: zont --- etc/rc.d/routing | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.d/routing b/etc/rc.d/routing index 2654b3d..0fe86c7 100755 --- a/etc/rc.d/routing +++ b/etc/rc.d/routing @@ -144,7 +144,7 @@ static_inet6() # get the number of FIBs supported. fibs=$((`${SYSCTL_N} net.fibs` - 1)) - if [ -n "$fibs" ]; then + if [ "$fibs" -gt 0 ]; then fibmod="-fib 0-$fibs" else fibmod= -- cgit v1.1 From 88807e15b48f22a8eecd4521ba4db85cab6214db Mon Sep 17 00:00:00 2001 From: crees Date: Sun, 18 Nov 2012 14:21:05 +0000 Subject: cp -R misses out dotfiles; use pax instead to copy file hierarchies PR: conf/99721 (based on) Submitted by: Florian Zavatzki Approved by: hrs MFC after: 1 month --- etc/rc.initdiskless | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.initdiskless b/etc/rc.initdiskless index cfb9214..60fe6bc 100644 --- a/etc/rc.initdiskless +++ b/etc/rc.initdiskless @@ -354,7 +354,7 @@ for i in ${templates} ; do subdir=${j##*/} if [ -d $j -a ! -f $j.cpio.gz ]; then create_md $subdir - cp -Rp $j/ /$subdir + (cd $j && pax -rw . /$subdir) fi done for j in /conf/$i/*.cpio.gz ; do -- cgit v1.1 From f5a468d92ec241c832092a10507e86363404fceb Mon Sep 17 00:00:00 2001 From: hrs Date: Tue, 20 Nov 2012 04:45:04 +0000 Subject: Do not put "already running" message when rc_quiet=yes. PR: bin/165477 --- etc/rc.subr | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.subr b/etc/rc.subr index bec5e7e..053f89a 100644 --- a/etc/rc.subr +++ b/etc/rc.subr @@ -704,7 +704,10 @@ run_rc_command() start) if [ -z "$rc_fast" -a -n "$rc_pid" ]; then - echo 1>&2 "${name} already running? (pid=$rc_pid)." + if [ -z "$rc_quiet" ]; then + echo 1>&2 "${name} already running? " \ + "(pid=$rc_pid)." + fi return 1 fi -- cgit v1.1 From 133206e35ac774847c2dafb92f63e78e2ad8e96e Mon Sep 17 00:00:00 2001 From: crees Date: Wed, 21 Nov 2012 18:12:28 +0000 Subject: Revert r243228. This commit appears to cause more trouble than it was designed to avoid; the issue described in the PR was no longer an issue anyway. --- etc/rc.initdiskless | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.initdiskless b/etc/rc.initdiskless index 60fe6bc..cfb9214 100644 --- a/etc/rc.initdiskless +++ b/etc/rc.initdiskless @@ -354,7 +354,7 @@ for i in ${templates} ; do subdir=${j##*/} if [ -d $j -a ! -f $j.cpio.gz ]; then create_md $subdir - (cd $j && pax -rw . /$subdir) + cp -Rp $j/ /$subdir fi done for j in /conf/$i/*.cpio.gz ; do -- cgit v1.1 From 8f5310865ed959aaeb47106db17c456a240d6444 Mon Sep 17 00:00:00 2001 From: glebius Date: Mon, 26 Nov 2012 19:42:38 +0000 Subject: Fix typo in weekly line which made it to rotated after reaching > 1 Kb. PR: conf/173857 Submitted by: Matt Smith --- etc/newsyslog.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/newsyslog.conf b/etc/newsyslog.conf index 44aff12..b9ac1a8 100644 --- a/etc/newsyslog.conf +++ b/etc/newsyslog.conf @@ -35,5 +35,5 @@ /var/log/security 600 10 100 * JC /var/log/sendmail.st 640 10 * 168 B /var/log/utx.log 644 3 * @01T05 B -/var/log/weekly.log 640 5 1 $W6D0 JN +/var/log/weekly.log 640 5 * $W6D0 JN /var/log/xferlog 600 7 100 * JC -- cgit v1.1 From 9cb06d4917322211acf3f73992d8be21d35de98c Mon Sep 17 00:00:00 2001 From: hselasky Date: Wed, 28 Nov 2012 18:37:20 +0000 Subject: Regenerate usb.conf MFC after: 1 week --- etc/devd/usb.conf | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'etc') diff --git a/etc/devd/usb.conf b/etc/devd/usb.conf index d4197f2..c1357a9 100644 --- a/etc/devd/usb.conf +++ b/etc/devd/usb.conf @@ -52,6 +52,17 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x05ac"; + match "product" "0x12a8"; + match "intclass" "0xff"; + match "intsubclass" "0xfd"; + match "intprotocol" "0x01"; + action "kldload -n if_ipheth"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0104"; match "product" "0x00be"; action "kldload -n uipaq"; @@ -3069,7 +3080,7 @@ nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; match "vendor" "0x12d1"; - match "product" "(0x1001|0x1003|0x1004|0x1401|0x1402|0x1403|0x1404|0x1405|0x1406|0x1407|0x1408|0x1409|0x140a|0x140b|0x140c|0x140d|0x140e|0x140f|0x1410|0x1411|0x1412|0x1413|0x1414|0x1415|0x1416|0x1417|0x1418|0x1419|0x141a|0x141b|0x141c|0x141d|0x141e|0x141f|0x1420|0x1421|0x1422|0x1423|0x1424|0x1425|0x1426|0x1427|0x1428|0x1429|0x142a|0x142b|0x142c|0x142d|0x142e|0x142f|0x1430|0x1431|0x1432|0x1433|0x1434|0x1435|0x1436|0x1437|0x1438|0x1439|0x143a|0x143b|0x143c|0x143d|0x143e|0x143f|0x1446|0x1465|0x14ac|0x14fe|0x1505|0x1506|0x1520|0x1803|0x1c05|0x1c0b)"; + match "product" "(0x1001|0x1003|0x1004|0x1401|0x1402|0x1403|0x1404|0x1405|0x1406|0x1407|0x1408|0x1409|0x140a|0x140b|0x140c|0x140d|0x140e|0x140f|0x1410|0x1411|0x1412|0x1413|0x1414|0x1415|0x1416|0x1417|0x1418|0x1419|0x141a|0x141b|0x141c|0x141d|0x141e|0x141f|0x1420|0x1421|0x1422|0x1423|0x1424|0x1425|0x1426|0x1427|0x1428|0x1429|0x142a|0x142b|0x142c|0x142d|0x142e|0x142f|0x1430|0x1431|0x1432|0x1433|0x1434|0x1435|0x1436|0x1437|0x1438|0x1439|0x143a|0x143b|0x143c|0x143d|0x143e|0x143f|0x1446|0x1464|0x1465|0x14ac|0x14c9|0x14d1|0x14fe|0x1505|0x1506|0x1520|0x1521|0x1803|0x1c05|0x1c0b)"; action "kldload -n u3g"; }; @@ -4600,5 +4611,5 @@ nomatch 32 { action "kldload -n umass"; }; -# 2274 USB entries processed +# 2279 USB entries processed -- cgit v1.1 From 991e942bf20fdf0e5d8ef3a6a152c146e904a93a Mon Sep 17 00:00:00 2001 From: rwatson Date: Sat, 1 Dec 2012 15:11:46 +0000 Subject: Merge a number of changes required to hook up OpenBSM 1.2-alpha2's auditdistd (distributed audit daemon) to the build: - Manual cross references - Makefile for auditdistd - rc.d script, rc.conf entrie - New group and user for auditdistd; associated aliases, etc. The audit trail distribution daemon provides reliable, cryptographically protected (and sandboxed) delivery of audit tails from live clients to audit server hosts in order to both allow centralised analysis, and improve resilience in the event of client compromises: clients are not permitted to change trail contents after submission. Submitted by: pjd Sponsored by: The FreeBSD Foundation (auditdistd) --- etc/defaults/rc.conf | 3 +++ etc/ftpusers | 1 + etc/mail/aliases | 1 + etc/master.passwd | 1 + etc/mtree/BSD.var.dist | 4 ++++ etc/rc.d/Makefile | 1 + etc/rc.d/auditdistd | 21 +++++++++++++++++++++ 7 files changed, 32 insertions(+) create mode 100644 etc/rc.d/auditdistd (limited to 'etc') diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf index 0efaaa1..cc3e623 100644 --- a/etc/defaults/rc.conf +++ b/etc/defaults/rc.conf @@ -590,6 +590,9 @@ sendmail_rebuild_aliases="NO" # Run newaliases if necessary (YES/NO). auditd_enable="NO" # Run the audit daemon. auditd_program="/usr/sbin/auditd" # Path to the audit daemon. auditd_flags="" # Which options to pass to the audit daemon. +auditdistd_enable="NO" # Run the audit daemon. +auditdistd_program="/usr/sbin/auditdistd" # Path to the auditdistd daemon. +auditdistd_flags="" # Which options to pass to the auditdistd daemon. cron_enable="YES" # Run the periodic job daemon. cron_program="/usr/sbin/cron" # Which cron executable to run (if enabled). cron_dst="YES" # Handle DST transitions intelligently (YES/NO) diff --git a/etc/ftpusers b/etc/ftpusers index 06b3f49..adb9dcf 100644 --- a/etc/ftpusers +++ b/etc/ftpusers @@ -19,6 +19,7 @@ _pflogd _dhcp uucp pop +auditdistd www hast nobody diff --git a/etc/mail/aliases b/etc/mail/aliases index 5f5cd24..46f5f64 100644 --- a/etc/mail/aliases +++ b/etc/mail/aliases @@ -26,6 +26,7 @@ postmaster: root # General redirections for pseudo accounts _dhcp: root _pflogd: root +auditdistd: root bin: root bind: root daemon: root diff --git a/etc/master.passwd b/etc/master.passwd index 4e1d113..f979940 100644 --- a/etc/master.passwd +++ b/etc/master.passwd @@ -20,6 +20,7 @@ _pflogd:*:64:64::0:0:pflogd privsep user:/var/empty:/usr/sbin/nologin _dhcp:*:65:65::0:0:dhcp programs:/var/empty:/usr/sbin/nologin uucp:*:66:66::0:0:UUCP pseudo-user:/var/spool/uucppublic:/usr/local/libexec/uucp/uucico pop:*:68:6::0:0:Post Office Owner:/nonexistent:/usr/sbin/nologin +auditdistd:*:78:77::0:0:Auditdistd unprivileged user:/var/empty:/usr/sbin/nologin www:*:80:80::0:0:World Wide Web Owner:/nonexistent:/usr/sbin/nologin hast:*:845:845::0:0:HAST unprivileged user:/var/empty:/usr/sbin/nologin nobody:*:65534:65534::0:0:Unprivileged user:/nonexistent:/usr/sbin/nologin diff --git a/etc/mtree/BSD.var.dist b/etc/mtree/BSD.var.dist index 4481b10..30b901d 100644 --- a/etc/mtree/BSD.var.dist +++ b/etc/mtree/BSD.var.dist @@ -19,6 +19,10 @@ /set gname=audit audit .. + dist uname=auditdistd gname=audit mode=0770 + .. + remote uname=auditdistd gname=wheel mode=0700 + .. /set gname=wheel backups .. diff --git a/etc/rc.d/Makefile b/etc/rc.d/Makefile index 245b0c9..aace4b1 100644 --- a/etc/rc.d/Makefile +++ b/etc/rc.d/Makefile @@ -19,6 +19,7 @@ FILES= DAEMON \ atm2 \ atm3 \ auditd \ + auditdistd \ bgfsck \ bluetooth \ bootparams \ diff --git a/etc/rc.d/auditdistd b/etc/rc.d/auditdistd new file mode 100644 index 0000000..0aa62e8 --- /dev/null +++ b/etc/rc.d/auditdistd @@ -0,0 +1,21 @@ +#!/bin/sh +# +# $FreeBSD$ +# + +# PROVIDE: auditdistd +# REQUIRE: auditd +# BEFORE: DAEMON +# KEYWORD: nojail shutdown + +. /etc/rc.subr + +name="auditdistd" +rcvar="${name}_enable" +pidfile="/var/run/${name}.pid" +command="/usr/sbin/${name}" +required_files="/etc/${name}.conf" +extra_commands="reload" + +load_rc_config $name +run_rc_command "$1" -- cgit v1.1 From 6dd12d609dc178d716b9e83a28132edaefc99c45 Mon Sep 17 00:00:00 2001 From: eadler Date: Wed, 5 Dec 2012 13:56:39 +0000 Subject: Remove hack to emulate effective uid and just use the EUID's name in the first place. I was unaware of this option when originally committing this change. Submitted by: gcooper Approved by: cperciva MFC after: 3 days --- etc/root/dot.cshrc | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'etc') diff --git a/etc/root/dot.cshrc b/etc/root/dot.cshrc index 5ce3e36..3e94371 100644 --- a/etc/root/dot.cshrc +++ b/etc/root/dot.cshrc @@ -23,10 +23,7 @@ setenv BLOCKSIZE K if ($?prompt) then # An interactive shell -- set some stuff up - if ($uid == 0) then - set user = root - endif - set prompt = "%n@%m:%~ %# " + set prompt = "%N@%m:%~ %# " set promptchars = "%#" set filec -- cgit v1.1 From 51bed028d5377df195db20a964f6b38bc12b97ae Mon Sep 17 00:00:00 2001 From: adrian Date: Fri, 7 Dec 2012 06:34:46 +0000 Subject: Add a new 900MHz GSM regulatory SKU for the Xagyl Communications XC900M. The XC900M acts as a Ubiquiti XR9 (and I _think_ SR9) by default; it uses the same 900MHz<->2.4GHz downconverter mapping. However it has an alternative frequency mapping which squeezes in a couple more half/quarter rate channels. Since the default HAL doesn't support fractional tuning (sub-1MHz) in 2.4GHz mode on the AR5413/AR5414, they implement it using a jumper. Datasheet: http://www.xagyl.com/download/XC900M_Datasheet.pdf Thankyou to Xagyl Communications for the XC900M NICs and Edgar Martinez for organising the donation. Tested: * XC900M <-> XC900M * Ubiquiti XR9 <-> XC900M TODO: * Test against SR9 and GZ901 if possible (the IEEE channel<->frequency mapping may not match up, thanks to the slightly different channels involved) --- etc/regdomain.xml | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) (limited to 'etc') diff --git a/etc/regdomain.xml b/etc/regdomain.xml index ff57113..126f03a 100644 --- a/etc/regdomain.xml +++ b/etc/regdomain.xml @@ -1303,6 +1303,29 @@ + + + XC900M + 0x29b + + + + 30 + IEEE80211_CHAN_G + + + + 30 + IEEE80211_CHAN_G + + + + 30 + IEEE80211_CHAN_G + + + + @@ -1896,6 +1919,25 @@ IEEE80211_CHAN_GSM + + 905 925 + 5 5 + IEEE80211_CHAN_GSM + IEEE80211_CHAN_QUARTER + + + 910 920 + 10 5 + IEEE80211_CHAN_GSM + IEEE80211_CHAN_HALF + + + 915 915 + 20 5 + IEEE80211_CHAN_GSM + + + -- cgit v1.1 From 36123bbedb14c1906b59566a4271c3300253d088 Mon Sep 17 00:00:00 2001 From: delphij Date: Mon, 10 Dec 2012 20:52:52 +0000 Subject: Sync pf.os with OpenBSD: add a handful of linux signatures from p0fv2 and some other signatures from observation. MFC after: 2 weeks --- etc/pf.os | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'etc') diff --git a/etc/pf.os b/etc/pf.os index 00873a7..699f19a 100644 --- a/etc/pf.os +++ b/etc/pf.os @@ -1,5 +1,5 @@ # $FreeBSD$ -# $OpenBSD: pf.os,v 1.25 2010/10/18 15:55:27 deraadt Exp $ +# $OpenBSD: pf.os,v 1.26 2012/08/03 12:25:16 jsg Exp $ # passive OS fingerprinting # ------------------------- # @@ -226,7 +226,13 @@ S2:64:1:60:M*,S,T,N,W0: Linux:2.4::Linux 2.4 (big boy) S3:64:1:60:M*,S,T,N,W0: Linux:2.4:.18-21:Linux 2.4.18 and newer S4:64:1:60:M*,S,T,N,W0: Linux:2.4::Linux 2.4/2.6 <= 2.6.7 S4:64:1:60:M*,S,T,N,W0: Linux:2.6:.1-7:Linux 2.4/2.6 <= 2.6.7 -S4:64:1:60:M*,S,T,N,W7: Linux:2.6:8:Linux 2.6.8 and newer (?) + +S4:64:1:60:M*,S,T,N,W5: Linux:2.6::Linux 2.6 (newer, 1) +S4:64:1:60:M*,S,T,N,W6: Linux:2.6::Linux 2.6 (newer, 2) +S4:64:1:60:M*,S,T,N,W7: Linux:2.6::Linux 2.6 (newer, 3) +T4:64:1:60:M*,S,T,N,W7: Linux:2.6::Linux 2.6 (newer, 4) + +S10:64:1:60:M*,S,T,N,W4: Linux:3.0::Linux 3.0 S3:64:1:60:M*,S,T,N,W1: Linux:2.5::Linux 2.5 (sometimes 2.4) S4:64:1:60:M*,S,T,N,W1: Linux:2.5-2.6::Linux 2.5/2.6 @@ -429,6 +435,8 @@ S44:128:1:48:M*,N,N,S: Windows:XP:SP1:Windows Pro SP1, 2000 SP3 32767:128:1:48:M*,N,N,S: Windows:2000:SP4:Windows SP1, 2000 SP4 32767:128:1:48:M*,N,N,S: Windows:XP:SP1:Windows SP1, 2000 SP4 +8192:128:1:52:M*,N,W2,N,N,S: Windows:Vista::Windows Vista/7 + # Odds, ends, mods: S52:128:1:48:M1260,N,N,S: Windows:2000:cisco:Windows XP/2000 via Cisco -- cgit v1.1 From 3b54c5ffbe67ad61e9127a5b46e31955105e4ed7 Mon Sep 17 00:00:00 2001 From: pjd Date: Thu, 13 Dec 2012 09:41:32 +0000 Subject: Fix the location of auditdistd configuration file. Reported by: Johan Hendriks --- etc/rc.d/auditdistd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.d/auditdistd b/etc/rc.d/auditdistd index 0aa62e8..f8c8195 100644 --- a/etc/rc.d/auditdistd +++ b/etc/rc.d/auditdistd @@ -14,7 +14,7 @@ name="auditdistd" rcvar="${name}_enable" pidfile="/var/run/${name}.pid" command="/usr/sbin/${name}" -required_files="/etc/${name}.conf" +required_files="/etc/security/${name}.conf" extra_commands="reload" load_rc_config $name -- cgit v1.1 From 976943f3a93bdb52ea2fb077b56f27c14b99da8c Mon Sep 17 00:00:00 2001 From: delphij Date: Thu, 13 Dec 2012 23:32:47 +0000 Subject: Teach sysctl(8) about parsing a file (while I'm there also give it capability of parsing both = and : formats). Submitted by: hrs (initial version, bugs are mine) MFC after: 3 months --- etc/rc.d/sysctl | 50 +++++++++++++------------------------------------- 1 file changed, 13 insertions(+), 37 deletions(-) (limited to 'etc') diff --git a/etc/rc.d/sysctl b/etc/rc.d/sysctl index 34fb3b5..cc3e801 100755 --- a/etc/rc.d/sysctl +++ b/etc/rc.d/sysctl @@ -8,51 +8,27 @@ . /etc/rc.subr name="sysctl" +command="/sbin/sysctl" stop_cmd=":" start_cmd="sysctl_start" reload_cmd="sysctl_start" lastload_cmd="sysctl_start last" extra_commands="reload lastload" -# -# Read in a file containing sysctl settings and set things accordingly. -# -parse_file() -{ - if [ -f $1 ]; then - while read var comments - do - case ${var} in - \#*|'') - ;; - *) - mib=${var%=*} - val=${var#*=} - - if current_value=`${SYSCTL} -n ${mib} 2>/dev/null`; then - case ${current_value} in - ${val}) - ;; - *) - if ! sysctl "${var}" >/dev/null 2>&1; then - warn "unable to set ${var}" - fi - ;; - esac - elif [ "$2" = "last" ]; then - warn "sysctl ${mib} does not exist." - fi - ;; - esac - done < $1 - fi -} - sysctl_start() { - - parse_file /etc/sysctl.conf $1 - parse_file /etc/sysctl.conf.local $1 + case $1 in + last) + command_args="-i -f" + ;; + *) + command_args="-f" + ;; + esac + + for _f in /etc/sysctl.conf /etc/sysctl.conf.local; do + [ -r ${_f} ] && ${command} ${command_args} ${_f} > /dev/null + done } load_rc_config $name -- cgit v1.1 From 1d3ec906ca23ea5f5ff60e8ebe9b3bcc4f9033d2 Mon Sep 17 00:00:00 2001 From: pjd Date: Fri, 14 Dec 2012 15:12:08 +0000 Subject: - When checking if a dump exists on the given device there is no need to provide dump directory. Eliminate this redundant argument. This changes the usage, but the only risk here is that a warning will be printed about directory given as device. - Update usage of -C option. - When clearing dump header from the given device there is also no need to provide dump directory, although additional arguments for -c were not documented. - Document that -v can be used with -c and that list of devices can be given. Obtained from: WHEEL Systems --- etc/rc.d/savecore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.d/savecore b/etc/rc.d/savecore index 4efb7db..3e61adc 100755 --- a/etc/rc.d/savecore +++ b/etc/rc.d/savecore @@ -62,7 +62,7 @@ savecore_start() ;; esac - if savecore -C "${dumpdir}" "${dev}" >/dev/null; then + if savecore -C "${dev}" >/dev/null; then savecore ${savecore_flags} ${dumpdir} ${dumpdev} if checkyesno crashinfo_enable; then ${crashinfo_program} -d ${dumpdir} -- cgit v1.1 From 8ee2f7fcb15b974fec335d602faf7a5d49d28cf8 Mon Sep 17 00:00:00 2001 From: hselasky Date: Sat, 15 Dec 2012 10:56:16 +0000 Subject: Regenerate usb.conf MFC after: 1 week --- etc/devd/usb.conf | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/devd/usb.conf b/etc/devd/usb.conf index c1357a9..d3090ab 100644 --- a/etc/devd/usb.conf +++ b/etc/devd/usb.conf @@ -423,6 +423,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0499"; + match "product" "(0x1000|0x1001|0x1002|0x1003|0x1004|0x1005|0x1006|0x1007|0x1008|0x1009|0x100a|0x100c|0x100d|0x100e|0x100f|0x1010|0x1011|0x1012|0x1013|0x1014|0x1015|0x1016|0x1017|0x1018|0x1019|0x101a|0x101b|0x101c|0x101d|0x101e|0x101f|0x1020|0x1021|0x1022|0x1023|0x1024|0x1025|0x1026|0x1027|0x1028|0x1029|0x102a|0x102b|0x102e|0x1030|0x1031|0x1032|0x1033|0x1034|0x1035|0x1036|0x1037|0x1038|0x1039|0x103a|0x103b|0x103c|0x103d|0x103e|0x103f|0x1040|0x1041|0x1042|0x1043|0x1044|0x1045|0x104e|0x104f|0x1050|0x1051|0x1052|0x1053|0x1054|0x1055|0x1056|0x1057|0x1058|0x1059|0x105a|0x105b|0x105c|0x105d|0x1503|0x2000|0x2001|0x2002|0x2003|0x5000|0x5001|0x5002|0x5003|0x5004|0x5005|0x5006|0x5007|0x5008|0x5009|0x500a|0x500b|0x500c|0x500d|0x500e|0x500f|0x7000|0x7010)"; + action "kldload -n snd_uaudio"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x049f"; match "product" "(0x0003|0x0032)"; action "kldload -n uipaq"; @@ -2647,6 +2655,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x0f3d"; + match "product" "0x68aa"; + action "kldload -n u3g"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x0f4e"; match "product" "0x0200"; action "kldload -n uipaq"; @@ -4199,6 +4215,14 @@ nomatch 32 { nomatch 32 { match "bus" "uhub[0-9]+"; match "mode" "host"; + match "vendor" "0x22de"; + match "product" "0x6801"; + action "kldload -n u3g"; +}; + +nomatch 32 { + match "bus" "uhub[0-9]+"; + match "mode" "host"; match "vendor" "0x2478"; match "product" "0x2008"; action "kldload -n uplcom"; @@ -4611,5 +4635,5 @@ nomatch 32 { action "kldload -n umass"; }; -# 2279 USB entries processed +# 2386 USB entries processed -- cgit v1.1 From cbf6823f9afcdfa0776c6a47cce2962d97a087ef Mon Sep 17 00:00:00 2001 From: pjd Date: Sun, 16 Dec 2012 23:29:56 +0000 Subject: Use new savecore(8) option and limit number of kernel dumps that will be kept around to the 10 most recent ones. Add UPDATING entry with info how to return to the previous behaviour (no limits). Obtained from: WHEEL Systems --- etc/defaults/rc.conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf index cc3e623..3760fc0 100644 --- a/etc/defaults/rc.conf +++ b/etc/defaults/rc.conf @@ -605,7 +605,9 @@ chkprintcap_enable="NO" # Run chkprintcap(8) before running lpd. chkprintcap_flags="-d" # Create missing directories by default. dumpdev="AUTO" # Device to crashdump to (device name, AUTO, or NO). dumpdir="/var/crash" # Directory where crash dumps are to be stored -savecore_flags="" # Used if dumpdev is enabled above, and present. +savecore_flags="-m 10" # Used if dumpdev is enabled above, and present. + # By default, only the 10 most recent kernel dumps + # are saved. crashinfo_enable="YES" # Automatically generate crash dump summary. crashinfo_program="/usr/sbin/crashinfo" # Script to generate crash dump summary. quota_enable="NO" # turn on quotas on startup (or NO). -- cgit v1.1 From b56a027638876133cbec63c0ee0262507aae713b Mon Sep 17 00:00:00 2001 From: zont Date: Tue, 18 Dec 2012 07:27:50 +0000 Subject: - Set memorylocked limit to 64Kb for default login class. This prevents unprivileged users to lock too much memory. - Set memorylocked limit to 64Mb for daemon login class. Some daemons such as amd(8) and watchdogd(8) calls mlockall(2) on startup, they are run from init(8) which uses daemon login class. - Set memorylocked limit to unlimited for root login class. Suggested by: avg Approved by: kib (mentor) MFC after: 1 week --- etc/login.conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/login.conf b/etc/login.conf index c62687a..92826c4 100644 --- a/etc/login.conf +++ b/etc/login.conf @@ -32,7 +32,7 @@ default:\ :cputime=unlimited:\ :datasize=unlimited:\ :stacksize=unlimited:\ - :memorylocked=unlimited:\ + :memorylocked=64K:\ :memoryuse=unlimited:\ :filesize=unlimited:\ :coredumpsize=unlimited:\ @@ -59,6 +59,7 @@ xuser:\ staff:\ :tc=default: daemon:\ + :memorylocked=64M:\ :tc=default: news:\ :tc=default: @@ -72,6 +73,7 @@ dialer:\ # in preference to 'default'. root:\ :ignorenologin:\ + :memorylocked=unlimited:\ :tc=default: # -- cgit v1.1 From eb5a928066a09fedb0bcc4237a55acde20e3b7a3 Mon Sep 17 00:00:00 2001 From: bapt Date: Thu, 20 Dec 2012 11:39:20 +0000 Subject: make installation of the 220.backup-pkgdb periodic script depend on PKGTOOLS knob --- etc/periodic/daily/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'etc') diff --git a/etc/periodic/daily/Makefile b/etc/periodic/daily/Makefile index b324f70..9c7f4d7 100644 --- a/etc/periodic/daily/Makefile +++ b/etc/periodic/daily/Makefile @@ -6,7 +6,6 @@ FILES= 100.clean-disks \ 110.clean-tmps \ 120.clean-preserve \ 200.backup-passwd \ - 220.backup-pkgdb \ 330.news \ 400.status-disks \ 405.status-ata-raid \ @@ -41,7 +40,8 @@ FILES+= 480.status-ntpd .endif .if ${MK_PKGTOOLS} != "no" -FILES+= 490.status-pkg-changes +FILES+= 220.backup-pkgdb \ + 490.status-pkg-changes .endif .if ${MK_RCMDS} != "no" -- cgit v1.1 From f8816140afe017432a9b5499219d80e004f53fa3 Mon Sep 17 00:00:00 2001 From: markj Date: Thu, 20 Dec 2012 23:18:36 +0000 Subject: Don't reload syslogd after rotating sendmail.st, as this file isn't managed by syslogd. PR: conf/169973 Approved by: rstone (co-mentor) MFC after: 1 week --- etc/newsyslog.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/newsyslog.conf b/etc/newsyslog.conf index b9ac1a8..76e0707 100644 --- a/etc/newsyslog.conf +++ b/etc/newsyslog.conf @@ -33,7 +33,7 @@ /var/log/pflog 600 3 100 * JB /var/run/pflogd.pid /var/log/ppp.log root:network 640 3 100 * JC /var/log/security 600 10 100 * JC -/var/log/sendmail.st 640 10 * 168 B +/var/log/sendmail.st 640 10 * 168 BN /var/log/utx.log 644 3 * @01T05 B /var/log/weekly.log 640 5 * $W6D0 JN /var/log/xferlog 600 7 100 * JC -- cgit v1.1 From 1bd72ff3fbdfa47a3afaec309975829ddf71fc25 Mon Sep 17 00:00:00 2001 From: ume Date: Fri, 28 Dec 2012 10:42:01 +0000 Subject: Fix location of /var/audit/dist and /var/audit/remote. Note that those who did installworld after r243752 should remove wrongly created /var/dist and /var/remote. Reviewed by: pjd --- etc/mtree/BSD.var.dist | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/mtree/BSD.var.dist b/etc/mtree/BSD.var.dist index 30b901d..6a9a7f4 100644 --- a/etc/mtree/BSD.var.dist +++ b/etc/mtree/BSD.var.dist @@ -18,11 +18,11 @@ /set mode=0750 /set gname=audit audit - .. dist uname=auditdistd gname=audit mode=0770 .. remote uname=auditdistd gname=wheel mode=0700 .. + .. /set gname=wheel backups .. -- cgit v1.1 From 896fc63862ccf01e4da5831d63296c6c274972a0 Mon Sep 17 00:00:00 2001 From: gshapiro Date: Sat, 29 Dec 2012 19:57:52 +0000 Subject: Add missing closing quote on commented out example PR: bin/174108 Obtained from: Julian H. Stacey MFC after: 1 day --- etc/sendmail/freebsd.mc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/sendmail/freebsd.mc b/etc/sendmail/freebsd.mc index 1e28c47..a758531 100644 --- a/etc/sendmail/freebsd.mc +++ b/etc/sendmail/freebsd.mc @@ -69,7 +69,7 @@ dnl http://www.google.com/Top/Computers/Internet/E-mail/Spam/Blacklists/ dnl Uncomment to activate your chosen DNS based blacklist dnl FEATURE(dnsbl, `dnsbl.example.com') dnl Alternatively, you can provide your own server and rejection message: -dnl FEATURE(dnsbl, `dnsbl.example.com', ``"550 Mail from " $&{client_addr} " rejected'') +dnl FEATURE(dnsbl, `dnsbl.example.com', ``"550 Mail from " $&{client_addr} " rejected"'') dnl Dialup users should uncomment and define this appropriately dnl define(`SMART_HOST', `your.isp.mail.server') -- cgit v1.1 From 40a342aed70ea70f82da5e8bd92256195a3c2449 Mon Sep 17 00:00:00 2001 From: gshapiro Date: Sat, 29 Dec 2012 20:42:28 +0000 Subject: Minor changes to force commit these files so new freebsd*.cf files are built to use the new sendmail-8.14.6/cf tree. While here, update DNSBL link once again. MFC after: 4 days --- etc/sendmail/freebsd.mc | 4 ++-- etc/sendmail/freebsd.submit.mc | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'etc') diff --git a/etc/sendmail/freebsd.mc b/etc/sendmail/freebsd.mc index a758531..92efee1 100644 --- a/etc/sendmail/freebsd.mc +++ b/etc/sendmail/freebsd.mc @@ -63,8 +63,8 @@ dnl DNS based black hole lists dnl -------------------------------- dnl DNS based black hole lists come and go on a regular basis dnl so this file will not serve as a database of the available servers. -dnl For that, visit -dnl http://www.google.com/Top/Computers/Internet/E-mail/Spam/Blacklists/ +dnl For more information, visit +dnl http://en.wikipedia.org/wiki/DNSBL dnl Uncomment to activate your chosen DNS based blacklist dnl FEATURE(dnsbl, `dnsbl.example.com') diff --git a/etc/sendmail/freebsd.submit.mc b/etc/sendmail/freebsd.submit.mc index c6ec655..fbb036c 100644 --- a/etc/sendmail/freebsd.submit.mc +++ b/etc/sendmail/freebsd.submit.mc @@ -9,6 +9,7 @@ divert(-1) # # + # # This is the FreeBSD configuration for a set-group-ID sm-msp sendmail # that acts as a initial mail submission program. -- cgit v1.1 From 5c3498dbc2bd75150a5a7719fa5e5218a03fcfb7 Mon Sep 17 00:00:00 2001 From: erwin Date: Fri, 4 Jan 2013 09:15:59 +0000 Subject: Update with new IPv4 address for D root. Approved by: delphij (mentor) --- etc/namedb/named.root | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'etc') diff --git a/etc/namedb/named.root b/etc/namedb/named.root index 1c8facf..adf5e79 100644 --- a/etc/namedb/named.root +++ b/etc/namedb/named.root @@ -7,14 +7,14 @@ ; (e.g. reference this file in the "cache . " ; configuration file of BIND domain name servers). ; -; This file is made available by InterNIC +; This file is made available by InterNIC ; under anonymous FTP as -; file /domain/named.root +; file /domain/named.cache ; on server FTP.INTERNIC.NET ; -OR- RS.INTERNIC.NET ; -; last update: Jun 8, 2011 -; related version of root zone: 2011060800 +; last update: Jan 3, 2013 +; related version of root zone: 2013010300 ; ; formerly NS.INTERNIC.NET ; @@ -35,7 +35,7 @@ C.ROOT-SERVERS.NET. 3600000 A 192.33.4.12 ; FORMERLY TERP.UMD.EDU ; . 3600000 NS D.ROOT-SERVERS.NET. -D.ROOT-SERVERS.NET. 3600000 A 128.8.10.90 +D.ROOT-SERVERS.NET. 3600000 A 199.7.91.13 D.ROOT-SERVERS.NET. 3600000 AAAA 2001:500:2D::D ; ; FORMERLY NS.NASA.GOV -- cgit v1.1 From ae464bd0f7d512f82e4fad2f51887e9565751562 Mon Sep 17 00:00:00 2001 From: peter Date: Sun, 6 Jan 2013 19:25:42 +0000 Subject: Not using the full domain was a really bad idea. --- etc/sendmail/freefall.mc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/sendmail/freefall.mc b/etc/sendmail/freefall.mc index 74bc0f5..df07fea 100644 --- a/etc/sendmail/freefall.mc +++ b/etc/sendmail/freefall.mc @@ -43,5 +43,5 @@ divert(0)dnl VERSIONID(`$FreeBSD$') OSTYPE(freebsd6) -FEATURE(nullclient, smarthost.ysv.$m) +FEATURE(nullclient, smarthost.ysv.freebsd.org) MASQUERADE_AS(FreeBSD.org) -- cgit v1.1 From 5f83c0049f20fb0b22907364a244ad39ac4c7ce4 Mon Sep 17 00:00:00 2001 From: smh Date: Thu, 10 Jan 2013 11:08:22 +0000 Subject: Allow perl scripts to be used in rc.d scripts PR: conf/117027 Reviewed by: pjd (mentor) Approved by: hrs MFC after: 2 weeks --- etc/rc.subr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.subr b/etc/rc.subr index 053f89a..9bff68b 100644 --- a/etc/rc.subr +++ b/etc/rc.subr @@ -290,7 +290,7 @@ _find_processes() _interpbn=${1##*/} _fp_args='_argv' _fp_match='case "$_argv" in - ${_interp}|"${_interp} "*|"${_interpbn}: ${_procname}"*)' + ${_interp}|"${_interp} "*|"[${_interpbn}]"|"${_interpbn}: ${_procname}"*)' else # a normal daemon _procnamebn=${_procname##*/} _fp_args='_arg0 _argv' -- cgit v1.1 From ae7a101bcb09bdb778b58981b276e035cfedc577 Mon Sep 17 00:00:00 2001 From: brooks Date: Fri, 11 Jan 2013 23:08:19 +0000 Subject: Use the -N option to install and nmtree to eliminate the need for the checks for missing users and groups. Sponsored by: DARPA, AFRL --- etc/Makefile | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index c18908f..dc5f1af 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -291,25 +291,27 @@ distribution: ${DESTDIR}/etc/nsswitch.conf .endif +MTREE_CMD?= mtree + distrib-dirs: - mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/ - mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var - mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr - mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.include.dist \ + ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/ + ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var + ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr + ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.include.dist \ -p ${DESTDIR}/usr/include .if ${MK_BIND_LIBS} != "no" - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.include.dist \ + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.include.dist \ -p ${DESTDIR}/usr/include .endif .if ${MK_BIND_MTREE} != "no" - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.chroot.dist \ + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.chroot.dist \ -p ${DESTDIR}/var/named .endif .if ${MK_GROFF} != "no" - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.groff.dist -p ${DESTDIR}/usr + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.groff.dist -p ${DESTDIR}/usr .endif .if ${MK_SENDMAIL} != "no" - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.sendmail.dist -p ${DESTDIR}/ + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.sendmail.dist -p ${DESTDIR}/ .endif cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys cd ${DESTDIR}/usr/share/man/en.ISO8859-1; ln -sf ../man* . -- cgit v1.1 From 97cd9ab39d93e754ad7cc287b2be631166918331 Mon Sep 17 00:00:00 2001 From: brooks Date: Fri, 11 Jan 2013 23:44:35 +0000 Subject: Revert r245316. Systems with non-standard uids/gids are more prevalent that I'd feared. Discussion is ongoing about the scope of a safer solution. --- etc/Makefile | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index dc5f1af..c18908f 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -291,27 +291,25 @@ distribution: ${DESTDIR}/etc/nsswitch.conf .endif -MTREE_CMD?= mtree - distrib-dirs: - ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/ - ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var - ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr - ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.include.dist \ + mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/ + mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var + mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr + mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.include.dist \ -p ${DESTDIR}/usr/include .if ${MK_BIND_LIBS} != "no" - ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.include.dist \ + mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.include.dist \ -p ${DESTDIR}/usr/include .endif .if ${MK_BIND_MTREE} != "no" - ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.chroot.dist \ + mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.chroot.dist \ -p ${DESTDIR}/var/named .endif .if ${MK_GROFF} != "no" - ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.groff.dist -p ${DESTDIR}/usr + mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.groff.dist -p ${DESTDIR}/usr .endif .if ${MK_SENDMAIL} != "no" - ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.sendmail.dist -p ${DESTDIR}/ + mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.sendmail.dist -p ${DESTDIR}/ .endif cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys cd ${DESTDIR}/usr/share/man/en.ISO8859-1; ln -sf ../man* . -- cgit v1.1 From 8251e188c6ba82c959a91d5bed4b7a1e622ae326 Mon Sep 17 00:00:00 2001 From: brooks Date: Tue, 15 Jan 2013 00:12:34 +0000 Subject: Add an option DB_FROM_SRC to use src/etc's user/group databases when installing. This allows things like running installworld for 10-CURRENT on a 9.0-RELEASE system without adding extra users and groups to the passwd and group files. To prevent potentially risky uid/gid mismatches on systems with non-standard local values, require that DESTDIR be set if DB_FROM_SRC is set. Sponsored by: DARPA, AFRL Reviewed by: peter --- etc/Makefile | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index c18908f..dc5f1af 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -291,25 +291,27 @@ distribution: ${DESTDIR}/etc/nsswitch.conf .endif +MTREE_CMD?= mtree + distrib-dirs: - mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/ - mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var - mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr - mtree -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.include.dist \ + ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/ + ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var + ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr + ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.include.dist \ -p ${DESTDIR}/usr/include .if ${MK_BIND_LIBS} != "no" - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.include.dist \ + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.include.dist \ -p ${DESTDIR}/usr/include .endif .if ${MK_BIND_MTREE} != "no" - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.chroot.dist \ + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.chroot.dist \ -p ${DESTDIR}/var/named .endif .if ${MK_GROFF} != "no" - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.groff.dist -p ${DESTDIR}/usr + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.groff.dist -p ${DESTDIR}/usr .endif .if ${MK_SENDMAIL} != "no" - mtree -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.sendmail.dist -p ${DESTDIR}/ + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.sendmail.dist -p ${DESTDIR}/ .endif cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys cd ${DESTDIR}/usr/share/man/en.ISO8859-1; ln -sf ../man* . -- cgit v1.1 From 621d391260c6f896fe746dc7705d3f0bbcf3421f Mon Sep 17 00:00:00 2001 From: brooks Date: Wed, 16 Jan 2013 23:16:41 +0000 Subject: According to the notes in ObsoleteFiles.inc we last installed section 1aout manpages in 2002. Stop making the directories and links to them. --- etc/mtree/BSD.usr.dist | 8 -------- 1 file changed, 8 deletions(-) (limited to 'etc') diff --git a/etc/mtree/BSD.usr.dist b/etc/mtree/BSD.usr.dist index 336d055..89ec940 100644 --- a/etc/mtree/BSD.usr.dist +++ b/etc/mtree/BSD.usr.dist @@ -756,8 +756,6 @@ /set uname=man cat1 .. - cat1aout - .. cat2 .. cat3 @@ -795,8 +793,6 @@ en.ISO8859-1 uname=root cat1 .. - cat1aout - .. cat2 .. cat3 @@ -835,8 +831,6 @@ en.UTF-8 uname=root cat1 .. - cat1aout - .. cat2 .. cat3 @@ -913,8 +907,6 @@ .. man1 .. - man1aout - .. man2 .. man3 -- cgit v1.1 From c68369b5438c9258d7f356fa9ab19aa5e3bda079 Mon Sep 17 00:00:00 2001 From: bz Date: Thu, 17 Jan 2013 01:27:39 +0000 Subject: Add a conditional sleep 1 in case we add any IPv6 addresses to interfaces. Do this per jail started, not per address. This will allow DAD to complete and services to properly start. Before we have seen problems with services trying to start before the IPv6 address was available to use and thus erroring and failing to start. MFC after: 3 days --- etc/rc.d/jail | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/rc.d/jail b/etc/rc.d/jail index ff2f312..f19983f 100755 --- a/etc/rc.d/jail +++ b/etc/rc.d/jail @@ -509,7 +509,7 @@ jail_handle_ips_option() esac case "${_type}" in inet) ;; - inet6) ;; + inet6) ipv6_address_count=$((ipv6_address_count + 1)) ;; *) warn "Could not determine address family. Not going" \ "to ${_action} address '${_addr}' for ${_jail}." continue @@ -546,6 +546,7 @@ jail_ips() esac # Handle addresses. + ipv6_address_count=0 jail_handle_ips_option ${_action} "${_ip}" # Handle jail_xxx_ip_multi alias=0 @@ -558,6 +559,12 @@ jail_ips() ;; esac done + case ${ipv6_address_count} in + 0) ;; + *) # Sleep 1 second to let DAD complete before starting services. + sleep 1 + ;; + esac } jail_prestart() -- cgit v1.1 From a390aab8573d52d24403baa43f0d9095d5a2308e Mon Sep 17 00:00:00 2001 From: brooks Date: Thu, 17 Jan 2013 18:32:30 +0000 Subject: Rework the mtree portion of etc/Makefile's distrib-dirs target to run mtree in a shell loop so there is only one mtree commandline. Move the implementation of LOCAL_MTREE into etc/Makefile. Sponsored by: DARPA, AFRL Reviewed by: mtree :) --- etc/Makefile | 35 +++++++++++++++++++++++------------ 1 file changed, 23 insertions(+), 12 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index dc5f1af..ea29cd0 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -293,26 +293,37 @@ distribution: MTREE_CMD?= mtree -distrib-dirs: - ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/ - ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var - ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr - ${MTREE_CMD} -eU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.include.dist \ - -p ${DESTDIR}/usr/include +MTREES= mtree/BSD.root.dist / \ + mtree/BSD.var.dist /var \ + mtree/BSD.usr.dist /usr \ + mtree/BSD.include.dist /usr/include .if ${MK_BIND_LIBS} != "no" - ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.include.dist \ - -p ${DESTDIR}/usr/include +MTREES+= mtree/BIND.include.dist /usr/include .endif .if ${MK_BIND_MTREE} != "no" - ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BIND.chroot.dist \ - -p ${DESTDIR}/var/named +MTREES+= mtree/BIND.chroot.dist /var/named .endif .if ${MK_GROFF} != "no" - ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.groff.dist -p ${DESTDIR}/usr +MTREES+= mtree/BSD.groff.dist /usr .endif .if ${MK_SENDMAIL} != "no" - ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f ${.CURDIR}/mtree/BSD.sendmail.dist -p ${DESTDIR}/ +MTREES+= mtree/BSD.sendmail.dist / .endif +.for mtree in ${LOCAL_MTREE} +MTREES+= ../${mtree} / +.endfor + +distrib-dirs: + @set ${MTREES}; \ + while test $$# -ge 2; do \ + m=${.CURDIR}/$$1; \ + shift; \ + d=${DESTDIR}$$1; \ + shift; \ + ${ECHO} ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} \ + -f $$m -p $$d; \ + ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ + done; true cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys cd ${DESTDIR}/usr/share/man/en.ISO8859-1; ln -sf ../man* . cd ${DESTDIR}/usr/share/man/en.UTF-8; ln -sf ../man* . -- cgit v1.1 From 6fd273a1c075120d4b9d6069e73e110d3d4fc218 Mon Sep 17 00:00:00 2001 From: brooks Date: Thu, 17 Jan 2013 20:21:30 +0000 Subject: In preparation for logging metadata about each filesystem object refactor the link section of distrib-dirs to alwasy install to a full path (the link contents remain relative as they should). Eliminate the use of the "rm -r[f] ; ln -s " pattern in favor of "ln -sf ". None of these links could be directories on a system installed in the last decade. Sponsored by: DARPA, AFRL Reviewed by: mtree --- etc/Makefile | 32 +++++++++++++------------------- 1 file changed, 13 insertions(+), 19 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index ea29cd0..5053762 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -324,32 +324,26 @@ distrib-dirs: -f $$m -p $$d; \ ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ done; true - cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys - cd ${DESTDIR}/usr/share/man/en.ISO8859-1; ln -sf ../man* . - cd ${DESTDIR}/usr/share/man/en.UTF-8; ln -sf ../man* . + ln -sf usr/src/sys ${DESTDIR}/sys cd ${DESTDIR}/usr/share/man; \ - set - `grep "^[a-zA-Z]" ${.CURDIR}/man.alias`; \ - while [ $$# -gt 0 ] ; \ - do \ - rm -rf "$$1"; \ - ln -s "$$2" "$$1"; \ - shift; shift; \ + for mandir in man*; do \ + ln -sf ../$$mandir ${DESTDIR}/usr/share/man/en.ISO8859-1/; \ + ln -sf ../$$mandir ${DESTDIR}/usr/share/man/en.UTF-8/; \ done cd ${DESTDIR}/usr/share/openssl/man; \ + for mandir in man*; do \ + ln -sf ../$$mandir \ + ${DESTDIR}/usr/share/openssl/man/en.ISO8859-1/; \ + done set - `grep "^[a-zA-Z]" ${.CURDIR}/man.alias`; \ - while [ $$# -gt 0 ] ; \ - do \ - rm -rf "$$1"; \ - ln -s "$$2" "$$1"; \ + while [ $$# -gt 0 ] ; do \ + ln -sf "$$2" "${DESTDIR}/usr/share/man/$$1"; \ + ln -sf "$$2" "${DESTDIR}/usr/share/openssl/man/$$1"; \ shift; shift; \ done - cd ${DESTDIR}/usr/share/openssl/man/en.ISO8859-1; ln -sf ../man* . - cd ${DESTDIR}/usr/share/nls; \ set - `grep "^[a-zA-Z]" ${.CURDIR}/nls.alias`; \ - while [ $$# -gt 0 ] ; \ - do \ - rm -rf "$$1"; \ - ln -s "$$2" "$$1"; \ + while [ $$# -gt 0 ] ; do \ + ln -sf "$$2" "${DESTDIR}/usr/share/nls/$$1"; \ shift; shift; \ done -- cgit v1.1 From 2ba8b9706f72629013ae0e5b0cac03cff0c58eb8 Mon Sep 17 00:00:00 2001 From: brooks Date: Thu, 17 Jan 2013 23:05:03 +0000 Subject: In r245571, "rm -rf ; ln -s " needed to be replaced with "ln -sfh " or the links would fail when a valid link to a directly was in place at . Reported by: peter Tested by: peter Pointy hat to: brooks --- etc/Makefile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index 5053762..e8f8291 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -324,26 +324,26 @@ distrib-dirs: -f $$m -p $$d; \ ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ done; true - ln -sf usr/src/sys ${DESTDIR}/sys + ln -sfh usr/src/sys ${DESTDIR}/sys cd ${DESTDIR}/usr/share/man; \ for mandir in man*; do \ - ln -sf ../$$mandir ${DESTDIR}/usr/share/man/en.ISO8859-1/; \ - ln -sf ../$$mandir ${DESTDIR}/usr/share/man/en.UTF-8/; \ + ln -sfh ../$$mandir ${DESTDIR}/usr/share/man/en.ISO8859-1/; \ + ln -sfh ../$$mandir ${DESTDIR}/usr/share/man/en.UTF-8/; \ done cd ${DESTDIR}/usr/share/openssl/man; \ for mandir in man*; do \ - ln -sf ../$$mandir \ + ln -sfh ../$$mandir \ ${DESTDIR}/usr/share/openssl/man/en.ISO8859-1/; \ done set - `grep "^[a-zA-Z]" ${.CURDIR}/man.alias`; \ while [ $$# -gt 0 ] ; do \ - ln -sf "$$2" "${DESTDIR}/usr/share/man/$$1"; \ - ln -sf "$$2" "${DESTDIR}/usr/share/openssl/man/$$1"; \ + ln -sfh "$$2" "${DESTDIR}/usr/share/man/$$1"; \ + ln -sfh "$$2" "${DESTDIR}/usr/share/openssl/man/$$1"; \ shift; shift; \ done set - `grep "^[a-zA-Z]" ${.CURDIR}/nls.alias`; \ while [ $$# -gt 0 ] ; do \ - ln -sf "$$2" "${DESTDIR}/usr/share/nls/$$1"; \ + ln -sfh "$$2" "${DESTDIR}/usr/share/nls/$$1"; \ shift; shift; \ done -- cgit v1.1 From 6c2d158abab6d3c886d4781a41c8dbdd264de1f2 Mon Sep 17 00:00:00 2001 From: brooks Date: Mon, 21 Jan 2013 22:40:39 +0000 Subject: Replace all known uses of ln in the build process with appropriate install -l invocations via new INSTALL_LINK and INSTALL_SYMLINK variables. Sponsored by: DARPA, AFRL Reviewed by: ian, ray, rpaulo --- etc/Makefile | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index e8f8291..33b305a 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -324,26 +324,29 @@ distrib-dirs: -f $$m -p $$d; \ ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ done; true - ln -sfh usr/src/sys ${DESTDIR}/sys + ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys cd ${DESTDIR}/usr/share/man; \ for mandir in man*; do \ - ln -sfh ../$$mandir ${DESTDIR}/usr/share/man/en.ISO8859-1/; \ - ln -sfh ../$$mandir ${DESTDIR}/usr/share/man/en.UTF-8/; \ + ${INSTALL_SYMLINK} ../$$mandir \ + ${DESTDIR}/usr/share/man/en.ISO8859-1/; \ + ${INSTALL_SYMLINK} ../$$mandir \ + ${DESTDIR}/usr/share/man/en.UTF-8/; \ done cd ${DESTDIR}/usr/share/openssl/man; \ for mandir in man*; do \ - ln -sfh ../$$mandir \ + ${INSTALL_SYMLINK} ../$$mandir \ ${DESTDIR}/usr/share/openssl/man/en.ISO8859-1/; \ done set - `grep "^[a-zA-Z]" ${.CURDIR}/man.alias`; \ while [ $$# -gt 0 ] ; do \ - ln -sfh "$$2" "${DESTDIR}/usr/share/man/$$1"; \ - ln -sfh "$$2" "${DESTDIR}/usr/share/openssl/man/$$1"; \ + ${INSTALL_SYMLINK} "$$2" "${DESTDIR}/usr/share/man/$$1"; \ + ${INSTALL_SYMLINK} "$$2" \ + "${DESTDIR}/usr/share/openssl/man/$$1"; \ shift; shift; \ done set - `grep "^[a-zA-Z]" ${.CURDIR}/nls.alias`; \ while [ $$# -gt 0 ] ; do \ - ln -sfh "$$2" "${DESTDIR}/usr/share/nls/$$1"; \ + ${INSTALL_SYMLINK} "$$2" "${DESTDIR}/usr/share/nls/$$1"; \ shift; shift; \ done -- cgit v1.1 From 75f69e58cce1b1205e345702e744162ee6c8b275 Mon Sep 17 00:00:00 2001 From: brooks Date: Tue, 22 Jan 2013 21:10:03 +0000 Subject: Introduce a new option -DNO_ROOT that allows install and distribution targets to be run without root privilege. Information about ownership, group, flags, and suid bits are stored in the file specified by METALOG which defaults to ${DESTDIR}/METALOG. This file can be used in conjunction with bsdtar or makefs to generate archives or file system images with correct permissions. The packageworld target has been altered to use this metadata allowing non-root releases (subject to further changes in release/Makefile.) Sponsored by: DARPA, AFRL Reviewed by: ian, ray --- etc/Makefile | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index 33b305a..164cbd4 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -156,6 +156,9 @@ ETCMAIL=Makefile README mailer.conf access.sample virtusertable.sample \ # Special top level files for FreeBSD FREEBSD=COPYRIGHT +# Sanitize DESTDIR +DESTDIR:= ${DESTDIR:C://*:/:g} + afterinstall: .if ${MK_MAN} != "no" ${_+_}cd ${.CURDIR}/../share/man; ${MAKE} makedb @@ -324,6 +327,20 @@ distrib-dirs: -f $$m -p $$d; \ ${MTREE_CMD} -deU ${MTREE_FOLLOWS_SYMLINKS} -f $$m -p $$d; \ done; true +.if defined(NO_ROOT) + @set ${MTREES}; \ + while test $$# -ge 2; do \ + m=${.CURDIR}/$$1; \ + shift; \ + d=$$1; \ + test "$$d" == "/" && d=""; \ + d=${DISTBASE}$$d; \ + shift; \ + ${ECHO} "${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# >>" \ + "${METALOG}" ; \ + ${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# >> ${METALOG} ; \ + done; true +.endif ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys cd ${DESTDIR}/usr/share/man; \ for mandir in man*; do \ -- cgit v1.1 From 15607eb86a5921dfebfd82136f84bd84626646d2 Mon Sep 17 00:00:00 2001 From: neel Date: Sun, 27 Jan 2013 21:55:01 +0000 Subject: Increase the "memorylocked" limit for the "daemon" class. amd(8) requires more than the 64MB that is currently available to it so bump it up to 128MB. Reviewed by: kib Discussed with: avg, kib, zont --- etc/login.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'etc') diff --git a/etc/login.conf b/etc/login.conf index 92826c4..67509f9 100644 --- a/etc/login.conf +++ b/etc/login.conf @@ -59,7 +59,7 @@ xuser:\ staff:\ :tc=default: daemon:\ - :memorylocked=64M:\ + :memorylocked=128M:\ :tc=default: news:\ :tc=default: -- cgit v1.1 From 1a89a21cbd61e82e4c1a20a42cb30342e26ef1a6 Mon Sep 17 00:00:00 2001 From: brooks Date: Tue, 29 Jan 2013 22:17:58 +0000 Subject: Log the addition of login.conf.db, passwd, pwd.db, and spwd.db via cat -l. Make cat a bootstrap tool to facilitate this. --- etc/Makefile | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index 164cbd4..dfa9953 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -180,6 +180,10 @@ CAP_MKDB_ENDIAN?= PWD_MKDB_ENDIAN?= .endif +.if defined(NO_ROOT) +METALOG.add?= cat -l >> ${METALOG} +.endif + distribution: .if !defined(DESTDIR) @echo "set DESTDIR before running \"make ${.TARGET}\"" @@ -201,6 +205,14 @@ distribution: .endif pwd_mkdb ${PWD_MKDB_ENDIAN} -i -p -d ${DESTDIR}/etc \ ${DESTDIR}/etc/master.passwd +.if defined(NO_ROOT) + ( \ + echo "./etc/login.conf.db type=file mode=0644 uname=root gname=wheel"; \ + echo "./etc/passwd type=file mode=0644 uname=root gname=wheel"; \ + echo "./etc/pwd.db type=file mode=0644 uname=root gname=wheel"; \ + echo "./etc/spwd.db type=file mode=0600 uname=root gname=wheel"; \ + ) | ${METALOG.add} +.endif .if ${MK_ATF} != "no" ${_+_}cd ${.CURDIR}/atf; ${MAKE} install .endif @@ -336,9 +348,9 @@ distrib-dirs: test "$$d" == "/" && d=""; \ d=${DISTBASE}$$d; \ shift; \ - ${ECHO} "${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# >>" \ - "${METALOG}" ; \ - ${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# >> ${METALOG} ; \ + ${ECHO} "${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# |" \ + "${METALOG.add}" ; \ + ${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# | ${METALOG.add} ; \ done; true .endif ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys -- cgit v1.1 From 3e28301ce283fac4598377e876e6c9c8231a3c9a Mon Sep 17 00:00:00 2001 From: brooks Date: Wed, 30 Jan 2013 17:39:43 +0000 Subject: When adding the directory ownership to the METALOG do it by name rather than number as is done in install so as to differ binding of names to ids. Remove the -W flag from the mtree command so that the correct user and group is recorded rather than the default. --- etc/Makefile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'etc') diff --git a/etc/Makefile b/etc/Makefile index dfa9953..81ef45a 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -348,9 +348,10 @@ distrib-dirs: test "$$d" == "/" && d=""; \ d=${DISTBASE}$$d; \ shift; \ - ${ECHO} "${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# |" \ - "${METALOG.add}" ; \ - ${MTREE_CMD} -C -f $$m | sed s#^\.#.$$d# | ${METALOG.add} ; \ + ${ECHO} "${MTREE_CMD:N-W} -C -f $$m -K uname,gname | " \ + "sed s#^\.#.$$d# | ${METALOG.add}" ; \ + ${MTREE_CMD:N-W} -C -f $$m -K uname,gname | sed s#^\.#.$$d# | \ + ${METALOG.add} ; \ done; true .endif ${INSTALL_SYMLINK} usr/src/sys ${DESTDIR}/sys -- cgit v1.1 From d10987d4020421db516b11821338cc2f1dd4b3ef Mon Sep 17 00:00:00 2001 From: ume Date: Sat, 2 Feb 2013 18:08:09 +0000 Subject: Use the default policy table of RFC 6724. MFC after: 1 weeks --- etc/rc.d/ip6addrctl | 28 ++++++++++++++++++---------- 1 file changed, 18 insertions(+), 10 deletions(-) (limited to 'etc') diff --git a/etc/rc.d/ip6addrctl b/etc/rc.d/ip6addrctl index 801d7bb..914ca8c 100755 --- a/etc/rc.d/ip6addrctl +++ b/etc/rc.d/ip6addrctl @@ -29,11 +29,15 @@ ip6addrctl_prefer_ipv6() afexists inet6 || return 0 ip6addrctl flush >/dev/null 2>&1 - ip6addrctl add ::1/128 50 0 - ip6addrctl add ::/0 40 1 - ip6addrctl add 2002::/16 30 2 - ip6addrctl add ::/96 20 3 - ip6addrctl add ::ffff:0:0/96 10 4 + ip6addrctl add ::1/128 50 0 + ip6addrctl add ::/0 40 1 + ip6addrctl add ::ffff:0:0/96 35 4 + ip6addrctl add 2002::/16 30 2 + ip6addrctl add 2001::/32 5 5 + ip6addrctl add fc00::/7 3 13 + ip6addrctl add ::/96 1 3 + ip6addrctl add fec0::/10 1 11 + ip6addrctl add 3ffe::/16 1 12 checkyesno ip6addrctl_verbose && ip6addrctl } @@ -42,11 +46,15 @@ ip6addrctl_prefer_ipv4() afexists inet6 || return 0 ip6addrctl flush >/dev/null 2>&1 - ip6addrctl add ::ffff:0:0/96 50 0 - ip6addrctl add ::1/128 40 1 - ip6addrctl add ::/0 30 2 - ip6addrctl add 2002::/16 20 3 - ip6addrctl add ::/96 10 4 + ip6addrctl add ::1/128 50 0 + ip6addrctl add ::/0 40 1 + ip6addrctl add ::ffff:0:0/96 100 4 + ip6addrctl add 2002::/16 30 2 + ip6addrctl add 2001::/32 5 5 + ip6addrctl add fc00::/7 3 13 + ip6addrctl add ::/96 1 3 + ip6addrctl add fec0::/10 1 11 + ip6addrctl add 3ffe::/16 1 12 checkyesno ip6addrctl_verbose && ip6addrctl } -- cgit v1.1 From 2ab43ec83ecf3474d4eddf9a184cc0adea3516d5 Mon Sep 17 00:00:00 2001 From: des Date: Tue, 5 Feb 2013 12:18:39 +0000 Subject: Load the pfsync module if necessary. Reviewed by: glebius@ MFC after: 1 week --- etc/rc.d/pfsync | 1 + 1 file changed, 1 insertion(+) (limited to 'etc') diff --git a/etc/rc.d/pfsync b/etc/rc.d/pfsync index fa89b30..3dab3a8 100755 --- a/etc/rc.d/pfsync +++ b/etc/rc.d/pfsync @@ -35,6 +35,7 @@ pfsync_start() if [ -n "${pfsync_syncpeer}" ]; then _syncpeer="syncpeer ${pfsync_syncpeer}" fi + load_kld pfsync ifconfig pfsync0 $_syncpeer syncdev $pfsync_syncdev $pfsync_ifconfig up } -- cgit v1.1 From b313f550e1119059ac3b02a0849b10b166b3a3fd Mon Sep 17 00:00:00 2001 From: jhb Date: Tue, 5 Feb 2013 18:55:09 +0000 Subject: Install and as userland headers in /usr/include. MFC after: 2 weeks --- etc/mtree/BSD.include.dist | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'etc') diff --git a/etc/mtree/BSD.include.dist b/etc/mtree/BSD.include.dist index 4a4deee..374889d 100644 --- a/etc/mtree/BSD.include.dist +++ b/etc/mtree/BSD.include.dist @@ -100,6 +100,8 @@ dev acpica .. + agp + .. an .. bktr @@ -136,6 +138,8 @@ .. pbio .. + pci + .. powermac_nvram .. ppbus -- cgit v1.1