Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Tue 20 Nov 2018, 01:50
All times are UTC - 4
 Forum index » House Training » Beginners Help ( Start Here)
How to manage user accounts in Puppy?
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [8 Posts]  
Author Message
d_vineet


Joined: 06 Aug 2018
Posts: 74
Location: Bharat

PostPosted: Mon 13 Aug 2018, 05:46    Post subject:  How to manage user accounts in Puppy?  

By going through http://puppylinux.org/wikka/Security , I added a user and changed password.
Does this mean that now puppylinux now supports multiple users?. If so, how do I manage the new user, i.e. modify the authority, delete user, etc.

Secondly, how do I switch users (whether created by me or system generated, i.e. root, spot & fido).
(the wikka says "su -c application YourNickHere" for running an app as other user.).
Back to top
View user's profile Send private message 
rockedge


Joined: 11 Apr 2012
Posts: 854
Location: Connecticut, United States

PostPosted: Mon 13 Aug 2018, 10:42    Post subject:  

open /etc/passwd , it will look like this somewhat:
Code:
root:x:0:0:root:/root:/bin/sh
daemon:x:1:1::/:
nobody:x:65534:65534::/tmp:
spot:x:502:502:Linux User,,,:/root/spot:/bin/sh
bin:x:2:2:bin:/bin:
messagebus:x:503:503:Linux User,,,:/tmp:/bin/sh
ftp:x:1000:1000:Linux User,,,:/root/ftpd:/bin/sh
haldaemon:x:108:119:Hardware abstraction layer,,,:/var/run/hald:/bin/false
uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
sshd:x:33:33:sshd:/:
webuser:x:1002:504:Linux User,,,:/root/Web-Server:/bin/sh
fido:x:1001:500:Linux User,,,:/root:/bin/sh
man:x:65534:65534::/tmp:

now I added a user "www-data" and it will look like this :
Code:
root:x:0:0:root:/root:/bin/sh
daemon:x:1:1::/:
nobody:x:65534:65534::/tmp:
spot:x:502:502:Linux User,,,:/root/spot:/bin/sh
bin:x:2:2:bin:/bin:
messagebus:x:503:503:Linux User,,,:/tmp:/bin/sh
ftp:x:1000:1000:Linux User,,,:/root/ftpd:/bin/sh
haldaemon:x:108:119:Hardware abstraction layer,,,:/var/run/hald:/bin/false
uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
sshd:x:33:33:sshd:/:
webuser:x:1002:504:Linux User,,,:/root/Web-Server:/bin/sh
fido:x:1001:500:Linux User,,,:/root:/bin/sh
man:x:65534:65534::/tmp:
www-data:x:1003:1003:Linux User,,,:/home/www-data:/bin/bash


notice "/home/www-data"

now change that to "/root/www-data" and save.
this will now have a "home" directory assigned to that user "www-data" that is in your /root
to create the directory in a terminal:
Code:
mkdir /root/www-data

then in a terminal:
Code:
chown -R www-data /root/www-data


you can use
Code:
su www-data

to be that user
Back to top
View user's profile Send private message Visit poster's website 
d_vineet


Joined: 06 Aug 2018
Posts: 74
Location: Bharat

PostPosted: Tue 14 Aug 2018, 01:40    Post subject:  

rockedge wrote:

you can use
Code:
su www-data

to be that user

Thanks for your answer.
I assume changing the user in this way would be effective for that particular console operation and not for the entire session?
Back to top
View user's profile Send private message 
Mike Walsh


Joined: 28 Jun 2014
Posts: 4383
Location: King's Lynn, UK.

PostPosted: Tue 14 Aug 2018, 06:06    Post subject:  

@ d_vineet:-

Rockedge's answer is indeed helpful, but.....Y'know, I hate to say it, but you're still thinking like an Ubuntu user.

What you have to understand with Puppy is that it was never intended to be a 'multi-user' system. It's intended for a single user who wants to be in full control of his/her system at all times (usually with elderly hardware that most people will turn their noses up at, and which they would have consigned to the scrapheap years ago.) And, TBH, if you're the only person who ever uses your system, why do you need to have to log-in to it, hmm?

Have a read of this article from the 'PuppyMaster' himself, Barry K:-

http://bkhome.org/archive/puppylinux/technical/root.htm

Sure, you can add users, and extra passwords, and all the rest of that malarkey.....but if you want all that, then Puppy's not really the distro for you. You're bastardizing Puppy into something it was never meant to be.

