Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-23 Thread Lee
On 5/22/22, Charles Kroeger wrote: >> There is no silver bullet that makes your system secure. > > I get a login shell with $su --login > > I don't have sudo installed > > is there something heretical about that, I should know? If this is for your personal machine, no. If this is a multi-user en

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread tomas
On Sun, May 22, 2022 at 03:32:22PM -0400, The Wanderer wrote: > On 2022-05-22 at 14:53, Charles Kroeger wrote: > > >> There is no silver bullet that makes your system secure. > > > > I get a login shell with $su --login > > > > I don't have sudo installed > > > > is there something heretical ab

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread Greg Wooledge
On Sun, May 22, 2022 at 09:37:43PM +0200, basti wrote: > https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=918754#41 > > or use su -l For the record, that URL says: This is a new behavior because the util-linux implementation of su is used now. See also /usr/share/doc/util-linux/NEWS.Debian.

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread basti
Am 20.05.22 um 02:24 schrieb Kenneth Parker: On Thu, May 19, 2022, 4:14 AM 황병희 > wrote: Tom Browder mailto:tom.brow...@gmail.com>> writes: > I need a special path setting for root after both "sudo" and "sudo > su." (...) Just you try like

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread The Wanderer
On 2022-05-22 at 14:53, Charles Kroeger wrote: >> There is no silver bullet that makes your system secure. > > I get a login shell with $su --login > > I don't have sudo installed > > is there something heretical about that, I should know? Not heretical, but - if something has compromised your

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread Charles Kroeger
> There is no silver bullet that makes your system secure. I get a login shell with $su --login I don't have sudo installed is there something heretical about that, I should know?

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread Tom Browder
On Sun, May 22, 2022 at 11:04 Greg Wooledge wrote: ... > So... we literally can't tell what you did. I think that character munging is because of the unwanted, unedititible html mail from my ipad gmail client. Still wondering why you can't just use the other solutions you've been > given. If

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread Tom Browder
On Sat, May 21, 2022 at 10:40 Greg Wooledge wrote: ... > So, I've already given you the solution that *I* would use, which is: > > ln -s /opt/raku/bin/raku /usr/local/bin/raku That works fine, but another part of the work flow for nstallation is the need to access another Raku program which mus

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread Greg Wooledge
On Sun, May 22, 2022 at 10:48:44AM -0500, Tom Browder wrote: > Yes, I actually used that syntax but failed to put it in the message—same > result: > > sudo —preserve-env=PATH raku -v > sudo: raku: command not found You might have misspelled --preserve. It's hard to tell, because what y

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread Tom Browder
On Sun, May 22, 2022 at 09:02 wrote: … Socratic -- I fear you over-estimate me badly :-) You are too modest! Note that the key --preserve-env takes an arg. That would be > > --preserve-env=PATH > > to pass on the PATH environment variable. The arg is a comma separated > list of environment v

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-22 Thread tomas
[reinserted the copy to list: others tend to have better ideas than me] On Sun, May 22, 2022 at 06:15:57AM -0500, Tom Browder wrote: > On Sat, May 21, 2022 at 11:28 wrote: > ... > > > I'm sure the OP is now able to locate that "security policy" config > > and change it to taste. "--preserve-env=

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread tomas
On Sat, May 21, 2022 at 06:04:07PM +0200, Linux-Fan wrote: > Greg Wooledge writes: > > > On Sat, May 21, 2022 at 10:04:01AM -0500, Tom Browder wrote: > > > I am getting nowhere fast. > > > > OK, let's start at the beginning. > > > > You have raku installed in some directory that is not in a regu

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread Linux-Fan
Greg Wooledge writes: On Sat, May 21, 2022 at 10:04:01AM -0500, Tom Browder wrote: > I am getting nowhere fast. OK, let's start at the beginning. You have raku installed in some directory that is not in a regular PATH. You won't tell us what this directory is, so let's pretend it's /opt/raku/

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread Greg Wooledge
On Sat, May 21, 2022 at 10:04:01AM -0500, Tom Browder wrote: > I am getting nowhere fast. OK, let's start at the beginning. You have raku installed in some directory that is not in a regular PATH. You won't tell us what this directory is, so let's pretend it's /opt/raku/bin/raku. You have added

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread Tom Browder
On Sat, May 21, 2022 at 09:02 Greg Wooledge wrote: > On Sat, May 21, 2022 at 03:19:09PM +0200, to...@tuxteam.de wrote: > > Less typing, more general. Nobody's trying to dissuade you of doing > > "sudo bash" or "sudo su" or... > I am getting nowhere fast. I think all will be okay if (and only if)

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread Greg Wooledge
On Sat, May 21, 2022 at 03:19:09PM +0200, to...@tuxteam.de wrote: > Less typing, more general. Nobody's trying to dissuade you of doing > "sudo bash" or "sudo su" or... I'm definitely trying to dissuade people from doing the latter. It's one of those horrible memes that has spread maliciously for

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread tomas
On Sat, May 21, 2022 at 11:12:01AM +, Lee wrote: > On 5/19/22, Tom Browder wrote: > > On Thu, May 19, 2022 at 03:54 Kamil Jońca wrote: > > > >> It is quite misterious for me. > >> What is the purpose of "sudo su" instead of plain "sudo" or "sudo -i" > < .. snip ..> > > > > I have for years n

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread Brian
On Sat 21 May 2022 at 12:24:04 +0100, Tixy wrote: > On Fri, 2022-05-20 at 18:44 +0100, Brian wrote: > > On Thu 19 May 2022 at 20:24:50 -0400, Kenneth Parker wrote: > > > > [...] > > > > > Note, Debian (at least in the Expert Installation Mode) lets me set a Root > > > Password. Ubuntu doesn't,

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread Tixy
On Fri, 2022-05-20 at 18:44 +0100, Brian wrote: > On Thu 19 May 2022 at 20:24:50 -0400, Kenneth Parker wrote: > > [...] > > > Note, Debian (at least in the Expert Installation Mode) lets me set a Root > > Password. Ubuntu doesn't, so one of my early actions after the Install is > > to enter "su

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-21 Thread Lee
On 5/19/22, Tom Browder wrote: > On Thu, May 19, 2022 at 03:54 Kamil Jońca wrote: > >> It is quite misterious for me. >> What is the purpose of "sudo su" instead of plain "sudo" or "sudo -i" < .. snip ..> > > I have for years now not used the many variants of su, just "sudo" alone > for one-off

