mirror of
https://github.com/sudo-project/sudo.git
synced 2025-08-29 05:17:54 +00:00
Preserve SUDO_EDITOR, EDITOR, and VISUAL for visudo.
This commit is contained in:
parent
14a8d9c09a
commit
1db1453556
9
configure
vendored
9
configure
vendored
@ -827,6 +827,7 @@ PRELOAD_MODULE
|
|||||||
INSTALL_NOEXEC
|
INSTALL_NOEXEC
|
||||||
INSTALL_INTERCEPT
|
INSTALL_INTERCEPT
|
||||||
INSTALL_BACKUP
|
INSTALL_BACKUP
|
||||||
|
visudo
|
||||||
sesh_file
|
sesh_file
|
||||||
noexec_file
|
noexec_file
|
||||||
NOEXECDIR
|
NOEXECDIR
|
||||||
@ -3724,6 +3725,7 @@ netsvc_conf=/etc/netsvc.conf
|
|||||||
intercept_file="$libexecdir/sudo/sudo_intercept.so"
|
intercept_file="$libexecdir/sudo/sudo_intercept.so"
|
||||||
noexec_file="$libexecdir/sudo/sudo_noexec.so"
|
noexec_file="$libexecdir/sudo/sudo_noexec.so"
|
||||||
sesh_file="$libexecdir/sudo/sesh"
|
sesh_file="$libexecdir/sudo/sesh"
|
||||||
|
visudo="$sbindir/visudo"
|
||||||
nsswitch_conf=/etc/nsswitch.conf
|
nsswitch_conf=/etc/nsswitch.conf
|
||||||
secure_path="not set"
|
secure_path="not set"
|
||||||
pam_session=on
|
pam_session=on
|
||||||
@ -35839,6 +35841,13 @@ while test X"$noexec_file" != X"$_noexec_file"; do
|
|||||||
eval "noexec_file=\"$_noexec_file\""
|
eval "noexec_file=\"$_noexec_file\""
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Update exec_prefix in visudo
|
||||||
|
_visudo=
|
||||||
|
while test X"$visudo" != X"$_visudo"; do
|
||||||
|
_visudo="$visudo"
|
||||||
|
eval "visudo=\"$_visudo\""
|
||||||
|
done
|
||||||
|
|
||||||
# Update exec_prefix in sesh_file
|
# Update exec_prefix in sesh_file
|
||||||
_sesh_file=
|
_sesh_file=
|
||||||
while test X"$sesh_file" != X"$_sesh_file"; do
|
while test X"$sesh_file" != X"$_sesh_file"; do
|
||||||
|
@ -75,6 +75,7 @@ AC_SUBST([NOEXECFILE])dnl
|
|||||||
AC_SUBST([NOEXECDIR])dnl
|
AC_SUBST([NOEXECDIR])dnl
|
||||||
AC_SUBST([noexec_file])dnl
|
AC_SUBST([noexec_file])dnl
|
||||||
AC_SUBST([sesh_file])dnl
|
AC_SUBST([sesh_file])dnl
|
||||||
|
AC_SUBST([visudo])dnl
|
||||||
AC_SUBST([INSTALL_BACKUP])dnl
|
AC_SUBST([INSTALL_BACKUP])dnl
|
||||||
AC_SUBST([INSTALL_INTERCEPT])dnl
|
AC_SUBST([INSTALL_INTERCEPT])dnl
|
||||||
AC_SUBST([INSTALL_NOEXEC])dnl
|
AC_SUBST([INSTALL_NOEXEC])dnl
|
||||||
@ -225,6 +226,7 @@ netsvc_conf=/etc/netsvc.conf
|
|||||||
intercept_file="$libexecdir/sudo/sudo_intercept.so"
|
intercept_file="$libexecdir/sudo/sudo_intercept.so"
|
||||||
noexec_file="$libexecdir/sudo/sudo_noexec.so"
|
noexec_file="$libexecdir/sudo/sudo_noexec.so"
|
||||||
sesh_file="$libexecdir/sudo/sesh"
|
sesh_file="$libexecdir/sudo/sesh"
|
||||||
|
visudo="$sbindir/visudo"
|
||||||
nsswitch_conf=/etc/nsswitch.conf
|
nsswitch_conf=/etc/nsswitch.conf
|
||||||
secure_path="not set"
|
secure_path="not set"
|
||||||
pam_session=on
|
pam_session=on
|
||||||
@ -4301,6 +4303,13 @@ while test X"$noexec_file" != X"$_noexec_file"; do
|
|||||||
eval "noexec_file=\"$_noexec_file\""
|
eval "noexec_file=\"$_noexec_file\""
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Update exec_prefix in visudo
|
||||||
|
_visudo=
|
||||||
|
while test X"$visudo" != X"$_visudo"; do
|
||||||
|
_visudo="$visudo"
|
||||||
|
eval "visudo=\"$_visudo\""
|
||||||
|
done
|
||||||
|
|
||||||
# Update exec_prefix in sesh_file
|
# Update exec_prefix in sesh_file
|
||||||
_sesh_file=
|
_sesh_file=
|
||||||
while test X"$sesh_file" != X"$_sesh_file"; do
|
while test X"$sesh_file" != X"$_sesh_file"; do
|
||||||
|
@ -41,6 +41,10 @@
|
|||||||
##
|
##
|
||||||
## Defaults specification
|
## Defaults specification
|
||||||
##
|
##
|
||||||
|
## Preserve editor environment variables for visudo.
|
||||||
|
## To preserve these for all commands, remove the "!visudo" qualifier.
|
||||||
|
Defaults!@visudo@ env_keep += "SUDO_EDITOR EDITOR VISUAL"
|
||||||
|
##
|
||||||
## You may wish to keep some of the following environment variables
|
## You may wish to keep some of the following environment variables
|
||||||
## when running commands via sudo.
|
## when running commands via sudo.
|
||||||
##
|
##
|
||||||
|
Loading…
x
Reference in New Issue
Block a user