Please don't think I'm 'having a go at you', because I'm not; I do understand where you're 'coming from'. I spent a year as an Ubuntu user myself.....and the prevailing mind-set is that to run anything at all as /root is incredibly dangerous, akin to juggling with sticks of dynamite, or fooling around with jars of glycerin! (Which is kinda daft, really, since the only stuff root is protecting is the stuff that's the easiest of all to replace; the system files themselves.....)

Your personal data is far more important to you. It took me some time to adjust to the Puppy way of looking at things; but having done so, I haven't had a single 'root-related' catastrophe in the last 4 years or so.

IMHO, it really is way over-hyped......


Mike. Wink

_________________
MY PUPPY PACKAGES | 'Thanks' are always appreciated!
--------------------------------------


Last edited by Mike Walsh on Tue 14 Aug 2018, 12:38; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website 
d_vineet


Joined: 06 Aug 2018
Posts: 74
Location: Bharat

PostPosted: Tue 14 Aug 2018, 08:03    Post subject:  

Mike Walsh wrote:
@ d_vineet:-

Rockedge's answer is indeed helpful, but.....Y'know, I hate to say it, but you're still thinking like an Ubuntu user.

Yes you are right. I need to get out of 'Ubuntu mindset' while using puppy.
Quote:

And, TBH, if you're the only person who ever uses your system, why do you need to have to log-in to it, hmm?

Yeah. That's right.
If the need was 'multiuser', there are a lot of other distros.
Really I do not need multiuser OS on private laptop.
Back to top
View user's profile Send private message 
mikeslr


Joined: 16 Jun 2008
Posts: 2791
Location: 500 seconds from Sol

PostPosted: Tue 14 Aug 2018, 10:32    Post subject: The Danger of Having to Run Browsers as Spot  

Hi d_vineet,

Just to add salt to the wound, Chrome-and-Clones Ubuntu Style Mindset has resulted in compromising Puppy's integrity (but of course, there's a workaround, but not perfect),

A frugally installed Puppy begins life as a several Read-Only compressed files read into Random Access Memory. On bootup, Puppy creates its operating system in Random Access Memory. At first shutdown, you're offered the opportunity to create s SaveFile or SaveFolder which will be used to store the settings, configurations you've made and applications you've installed. Since you may later change settings/configurations and add additional applications, this is a READ-WRITE file. If you decline to create it, you'll always boot into a pristine operating system: whatever was in RAM is cleared at shutdown. But if you create a SaveFile/Folder the mistakes you make, junk picked up on the internet and possibly malware will be written to the SaveFile/Folder and become part of your operating system.

When a Save is executed, whatever is in RAM --with, AFAIK, the exception of files in /tmp-- is written to the SaveFile/Folder.

To avoid that happening inadvertantly, you can turn-off Puppy's Automatic Save --see this link, but earlier posts on its thread for instructions "How to", http://murga-linux.com/puppy/viewtopic.php?p=974066#974066 and only execute a manual Save immediately on bootup, before you've gone on line, but after testing your changes/additions during your prior session and shutting down without performing a Save.

Chrome-and-clones, however, are now so constructed by their originators that they can not be run as Root. Consequently, Puppy Devs have to configure them to run as Spot. Spot resides as a folder in /root, e.g. /root/spot. Like other applications, it is created in RAM 'for this session only' by reading into RAM the files in "storage" whether a separate compressed READ-Only file, e.g. Chromium.sfs, or the files written to the SaveFile/Folder. To preserve their settings, bookmarks, addons from one session to the next, you have to perform a SAVE. How do you install an addon if you're not online? How do you add to your bookmarks if you're not online? Of course, google doesn't want you to store your bookmarks locally, It want you to sync so that it will have a copy of everything you think important.

And, having gone online to make changes to your Chrome-and-clones browser, whatever junk you've picked up on line gets written to your SaveFile/Folder when you've performed a Save.

Of course, you should make those changes immediately on bootup before you may inadvertently wander into strange territory. Still, the overall security of the system has been weakened.

Compare that to using fredx181's firefox-quantum which can be run from /mnt/home where settings, bookmarks, addons are maintained in its folder on /mnt/home and created/deleted/changed by the program itself without having to execute a Save. I've mentioned fredx181's firefox as it is the easiest to setup on /mnt/home. But with the exception of those Chrome-and-clones published afer about November 2017, most browsers could be setup not to require a Save to preserve changes.

mikesLr

Last edited by mikeslr on Tue 14 Aug 2018, 11:14; edited 1 time in total
Back to top
View user's profile Send private message 
fredx181


Joined: 11 Dec 2013
Posts: 3541
Location: holland

PostPosted: Tue 14 Aug 2018, 11:06    Post subject:  

mikeslr wrote:
I've mentioned fredx181's firefox as it is the easiest to setup on /mnt/home.


But... where do I find fredx181's firefox-quantum Question Wink Very Happy
Ah.. got it, it's Here

_________________
Dog Linux website
Back to top
View user's profile Send private message 
rockedge


Joined: 11 Apr 2012
Posts: 854
Location: Connecticut, United States

PostPosted: Tue 14 Aug 2018, 11:26    Post subject:  

the only reason I add other users other than root are for web servers and a mysql database server.....that are exposed to Internet and are designed that way.
Back to top
View user's profile Send private message Visit poster's website 
Display posts from previous:   Sort by:   
Page 1 of 1 [8 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » House Training » Beginners Help ( Start Here)
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0482s ][ Queries: 12 (0.0033s) ][ GZIP on ]