Re: Avoiding command hijacking in shells (was Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11))

2022-05-20 Thread Greg Wooledge
On Fri, May 20, 2022 at 09:36:40PM -0400, The Wanderer wrote: > I wasn't even thinking of it in those terms, although now that you point > it out that's a good thing to be aware of. I was thinking of it in terms > of A: trying to write scripts that are safe against such problematic > elements being

Re: Avoiding command hijacking in shells (was Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11))

2022-05-20 Thread The Wanderer
On 2022-05-20 at 21:20, Greg Wooledge wrote: > On Fri, May 20, 2022 at 08:41:43PM -0400, The Wanderer wrote: > >> On 2022-05-20 at 20:28, David Wright wrote: >> >> > $ function /usr/bin/sudo { echo teehee; } >> > $ /usr/bin/sudo whatever >> > teehee >> > $ >> >> A quick test demonstrates that th

Re: Avoiding command hijacking in shells (was Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11))

2022-05-20 Thread Greg Wooledge
On Fri, May 20, 2022 at 08:41:43PM -0400, The Wanderer wrote: > On 2022-05-20 at 20:28, David Wright wrote: > > $ function /usr/bin/sudo { echo teehee; } > > $ /usr/bin/sudo whatever > > teehee > > $ > > A quick test demonstrates that this can be worked around via the 'unset' > command: Until yo

Avoiding command hijacking in shells (was Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11))

