- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- useradd creating home directory 755 instead of 700
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2012 07:38 AM
08-31-2012 07:38 AM
useradd creating home directory 755 instead of 700
HI All, Good Evening!!!
This doubt might be silly, but this is creating lot of security exposure.
When i create a user account using user add command, the home directory is getting created with 755 permission instead of 700 permission.
I've tried all means but no luck. i need the home directory to be created with 700 permission when i shoot useradd command. Can anyone help me out to resolve this issue.
Many Thanks in advance!!!
Regards,
Pradeep.
- Tags:
- useradd
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2012 08:53 AM
08-31-2012 08:53 AM
Re: useradd creating home directory 755 instead of 700
I have not been able to find a way to do that yet.
It would make sense for your umask to control that, but I set umask to 077 and a homedir was still created with 755 permissions.
I will continue to search.
- Tags:
- umask
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2012 11:55 AM
08-31-2012 11:55 AM
Re: useradd creating home directory 755 instead of 700
Is there anything in /etc/default/useradd that controls it?
Otherwise you can just use chmod go-rx after the useradd.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2012 12:10 PM
08-31-2012 12:10 PM
Re: useradd creating home directory 755 instead of 700
No, nothing in /etc/default/useradd regarding permissions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2012 12:43 PM
08-31-2012 12:43 PM
Re: useradd creating home directory 755 instead of 700
- Tags:
- SAM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2012 01:08 PM
08-31-2012 01:08 PM
Re: useradd creating home directory 755 instead of 700
>if I create the account using Sam, then home directory gets created with 700 permission.
I thought I checked recently but is there a useradd.sam like usermod.sam?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2012 02:17 PM
08-31-2012 02:17 PM
Re: useradd creating home directory 755 instead of 700
Yes, there is a /usr/sam/lbin/useradd.sam, but it is just a link to /usr/sbin/useradd. I looked at it but did not see anything that allows you to specify the homedirectory permissions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-31-2012 02:24 PM
08-31-2012 02:24 PM
Re: useradd creating home directory 755 instead of 700
>it is just a link to /usr/sbin/useradd.
The program can just look at argv[0] and do something different. Like usermod.sam.
>I looked at it but did not see anything that allows you to specify the homedirectory permissions.
But did you try it? ;-) Of course kind of hard to find options if not present in the help.