-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Am 08.07.2014 12:35, schrieb Johannes Meixner:
> 
> Hello Thomas,
> 
> On Jul 8 11:55 Thomas Biege wrote (excerpt):
>> I would suggest to set PATH to a safe value (/bin, /sbin,
>> /usr/bin, /usr/sbin, maybe more) in your code and use the short
>> form of the command for your convenience.
> 
> I wonder if the ordering of the directories in PATH is of
> importance?
> 
> In https://bugzilla.novell.com/show_bug.cgi?id=794084#c11 you
> suggested to set PATH to /bin:/usr/bin:/sbin:/usr/sbin
> 
> root has after log in 
> /sbin:/usr/sbin:/usr/local/sbin:/root/bin:/usr/local/bin:/usr/bin:/bin:...

This
> 
one looks good and we use it already.

> 
> In bash scripts and when running commands in yast2-printer I use 
> ---------------------------------------------------------------------
>
> 
# Make sure to have a clean environment:
> export PATH="/sbin:/usr/sbin:/usr/bin:/bin" export LC_ALL="POSIX" 
> export LANG="POSIX" umask 022 
> ---------------------------------------------------------------------
>
>  I would appreciate an authoritative "recommended default way" how
> to set up a reasonably clean environment before calling programs as
> root.
> 
> Is perhaps calling "su - root" a reasonable way?

For executing "rm"?

Bye,
Thomas


> 
> 
> Kind Regards Johannes Meixner


- -- 
Thomas Biege <[email protected]>, Team Leader MaintenanceSecurity, CSSLP
SUSE LINUX Products GmbH
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer
HRB 21284 (AG Nürnberg)
- --
  Wer aufhoert besser werden zu wollen, hoert auf gut zu sein.
                            -- Marie von Ebner-Eschenbach
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJTu/2uAAoJEJqHoVJVjr8DQzYIAMVoHj4KaPx/eJz+U+gEwpgY
EdTWBhMHZRuHAJpvBM99hv7I1Sf36tmXY4VOv6nkzmKLBEc3pr7Yuwa+Jk6W2g9K
meDsz0Fj8RPQM4IKj137MZZdIEIaF2MbNXXgbL33C+lb2NR5c8E3BuH6xjqPaRSv
Bx90YrWu2NlX7GWR1j1nm3CR/scEEVVAltHqKG1M7+qBwx6bMR6KasMwtJ7af4Ks
uZvO+iFESUSH/8yICSfeEcwhaSaFLZgBn2TZoSJHgIi9IHflQ59GS6nrBVco9XUU
7DTIhUfj5wYE/OWfl4DRaDPqWN5Tm0Pq7G4X8QzM14dU/QoO8AbAI0IJNIobaCw=
=i9CG
-----END PGP SIGNATURE-----
-- 
To unsubscribe, e-mail: [email protected]
To contact the owner, e-mail: [email protected]

Reply via email to