2022-05-20 Thread The Wanderer
On 2022-05-20 at 20:28, David Wright wrote: > On Thu 19 May 2022 at 15:42:33 (-0500), Nicholas Geovanis wrote: > >> On Thu, May 19, 2022, 3:14 AM 황병희 wrote: >> > Tom Browder writes: >> > >> > > I need a special path setting for root after both "sudo" and "sudo >> > > su." (...) >> > >> > Just yo

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-20 Thread Nicholas Geovanis
On Fri, May 20, 2022, 7:28 PM David Wright wrote: > On Thu 19 May 2022 at 15:42:33 (-0500), Nicholas Geovanis wrote: > > On Thu, May 19, 2022, 3:14 AM 황병희 wrote: > > > Tom Browder writes: > > > > > > > I need a special path setting for root after both "sudo" and "sudo > > > > su." (...) > > > >

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-20 Thread David Wright
On Thu 19 May 2022 at 15:42:33 (-0500), Nicholas Geovanis wrote: > On Thu, May 19, 2022, 3:14 AM 황병희 wrote: > > Tom Browder writes: > > > > > I need a special path setting for root after both "sudo" and "sudo > > > su." (...) > > > > Just you try like as "sudo su -". Sometimes i use it that way.

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-20 Thread Brian
On Thu 19 May 2022 at 20:24:50 -0400, Kenneth Parker wrote: [...] > Note, Debian (at least in the Expert Installation Mode) lets me set a Root > Password. Ubuntu doesn't, so one of my early actions after the Install is > to enter "sudo su -" and, on the resulting Root Shell, type "passwd root".

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Timothy M Butterworth
On Thu, May 19, 2022 at 8:25 PM Kenneth Parker wrote: > > > On Thu, May 19, 2022, 4:14 AM 황병희 wrote: > >> Tom Browder writes: >> >> > I need a special path setting for root after both "sudo" and "sudo >> > su." (...) >> >> You do not need to use sudo with su. When you enter su you are prompted

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Kenneth Parker
On Thu, May 19, 2022, 4:14 AM 황병희 wrote: > Tom Browder writes: > > > I need a special path setting for root after both "sudo" and "sudo > > su." (...) > > Just you try like as "sudo su -". Sometimes i use it that way. > > Sincerely, Linux fan Byung-Hee > > -- > ^고맙습니다 _白衣從軍_ 감사합니다_^))// > When

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Nicholas Geovanis
On Thu, May 19, 2022, 3:14 AM 황병희 wrote: > Tom Browder writes: > > > I need a special path setting for root after both "sudo" and "sudo > > su." (...) > > Just you try like as "sudo su -". Sometimes i use it that way. > When I need to use sudo or su to invoke executables, I fully qualify the pa

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Tom Browder
On Thu, May 19, 2022 at 06:31 Greg Wooledge wrote: ... > > > > I feel like you're doing "sudo su" out of some bad habit that you've > > > developed. You'd be doing yourself a favor if you retrain yourself > > > to use "sudo -s" instead. > > > > Greg, I think I need to change the paths in the sud

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Greg Wooledge
On Thu, May 19, 2022 at 06:22:07AM -0500, Tom Browder wrote: > On Thu, May 19, 2022 at 06:03 Greg Wooledge wrote: > > > On Thu, May 19, 2022 at 05:47:29AM -0500, Tom Browder wrote: > > > $ sudo su > > > # ./myprog install > > > > Again, there's no reason to use both "sudo" AND "su". Just

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Tom Browder
On Thu, May 19, 2022 at 06:03 Greg Wooledge wrote: > On Thu, May 19, 2022 at 05:47:29AM -0500, Tom Browder wrote: > > $ sudo su > > # ./myprog install > > Again, there's no reason to use both "sudo" AND "su". Just "sudo -s" > would give you the interactive root shell, without changing di

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Greg Wooledge
On Thu, May 19, 2022 at 05:47:29AM -0500, Tom Browder wrote: > $ sudo su > # ./myprog install Again, there's no reason to use both "sudo" AND "su". Just "sudo -s" would give you the interactive root shell, without changing directory. I feel like you're doing "sudo su" out of some bad hab

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Tom Browder
On Thu, May 19, 2022 at 03:54 Kamil Jońca wrote: > Tom Browder writes: > > > I need a special path setting for root after both "sudo" and "sudo su." > How can I set that up correctly? > > It is quite misterious for me. > What is the purpose of "sudo su" instead of plain "sudo" or "sudo -i" KJ,

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread Kamil Jońca
Tom Browder writes: > I need a special path setting for root after both "sudo" and "sudo su." How > can I set that up correctly? It is quite misterious for me. What is the purpose of "sudo su" instead of plain "sudo" or "sudo -i" KJ -- http://stopstopnop.pl/stop_stopnop.pl_o_nas.html

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread 황병희
Tom Browder writes: > I need a special path setting for root after both "sudo" and "sudo > su." (...) Just you try like as "sudo su -". Sometimes i use it that way. Sincerely, Linux fan Byung-Hee -- ^고맙습니다 _白衣從軍_ 감사합니다_^))//

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-19 Thread mick crane
On 2022-05-19 04:08, Greg Wooledge wrote: A much better workaround is to create the /etc/default/su file and put the line ALWAYS_SET_PATH yes well that's handy. "su -" puts you in /root whereas with that you stay in $PWD. cheers mick

Re: setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-18 Thread Greg Wooledge
On Wed, May 18, 2022 at 09:36:56PM -0500, Tom Browder wrote: > I need a special path setting for root after both "sudo" and "sudo su." How > can I set that up correctly? Let's start by pointing out how silly the latter is. You're running TWO different setuid programs, either one of which is capab

setting path for root after "sudo su" and "sudo" for Debian Bullseye (11)

2022-05-18 Thread Tom Browder
I need a special path setting for root after both "sudo" and "sudo su." How can I set that up correctly? Searching for a definitive answer seems hopeless. Any working solution is greatly appreciated. In desperation I've thought about modifying /etc/login.defs for both root and all users, but hope

Re: Error when setting path

2003-08-17 Thread Thomas Krennwallner
Hi! On Sun Aug 17, 2003 at 02:11:45PM +0200, Wayne Gemmell wrote: > When I try to append to my current path I get the following output > > [EMAIL PROTECTED]:~$ export $PATH=$PATH:/usr/local/j2sdk1.4.2/bin/ > bash: export: > `/bin:/usr/bin:/usr/X11R6/bin:/usr/local/bin=/bin:/usr/bin:/usr/X11R6/bi

Re: Error when setting path

2003-08-17 Thread Wayne Gemmell
Hmmm, last thing on my mind... thanks, it works now Wayne On Sunday 17 August 2003 14:15, Isaac To wrote: > > "Wayne" == Wayne Gemmell <[EMAIL PROTECTED]> writes: > > Wayne> Any ideas?? These are just two of my many attempts, the second > Wayne> being as root. As you can see the direct

Re: Error when setting path

2003-08-17 Thread Isaac To
> "Wayne" == Wayne Gemmell <[EMAIL PROTECTED]> writes: Wayne> Any ideas?? These are just two of my many attempts, the second Wayne> being as root. As you can see the directory does exist but from Wayne> what I can tell that doesn't matter much. Remember that the shell language is

Error when setting path

2003-08-17 Thread Wayne Gemmell
Hi all, When I try to append to my current path I get the following output [EMAIL PROTECTED]:~$ export $PATH=$PATH:/usr/local/j2sdk1.4.2/bin/ bash: export: `/bin:/usr/bin:/usr/X11R6/bin:/usr/local/bin=/bin:/usr/bin:/usr/X11R6/bin:/usr/local/bin:/usr/local/j2sdk1.4.2/bin/': not a valid identifie

Re: Setting $PATH

2001-08-15 Thread Oliver Elphick
dman wrote: >Do you mean when you start a terminal in X you don't have ~/bin in >your path? > >All settings (such as $PATH) persist through the life of the shell. >If you start another shell you start from the beginning again (after >reading the proper config files). > >IIRC .bash_p

Re: Setting $PATH

2001-08-14 Thread dman
On Tue, Aug 14, 2001 at 08:35:46PM +0200, Jesper Holmberg wrote: | I might have misunderstood something here, but my bash{profile,rc} files | don't work as I expect. | | In my .bash_profile, I have this: | | PATH="~/bin:${PATH}" | export PATH | | This works as expected after I have logged in, I

Setting $PATH

2001-08-14 Thread Jesper Holmberg
I might have misunderstood something here, but my bash{profile,rc} files don't work as I expect. In my .bash_profile, I have this: PATH="~/bin:${PATH}" export PATH This works as expected after I have logged in, I do have ~/bin in my path. However, when I start X, my ~/bin is gone from the path.

Re: Setting PATH file...

2000-11-26 Thread patd
/etc/profile for bourne and korn based shells. On Sat, Nov 25, 2000 at 02:24:04PM -0600, Rogelio E. Castillo Haro wrote: > Do you know which is the file where I can add a path to wide-system, > including root? > > TIA > > Rogelio > > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with

Setting PATH file...

2000-11-26 Thread Rogelio E. Castillo Haro
Do you know which is the file where I can add a path to wide-system, including root? TIA Rogelio

