Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-11 Thread David Wright
On Wed 11 May 2022 at 20:26:20 (+0200), to...@tuxteam.de wrote: > On Wed, May 11, 2022 at 11:07:09AM -0500, David Wright wrote: > > [...] > > > But after two posts about background information on setuid shell > > scripts, you now write "the worst antipattern is to misuse tech > > to force people

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-11 Thread tomas
On Wed, May 11, 2022 at 11:07:09AM -0500, David Wright wrote: [...] > But after two posts about background information on setuid shell > scripts, you now write "the worst antipattern is to misuse tech > to force people to follow some nonsensical rituals". Strong words. Sorry if I was unclear. Th

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-11 Thread David Wright
On Wed 11 May 2022 at 07:05:47 (+0200), to...@tuxteam.de wrote: > On Tue, May 10, 2022 at 10:08:20PM -0500, David Wright wrote: > > On Tue 10 May 2022 at 17:12:25 (-0600), Charles Curley wrote: > > [...] > > > IOW, though logging in to root by password is ok at the console, > > it's not ok when r

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-11 Thread Dan Ritter
Charles Curley wrote: > On Tue, 10 May 2022 11:08:23 -0500 > David Wright wrote: > > > That complicates unlocking partitions remotely because, even if you > > can log in as root, you normally can't log in remotely as root. > > ??? I log in as root over SSH all the time. Most sshd configs eithe

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-10 Thread tomas
On Tue, May 10, 2022 at 10:08:20PM -0500, David Wright wrote: > On Tue 10 May 2022 at 17:12:25 (-0600), Charles Curley wrote: [...] > IOW, though logging in to root by password is ok at the console, > it's not ok when remote. ➀ I assume you know all that you can set "PermitRootLogin yes" in your

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-10 Thread David Wright
On Tue 10 May 2022 at 17:12:25 (-0600), Charles Curley wrote: > On Tue, 10 May 2022 11:08:23 -0500 > David Wright wrote: > > > That complicates unlocking partitions remotely because, even if you > > can log in as root, you normally can't log in remotely as root. > > ??? I log in as root over SSH

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-10 Thread Greg Wooledge
On Tue, May 10, 2022 at 05:12:25PM -0600, Charles Curley wrote: > David Wright wrote: > > I use a special user called unlock, whose home directory is on > > /var/local/, to unlock my /home partitions: > > Unlock? What does "unlock" mean in this context? It looks like a > synonym for "mount". If s

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-10 Thread Charles Curley
On Tue, 10 May 2022 11:08:23 -0500 David Wright wrote: > That complicates unlocking partitions remotely because, even if you > can log in as root, you normally can't log in remotely as root. ??? I log in as root over SSH all the time. > > I use a special user called unlock, whose home director

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-10 Thread David Wright
On Tue 10 May 2022 at 13:02:41 (-0400), Greg Wooledge wrote: > On Tue, May 10, 2022 at 11:08:23AM -0500, David Wright wrote: [> > On Tue 10 May 2022 at 08:21:00 (-0600), Charles Curley wrote:] > > > Why the aversion to doing things as root? Why not just run your scripts > > > as root? This is exa

Re: Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-10 Thread Greg Wooledge
On Tue, May 10, 2022 at 11:08:23AM -0500, David Wright wrote: > > On Tue, 10 May 2022 07:50:18 -0400 rhkra...@gmail.com wrote: > > Why the aversion to doing things as root? Why not just run your scripts > > as root? This is exactly the sort of thing that is reserved to root for > > reasons of secur

Re: Help with suid (bash)

2022-05-10 Thread rhkramer
On Tuesday, May 10, 2022 10:21:00 AM Charles Curley wrote: > Why the aversion to doing things as root? Why not just run your scripts > as root? This is exactly the sort of thing that is reserved to root for > reasons of security. I may think about that some more, but it is a general aversion to be

Unlocking (remote/local), was Re: Help with suid (bash)

2022-05-10 Thread David Wright
On Tue 10 May 2022 at 08:21:00 (-0600), Charles Curley wrote: > On Tue, 10 May 2022 07:50:18 -0400 rhkra...@gmail.com wrote: > > > Background: 8 years ago I wrote a set of scripts to help me mount and > > unmount LUKS encrypted partitions as needed and as myself > > () rather than as root. > > W

Re: Help with suid (bash)

2022-05-10 Thread Charles Curley
On Tue, 10 May 2022 07:50:18 -0400 rhkra...@gmail.com wrote: > Background: 8 years ago I wrote a set of scripts to help me mount and > unmount LUKS encrypted partitions as needed and as myself > () rather than as root. Why the aversion to doing things as root? Why not just run your scripts as ro

Followup: Re: Resolved: Re: Help with suid (bash)

2022-05-10 Thread rhkramer
By the way, thanks to all who replied! One followup below. On Tuesday, May 10, 2022 08:20:10 AM rhkra...@gmail.com wrote: > Ok, thanks very much! > > That resolves that -- I do have another way of doing it (the c helper > program), I just don't like it -- I'll probably continue to use that but >

Re: Help with suid (bash)

2022-05-10 Thread tomas
On Tue, May 10, 2022 at 07:58:39AM -0400, Greg Wooledge wrote: > On Tue, May 10, 2022 at 07:50:18AM -0400, rhkra...@gmail.com wrote: > > Aside: even though this is not a Debian specific question, I often use > > debian- > > user as my first resource in asking Linux questions. > > It's Linux-speci

Resolved: Re: Help with suid (bash)

2022-05-10 Thread rhkramer
(Intentionally top posting) Ok, thanks very much! That resolves that -- I do have another way of doing it (the c helper program), I just don't like it -- I'll probably continue to use that but think about alternatives. On Tuesday, May 10, 2022 07:58:39 AM Greg Wooledge wrote: > The Linux ker

Re: Help with suid (bash)

2022-05-10 Thread tomas
On Tue, May 10, 2022 at 07:50:18AM -0400, rhkra...@gmail.com wrote: > Aside: even though this is not a Debian specific question, I often use debian- > user as my first resource in asking Linux questions. > > Background: 8 years ago I wrote a set of scripts to help me mount and unmount > LUKS encr

Re: Help with suid (bash)

2022-05-10 Thread Greg Wooledge
On Tue, May 10, 2022 at 07:50:18AM -0400, rhkra...@gmail.com wrote: > Aside: even though this is not a Debian specific question, I often use debian- > user as my first resource in asking Linux questions. It's Linux-specific, though. > -rwsr-xr-x 1 root 1412 Aug 31 2014 > The Linux kernel doe