LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   regarding : file not accessible even with chmod 777 (http://www.linuxquestions.org/questions/linux-newbie-8/regarding-file-not-accessible-even-with-chmod-777-a-786126/)

linux2010 02-01-2010 12:59 AM

regarding : file not accessible even with chmod 777
 
hi

my application runs on user account and needs access to a file on which it has to work. when the file and the corresponding script is kept at certain location then the application is bale to have access to the file.

If the location of either the file or the script is changed with 777 permission to them even then the application given : "file is not accessible"

i have tried this( put these file and script) in root made folders and also in user made folders with 777 permission but results the same- " "file is not accessible"

Plz advice what may be the issues and how to resolve it.


thanks and regards

Dave_Devnull 02-01-2010 03:13 AM

A couple of things cross my mind;

Who does the file you are trying to access belong to, what group is it in, and what are it's permissions? Does your script fall into the bounds of those permissions?

Is there an Secure Linux context on the files stopping script access?
Is your script running chrooted and unable to access the location of the file?

linux2010 02-01-2010 11:32 PM

reply
 
Quote:

Originally Posted by Dave_Devnull (Post 3848009)
A couple of things cross my mind;

Who does the file you are trying to access belong to, what group is it in, and what are it's permissions? Does your script fall into the bounds of those permissions?

Is there an Secure Linux context on the files stopping script access?
Is your script running chrooted and unable to access the location of the file?

hi

the file is belongs to the user, the script belongs to the user. There is no grouping . The system has only root and this user.The folder containing the file and the script has chmod 777.

:" Is there an Secure Linux context on the files stopping script access?
Is your script running chrooted and unable to access the location of the file?"
How can i check these both things. This is right that the application was installed from root. but application runs from user.

plz help.

thanks

Dave_Devnull 02-02-2010 12:13 AM

It would be a big help if you could tell us what distro this is, a directory listing (with ls -alh) showing the directory that contains the file your script is trying to access, and the output of 'stat /the/file/concerned'.

chrism01 02-02-2010 01:14 AM

Also

ls -lZ /the/file/concerned

(lowercase L there)

Dave_Devnull 02-02-2010 01:25 AM

Nice touch Chris - you learn something new everyday:

' -Z, --context
print any SELinux security context of each file'

Thanks for that ;-)

chrism01 02-02-2010 05:35 PM

any time ... ;)
I've been reading up on security for a few mths now in quiet work periods; its amazing what you learn
:)


All times are GMT -5. The time now is 11:21 PM.