Re: Setting Path ENV variable

1999-12-22 Thread Wayne Topa
Subject: Re: Setting Path ENV variable Date: Tue, Dec 21, 1999 at 11:15:06PM - In reply to:Pollywog Quoting Pollywog([EMAIL PROTECTED]): >| > >| > The /etc/profile PATH statement is for everyone. To add _to_ that >| > PATH you should do the f

Re: Setting Path ENV variable

1999-12-22 Thread Wayne Topa
Subject: Re: Setting Path ENV variable Date: Tue, Dec 21, 1999 at 08:26:30PM -0500 In reply to:Wayne Topa Quoting Wayne Topa([EMAIL PROTECTED]): >| >| Subject: Re: Setting Path ENV variable >| Date: Mon, Dec 20, 1999 at 03:08:33PM -0800 >| >| In reply

Re: Setting Path ENV variable

1999-12-22 Thread Wayne Topa
Subject: Re: Setting Path ENV variable Date: Mon, Dec 20, 1999 at 03:08:33PM -0800 In reply to:Andy Thomas Quoting Andy Thomas([EMAIL PROTECTED]): >| Ok... where is .bash_profile for root supposed to be located? I've got one >| for a user ("jimmy") I'

Re: Setting Path ENV variable

1999-12-21 Thread Pollywog
On 20-Dec-1999 Andy Thomas wrote: > Ok... where is .bash_profile for root supposed to be located? I've got one > for a user ("jimmy") I've created in /home/jimmy/.bash_profile and another > one in /etc/skel/.bash_profile. Edit the /etc/skel one or create a new one > in /etc? > > So is there no

Re: Setting Path ENV variable

1999-12-21 Thread Pollywog
On 21-Dec-1999 Wayne Topa wrote: > > Subject: Re: Setting Path ENV variable > Date: Sun, Dec 19, 1999 at 09:24:37PM -0800 > > In reply to:Andy Thomas > > Quoting Andy Thomas([EMAIL PROTECTED]): >>| ok.. I've found the .bashrc in /root and put t

Re: Setting Path ENV variable

1999-12-21 Thread Andy Thomas
CTED]> > To: Debian Users > Subject: Re: Setting Path ENV variable > Date: Tuesday, December 21, 1999 2:27 PM > > > Subject: Re: Setting Path ENV variable > Date: Sun, Dec 19, 1999 at 09:24:37PM -0800 > > In reply to:Andy Thomas > > Quoting Andy Thom

Re: Setting Path ENV variable

1999-12-21 Thread Wayne Topa
Subject: Re: Setting Path ENV variable Date: Sun, Dec 19, 1999 at 09:24:37PM -0800 In reply to:Andy Thomas Quoting Andy Thomas([EMAIL PROTECTED]): >| ok.. I've found the .bashrc in /root and put the path statement into there. >| Yet is still gives only the standard

Re: Setting Path ENV variable

1999-12-21 Thread Andy Thomas
e/c /space:/etc/ppp:/etc/ppp/peers" TIA for any help. Andy -- > From: ktb <[EMAIL PROTECTED]> > To: Debian Users > Subject: Re: Setting Path ENV variable > Date: Tuesday, December 07, 1999 7:44 PM > > Andy Thomas wrote: > > > > Hi, > > Run

Re: Setting Path ENV variable

1999-12-08 Thread Ethan Benson
On 7/12/99 ktb wrote: I'm by no means an expert on this but I've found that /etc/profile effects my console sessions and not my 'X' sessions. this is because xdm is broken and does not load any environment, even your .profile or .bash_profile. you have to force it by adding: set -a ## thi

Re: Setting Path ENV variable

1999-12-08 Thread ktb
Andy Thomas wrote: > > Hi, > Running Linux from O'Reilly says that the search path can be set in > .bashrc > file, but the only .bashrc I'm finding is for a user I created, not >root. > Is there a bash configuration file for root? To get to that file you have to be signed in as root or su t

Setting Path ENV variable

1999-12-08 Thread Andy Thomas
Hi, Running Linux from O'Reilly says that the search path can be set in .bashrc file, but the only .bashrc I'm finding is for a user I created, not root. Is there a bash configuration file for root? I'm trying to add some directories to the search path. I found a file named /etc/profile w