![]() |
![]() |
![]() |
||||
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() ![]() |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
![]() |
#1 |
Confirmed User
Join Date: Jan 2007
Posts: 185
|
PHP renaming folder problem
I'm trying to rename a folder from a php file and it's giving me an error. I'm getting a 'Permission Denied' error, but the folder chmod is 777 so I don't understand why I'm getting this error.
__________________
Need design work or PHP coding? -> Offbeatideas - What's your idea? Contact me for all your Predator integration needs! ---------------------------------- My Sites: SpeedySpank (70% ratio - Signup) - Liz Vicious Blog AIM: practicetitoism | ICQ: 462598451 |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
So Fucking Banned
Join Date: Jan 2005
Location: At My Desk
Posts: 2,904
|
is it outside of the script parent directory?
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
The Dirty Frenchman
Industry Role:
Join Date: Nov 2005
Location: Lost Angeles
Posts: 8,904
|
the script doesnt have permissions for the folder, you'll have to chown it to a different owner with the correct delete privileges.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 |
Confirmed User
Join Date: Jan 2007
Posts: 185
|
Yes the script is in '/includes/cron' and the folder name I want to change is just in /. I'm using full paths to the folders though.
__________________
Need design work or PHP coding? -> Offbeatideas - What's your idea? Contact me for all your Predator integration needs! ---------------------------------- My Sites: SpeedySpank (70% ratio - Signup) - Liz Vicious Blog AIM: practicetitoism | ICQ: 462598451 |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 |
The Dirty Frenchman
Industry Role:
Join Date: Nov 2005
Location: Lost Angeles
Posts: 8,904
|
It's also sort of disturbing that you advertise PHP coding, and wouldn't know something trivial like file permissions.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 |
Confirmed User
Join Date: Jan 2007
Posts: 185
|
I understand file permissions. The permissions to the folder are 777 so others should be able to execute stuff on the folder.
__________________
Need design work or PHP coding? -> Offbeatideas - What's your idea? Contact me for all your Predator integration needs! ---------------------------------- My Sites: SpeedySpank (70% ratio - Signup) - Liz Vicious Blog AIM: practicetitoism | ICQ: 462598451 |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#7 |
So Fucking Banned
Join Date: Jan 2005
Location: At My Desk
Posts: 2,904
|
are you in safe mode?
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#8 |
The Dirty Frenchman
Industry Role:
Join Date: Nov 2005
Location: Lost Angeles
Posts: 8,904
|
Yes, but there is also an OWNER of the file/folder, you fucking boob. There is a different between chroot and chown. If it's in /includes/cron then it is is most likely owned by the root user. A simple 'ls -l' will show the owner. And your script isnt being executed by the root user unless you're executing it from the command line.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#9 | |
Confirmed User
Join Date: Jan 2007
Posts: 185
|
Quote:
__________________
Need design work or PHP coding? -> Offbeatideas - What's your idea? Contact me for all your Predator integration needs! ---------------------------------- My Sites: SpeedySpank (70% ratio - Signup) - Liz Vicious Blog AIM: practicetitoism | ICQ: 462598451 |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#10 | |
The Dirty Frenchman
Industry Role:
Join Date: Nov 2005
Location: Lost Angeles
Posts: 8,904
|
Quote:
http://www.google.com The interwebz is for porn. |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#11 | |
Confirmed User
Join Date: Jan 2007
Posts: 185
|
Quote:
__________________
Need design work or PHP coding? -> Offbeatideas - What's your idea? Contact me for all your Predator integration needs! ---------------------------------- My Sites: SpeedySpank (70% ratio - Signup) - Liz Vicious Blog AIM: practicetitoism | ICQ: 462598451 |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#12 |
The Dirty Frenchman
Industry Role:
Join Date: Nov 2005
Location: Lost Angeles
Posts: 8,904
|
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#13 |
So Fucking Banned
Join Date: Jan 2005
Location: At My Desk
Posts: 2,904
|
Who cares who owns it, when its 777 its world writable
the problem is php security can not write outside its root in safe mode |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#14 | |
The Dirty Frenchman
Industry Role:
Join Date: Nov 2005
Location: Lost Angeles
Posts: 8,904
|
Quote:
When safe_mode is on, PHP checks to see if the owner of the current script matches the owner of the file to be operated on by a file function or its directory. So yes, the owner of the file matters. |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#15 |
Confirmed User
Join Date: Jan 2007
Posts: 185
|
Safe mode is off for this domain
__________________
Need design work or PHP coding? -> Offbeatideas - What's your idea? Contact me for all your Predator integration needs! ---------------------------------- My Sites: SpeedySpank (70% ratio - Signup) - Liz Vicious Blog AIM: practicetitoism | ICQ: 462598451 |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#16 |
So Fucking Banned
Join Date: Jan 2005
Location: At My Desk
Posts: 2,904
|
su_exec? come on man, fill us in on required details and then the answer will present itself
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#17 |
Confirmed User
Industry Role:
Join Date: Aug 2006
Location: Poland
Posts: 9,229
|
check for openbasedir restrictions? the user that owns it wouldn't matter, as if its chmodded to 0777 it's world writable anyways.
How are you trying to rename it? exec('mv source target') or what?
__________________
Mechanical Bunny Media Mechbunny Tube Script | Mechbunny Webcam Aggregator Script | Custom Web Development |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#18 |
So Fucking Banned
Join Date: Jan 2005
Location: At My Desk
Posts: 2,904
|
I imagine he is unsing rename()
maybe he can't rename it because he is in it? ![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#19 |
So Fucking Banned
Join Date: Oct 2002
Location: MaxCash.com
Posts: 12,745
|
I had a similar problem and it was my dumb host.... change it to 755 and try it.
It worked for me and they said it was some security shit that wouldnt let 777 work. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#20 |
Registered User
Join Date: Jan 2007
Posts: 43
|
you can try set file privilege for web..
chown www 'filename' |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#21 | |
Too lazy to set a custom title
Join Date: Dec 2006
Posts: 23,400
|
Quote:
![]()
__________________
i like waffles |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#22 | |
So Fucking Banned
Join Date: Jan 2005
Location: At My Desk
Posts: 2,904
|
Quote:
He isnt providing system info, so no sense wasting brains over this one... |
|
![]() |
![]() ![]() ![]() ![]() ![]() |