file-permissions

Unsync'd Git Repository in Dropbox

I have a git repository (and working directory) that is stored in my Dropbox so I can move back and forth between computers without having to commit or stash (read: without any effort at all). This is working great except for one minor annoyance that is becoming a major annoyance. Every so often, I'll leave one computer in a fully commi...

Least Possible Permission to allow File Upload and Deletion to a file or directory?

I am trying to set the least possible permission on a file, and still be upload files and delete them. I normally use "0755", but I think it is still much for just doing uploading and deleting. ...

Are my permissions set correctly? (python)

Hello, In python I'm doing a os.system('chmod o+w filename.png') command so I can overwrite the file with pngcrush. These are the permissions after I set them in python: -rw-rw-rw- 1 me users 925 Sep 20 11:25 filename.png Then I attempt: os.system('pngcrush filename.png filename.png') which is supposed to overwrite the file, but...

What should I check for when I cannot upload files into filefield CCK fields?

I have recently moved a drupal site. (both servers run on a debian based LAMP stack) Everything works great here, including the uploading of images via a CCK filefield. Original url: dev.example.com/foo Deploying it to a test folder on the production server to a test folder for an environmental shakedown cruise lead it here: www...

Getting admin password while copy file using shutil.copy?

I m using shutil.copy from python to copy a list of files. But when i copy the files to /usr/lib/ location, i m getting permission denied as i need to be an administrator to do that. So How could i copy files with admin permission or how could i get the admin password from the user to copy the files? Ideas would be appreciated ...

Checking if a user has read permissions for a file in windows

How do you check to se if a user has read permissions for a file in windows? There is the possibility to read the authorization rules via File.GetAccessControl. This does not tell me if the user has the right to read the file through group membership... ...

Restricting Certificate access from C# Code

The use case: I have a hosting platform (server) where multiple ASP.Net applications are hosted. I do not want to have application to have programmatic access to the certificates on the Server. Only the Components/libraries that are developed by the platform owners should be able to access those certificates. Is there any way in which...

How to set the permission on files at the time of Upload through Amazon s3 API

Is there any way to set the file permission at the time of uploading files through Amazon S3 API. In my current solution i am able to upload the file on my bucket but i can not view the file through the URL which is mentioned in the file properties section. It is opening when i am passing access keys in query string. Is there any setti...

PHP file permissions

How can I set permissions of a file to let a PHP program read and write but not be read by the public. When I set read permissions it denies PHP to the files. ...

Read file with no read access in PHP

In php, I need to read a file that has no read access (the file permissions are -rw-r-----). Changing the file's permissions isn't possible. The file sits on a local server. Various methods I've tried in PHP don't work (file_get_contents, fopen, and curl) and maybe that's to be expected if that last read bit isn't set. Is that because...

ant: handling jar whose contents have file permissions 000

I am trying to overwrite the default icon of installer JAR created by IzPack, with one from my application: <jar update="yes" jarfile="${pwd}/dist/${release}_installer.jar"> <zipfileset src="${pwd}/dist/app.jar" includes="com/izforge/izpack/panels/**"/> <zipfileset src="${pwd}/dist/app.jar" includes="com/xyz/img/logo.png" fu...

777 permissions for public_html - Internal Server Error on some servers, but not others?

I have a few different servers, and on some servers, I can chmod the public_html folder to 777 permissions without problems - but on other servers, I get error messages. When trying to access the domain I get an Internal Server Error, and in my cpanel error_log on one server I get messages like the following: Fri Oct 08 09:55:39 2010] [...

Writing to a file in a directory that belongs to a different user using php

Hi, I have a server that hosts several domains. From one of the domains, using a php script I want to be able to append a few lines to the .htaccess of other domains. For example from masterdomain.com I want to append some lines to the .htaccess of otherdomain.com. So from a php file in /home/masterdomain/www/ I want to append a few li...

Probable issues with running flex application/swf in local mode.

Hi All, We are developing client application for our solution. Its a desktop client. We are using flex for same. (Although I know flex is meant for web application and air application is best suited for desktop clients, but due to some build issues we can't go for air applications). Now according to our use case we required to read file...

Server 2008 has been trying to "stop sharing" for > 1 hour. What do I do?

I copied a few million files from one disk array to another on a Server 2008 box. Then I wanted to move the share that people used to access those files, so it would point at the new location of the files. I innocently clicked "stop sharing" on the first share, thinking it would just delete a record somewhere, and deny network access to...

question regarding file permission

Hi there, i developed the application using WAMP, i think windows assigns 0644 file permission to all directory by default. i am hosting the application on Unix Server which uses cPanel 11, my application has some directories where user(admin) will be uploading files to it. what file permission should i be giving to that directory? is i...

file won't upload unless i change the file permission to 0777 on my server

hi there, i am unaware on the cons and pros of giving the directory permission to 0777, and i have left with no choice but to use the 0777 file permission to upload files on my server through my application. the following file permission works for me to upload file 0757 and 0557. this means i can upload the file with the world or othe...

FileSystemWatcher - minimum permissions needed on target directories ?

Hi - Using the .NET FileSystemWatcher http://msdn.microsoft.com/en-us/library/system.io.filesystemwatcher.aspx to monitor a directory full of files for : Changed; Created; Deleted; Renamed events . What's the minimum the rights the Account running the FileSystemWatcher needs over the directory it's watching ? It seems like it would be ...

FileShare.ReadWrite what additional permissions are needed?

The MSDN documentation for FileShare.ReadWrite says: FileShare.ReadWrite Allows subsequent opening of the file for reading or writing. If this flag is not specified, any request to open the file for reading or writing (by this process or another process) will fail until the file is closed. However, even if this flag i...

Noob question about writing PHP template, copy(), and UNIX permissions

This is a noob PHP writing to system question. Are there restrictions to php's copy() function writing within a password protected directory? I'm trying to write the generated html content from a template page. I'm getting: "401 Unauthorized The requested page requires authentication" File permissions for the template file, destinati...