LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 04-21-2001, 07:54 PM   #1
caguru
LQ Newbie
 
Registered: Apr 2001
Posts: 6

Rep: Reputation: 0

Hello everyone.
I am new to this board, and fairly new to Linux. All of my remote web servers run linux and to this point it has made sense. Here's my dilema (probably as easy as 2+2 for yall)...

I am adding a GUI for one of my sites that will allow others with access to a password protected directory to maintain the MYSQL and the PHP pages without any knowledge of scripting.

I made several PHP files in a password protected directory that rewrite the public PHP files. Now this works without flaw on my windows2000pro machine but not on my webserver. In fact the only way I can get the hidden files to rewrite the public files is to CHMOD the public files to 777. That can't be right. I was under the impression that would allow all public users to modify the files and that is definitely not my goal.

If I remove public write access on the target file, I receive errors such as permission denied or could not include file.

Someone please explain this to me. Remember I am a windows user so I don't really understand linux lingo. I wish I did though.
 
Old 04-25-2001, 08:17 PM   #2
jeremy
root
 
Registered: Jun 2000
Distribution: Debian, Red Hat, Slackware, Fedora, Ubuntu
Posts: 10,319

Rep: Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612
If you don't want the files 777 you would need to own them to the user or group of the web server and make sure they are writable.
 
Old 04-25-2001, 10:50 PM   #3
caguru
LQ Newbie
 
Registered: Apr 2001
Posts: 6

Original Poster
Rep: Reputation: 0
owner nobody

I was recently told that I can write to the files via PHP if the owner was set to nobody. Can the owner be set to nobody via SSH on a virtual host?

If not how does the owner or group access the file rewriting pages via http. My GUI is totally built from PHP in a hidden directory.

Thanks for the input.
 
Old 04-26-2001, 07:52 AM   #4
jeremy
root
 
Registered: Jun 2000
Distribution: Debian, Red Hat, Slackware, Fedora, Ubuntu
Posts: 10,319

Rep: Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612Reputation: 2612
Apache is often setup to run as nobody. To change file ownership you would use chmod. To change group ownership you would use chgrp.
 
  


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
permissions on flat file php authentication blizunt7 Linux - Security 2 11-23-2005 06:13 AM
Apache and File Permissions Matir Linux - Security 6 08-13-2005 12:22 AM
File Permissions with Apache Herbalist Linux - Networking 5 06-17-2005 01:39 PM
File permissions with apache deee Linux - Newbie 3 03-31-2004 02:24 PM
Apache and File Permissions notstrider Linux - Networking 1 03-14-2003 11:44 AM


All times are GMT -5. The time now is 12:29 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration