LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 02-16-2016, 12:15 PM   #1
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
permissions to the www directory structure


I just followed some hary instructions on how to set up a virtual host, (its now working fully yet) while i wait to get that done.

it had me set up the dir structure,

Code:
/www/doman-name/html/cgi-bin
A few others as it all pertains listing all of them is not necessary.
the instructions had me created the dir structure then add
Code:
useradd -d /www/your-domain/ domain_user
doing this gives that domain_user a group name of the same. adding another to the domain_user group name.

should it not also allow another, different user that has been added to this group the same permissions as the group has?

Quote:
brainwave:x:1001:userx

%userx@voided 12:07:47 ~ >>$ ls -la /www/brainwave.bw
total 20
drwxr-xr-x 5 brainwave brainwave 4096 Feb 16 10:19 .
drwxr-xr-x 3 root root 4096 Feb 16 10:18 ..
drwxr-xr-x 2 mysql mysql 4096 Feb 16 10:19 databases
drwxr-xr-x 3 brainwave brainwave 4096 Feb 16 10:43 html
drwxr-xr-x 2 brainwave brainwave 4096 Feb 16 10:44 logs

%userx@voided 12:08:15 ~ >>$ ls -la /www/brainwave.bw/html/
total 16
drwxr-xr-x 3 brainwave brainwave 4096 Feb 16 10:43 .
drwxr-xr-x 5 brainwave brainwave 4096 Feb 16 10:19 ..
drwxr-xr-x 2 brainwave brainwave 4096 Feb 16 10:18 cgi-bin
-rw-r--r-- 1 userx brainwave 95 Feb 16 09:33 index.html
the index.html file that is in there was put there when I was in root shell then I changed the userwner .

then I tried creating a php file then move it into that directoy, but getting a, no way dude! no permissions yea'!, error.

Code:
 %userx@voided 12:11:32 ~ >>$1 mv phpinfo.php /www/brainwave.bw/html/
mv: cannot create regular file '/www/brainwave.bw/html/phpinfo.php': Permission denied
is that root /www being owned by root preventing this from taking place, and if yes, how to get around this?
 
Old 02-16-2016, 12:38 PM   #2
dr_agon
Member
 
Registered: Sep 2007
Location: Poland
Distribution: Ubuntu LTS
Posts: 105
Blog Entries: 12

Rep: Reputation: 26
Quote:
drwxr-xr-x 3 brainwave brainwave 4096 Feb 16 10:43 html
Directory /www/brainwave.bw/html/ is not group-writable and you (userx) are not the owner (brainwave).
If userx is already in brainwave group - just give the group write access to html directory.
 
Old 02-16-2016, 01:13 PM   #3
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Original Poster
Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
got it working now thanks
 
Old 02-16-2016, 01:29 PM   #4
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Glad it worked out.
 
Old 02-16-2016, 01:38 PM   #5
BW-userx
LQ Guru
 
Registered: Sep 2013
Location: Somewhere in my head.
Distribution: Slackware (15 current), Slack15, Ubuntu studio, MX Linux, FreeBSD 13.1, WIn10
Posts: 10,342

Original Poster
Rep: Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242Reputation: 2242
happy I'mm mking your day cheers lol

now I got a scrub my brain and remember html and css again, .. oh yeah just Google it lol
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Modify the directory entry structure of a directory to show manipulated data shreyas08 Linux - Newbie 1 12-13-2011 05:34 AM
Convert directory structure from long file names in Linux to DOS 8.3 structure? manorina Linux - Software 5 09-12-2009 09:18 AM
how to apply "chmod g+r" permissions to a deep file and directory structure htamayo Linux - Newbie 3 03-20-2009 03:45 PM
Home Jail Folder Structure like Gobolinux Directory Structure luispt Linux - General 3 07-26-2008 06:46 PM
Samba folder permissions and structure question ajdowntown Linux - Server 0 03-08-2007 12:54 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 08:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration