You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

108 lines
3.1 KiB

diff -up sudo-1.8.6p7/doc/fixmdoc.sh.manfix-usepty sudo-1.8.6p7/doc/fixmdoc.sh
--- sudo-1.8.6p7/doc/fixmdoc.sh.manfix-usepty 2015-07-07 09:06:37.893592317 +0200
+++ sudo-1.8.6p7/doc/fixmdoc.sh 2015-07-07 09:07:40.575602754 +0200
@@ -1,4 +1,19 @@
#!/bin/sh
+#
+# Copyright (c) 2012-2014 Todd C. Miller <Todd.Miller@courtesan.com>
+#
+# Permission to use, copy, modify, and distribute this software for any
+# purpose with or without fee is hereby granted, provided that the above
+# copyright notice and this permission notice appear in all copies.
+#
+# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+#
OUTFILE="$1"
rm -f "$OUTFILE"
@@ -18,11 +33,9 @@ case "$OUTFILE" in
# BSD auth
BA_FLAG=
if [ X"$BAMAN" != X"1" ]; then
- BA_FLAG='/^.*\n\.Op Fl a Ar auth_type/{;N;/^.*\n\.Ek$/d;};'
+ BA_FLAG='/^.*\n\.Op Fl a Ar type/{;N;/^.*\n\.Ek$/d;};'
cat >>"$OUTFILE" <<-'EOF'
- /^\.It Fl a Ar type/,/BSD authentication\.$/ {
- d
- }
+ /^\.It Fl a Ar type/,/BSD authentication\.$/d
EOF
fi
@@ -31,9 +44,7 @@ case "$OUTFILE" in
if [ X"$LCMAN" != X"1" ]; then
LC_FLAG='/^.*\n\.Op Fl c Ar class/{;N;/^.*\n\.Ek$/d;};'
cat >>"$OUTFILE" <<-'EOF'
- /^\.It Fl c Ar class/,/BSD login classes\.$/ {
- d
- }
+ /^\.It Fl c Ar class/,/BSD login classes\.$/d
/^\.Xr login_cap 3 ,$/d
/^BSD login class$/ {
N
@@ -47,12 +58,8 @@ case "$OUTFILE" in
if [ X"$SEMAN" != X"1" ]; then
SE_FLAG='/^.*\n\.Op Fl r Ar role/{;N;/^.*\n\.Ek$/d;};/^.*\n\.Op Fl t Ar type/{;N;/^.*\n\.Ek$/d;};'
cat >>"$OUTFILE" <<-'EOF'
- /^\.It Fl r Ar role/,/newline character\.$/ {
- d
- }
- /^\.It Fl t Ar type/,/specified role\.$/ {
- d
- }
+ /^\.It Fl r Ar role/,/^\.Ar role \.$/d
+ /^\.It Fl t Ar type/,/derived from the role\.$/d
/^SELinux role and type$/ {
N
/^SELinux role and type\n\.It$/d
@@ -103,12 +110,8 @@ case "$OUTFILE" in
# BSD login class
if [ X"$LCMAN" != X"1" ]; then
cat >>"$OUTFILE" <<-'EOF'
- /^On BSD systems/,/\.$/ {
- d
- }
- /^\.It use_loginclass$/,/^\.It/ {
- /^\.It [^u][^s][^e][^_][^l]/!d
- }
+ /^On BSD systems/,/\.$/d
+ /^\.It use_loginclass$/,/^by default\./d
EOF
fi
@@ -120,15 +123,8 @@ case "$OUTFILE" in
N
d
}
- /^\.It limitprivs$/,/^\.It/ {
- /^\.It [^l][^i][^m][^i][^t]/!d
- }
- /^\.It privs$/,/^\.It/ {
- /^\.It [^p][^r][^i][^v][^s]$/!d
- }
- /^On Solaris 10/,/^\.Pp/ {
- d
- }
+ /^\.It \(limit\)*privs$/,/is built on Solaris 10 or higher\.$/d
+ /^On Solaris 10/,/^\.Pp/d
EOF
fi
@@ -140,9 +136,7 @@ case "$OUTFILE" in
N
d
}
- /^\.It [rt][oy][lp]e$/,/^\.It/ {
- /^\.It [^rt][^oy][^lp][^e]$/!d
- }
+ /^\.It [rt][oy][lp]e$/,/is built with SELinux support\.$/d
EOF
fi
;;