Search Results

Search found 16797 results on 672 pages for 'directory traversal'.

Page 59/672 | < Previous Page | 55 56 57 58 59 60 61 62 63 64 65 66  | Next Page >

  • cannot write to certain directory using CentOS distro

    - by fishcracker
    I have a script that will generate an image then upload it in a certain directory. The script works fine, however uploading it in the CentOS server, it won't work anymore. By debugging, I have found out that this is a permission denied issue. I am forced to chmod -R 777 certain_directory to make it work. I am not convince with this, I can't set the directory ownership to www-data I'm used to when I am using Debian. Any workaround for this?

    Read the article

  • Get Directory Size through SFTP

    - by Nongo
    A client has a managed websever; on this server is an e-commerce script and part of the script dumps a backup every week. The backup is stored on the web server (not in the HTTP route). The ISP takes a copy, and my clients wants to take a copy too. What I am trying to do is before downloading the file I want to be able to calculate the backup directory size - but the only access I have is through SFTP. Is it possible to easily get the directory size and then use this in a PowerShell Script. NOTE: I have written an automatic download script in Powershell, and I want to extend this. Forgive me if this sounds vague I can provide further info if you have any specific questions.

    Read the article

  • Unable to load directory when using jar [on hold]

    - by user1630359
    I've a directory in my eclipse project, in build path which contains files (txt). Now, when i run the application from eclipse, i can read the files (using #1 below). but, when i export my application to jar and run it from other pc i can't read the files or even check whether the directory exist or not. All the below lines are always return NULL! 1. File dir = new File("files"); 2. File dir = this.getClass().getResourceAsStream("files"); 3. File dir = this.getClass().getClassLoader().getResource("files"); any assistance will be appreciated! Thanks!

    Read the article

  • C# How to check if an FTP Directory Exists

    - by Billy Logan
    Hello Everyone, Looking for the best way to check for a given directory via FTP. currently i have the following code: private bool FtpDirectoryExists(string directory, string username, string password) { try { var request = (FtpWebRequest)WebRequest.Create(directory); request.Credentials = new NetworkCredential(username, password); request.Method = WebRequestMethods.Ftp.GetDateTimestamp; FtpWebResponse response = (FtpWebResponse)request.GetResponse(); } catch (WebException ex) { FtpWebResponse response = (FtpWebResponse)ex.Response; if (response.StatusCode == FtpStatusCode.ActionNotTakenFileUnavailable) return false; else return true; } return true; } This returns false whether the directory is there or not. Can someone point me in the right direction. Thanks in advance, Billy

    Read the article

  • Display contents of a file in the parent directory

    - by Sharjeel Sayed
    I have a command which lists Weblogic instances directories on a server.I want to display contents of a file in the parent directory of each directory listed. An additional feature would be to display the name of the file in addition to displaying the contents /usr/ucb/ps auwwx | grep weblogic | tr ' ' '\n' | grep security.policy | grep domain | awk -F'=' '{print $2}' | sed -e 's/weblogic.policy//' -e 's/security\///' | sort The output of the above command looks like this /opt/<some_directory>/<domain_name>/<app_name>/ /opt/<some_directory>/<domain_name>/<app_name>/ I want to cat a file somefile.cf in the directory

    Read the article

  • Change present working directory of a calling shell from a ruby script

    - by Erik Kastman
    I'm writing a simple ruby sandbox command-line utility to copy and unzip directories from a remote filesystem to a local scratch directory in order to unzip them and let users edit the files. I'm using Dir.mktmpdir as the default scratch directory, which gives a really ugly path (for example: /var/folders/zz/zzzivhrRnAmviuee+++1vE+++yo/-Tmp-/d20100311-70034-abz5zj) I'd like the last action of the copy-and-unzip script to cd the calling shell into the new scratch directory so people can access it easily, but I can't figure out how to change the PWD of the calling shell. One possibility is to have the utility print out the new path to stdout and then run the script as part of a subshell (i.e. cd $(sandbox my_dir) ), but I want to print out progress on the copy-and-unzipping since it can take up to 10 minutes, so this won't work. Should I just have it go to a pre-determined, easy-to-find scratch directory? Does anyone have a better suggestion? Thanks in advance for your help. -Erik

    Read the article

  • How to unpatch a directory/file in Linux

    - by softy
    How can I achieve to get the unpatched file/directory form a patched one.I have applied a patch pd.patch on a directory and a patch pf.patch on a file like this : patch -p1 < pd (in the diretory) patch -p1 file_unpatch < pf.patch . ( will give me file_patch(patched file_unpatch)) How can i retrieve original file_unpatch and the unpatched directory. I have figured out we can unpatch a directoy using -R option , patch -p1 -R < pd (in the diretory) -- will give me unpatched directory. What about file? RGds, Softy

    Read the article

  • Multiple Git repositories in one directory

    - by Jakob
    Hello, I would like to deploy a directory to multiple developers having different permissions. So this is one thing Git cannot do. What about creating two repositories in one directory and assigning them different file lists by excluding files managed by the other repository with the .gitignore file. Example: /www/project/.git for all files execpt in /www/project/css /www/project/css/.git - only files in this directory Has anyone tried this solution? Or are there any better ways to handle this issue? Regards, Jakob

    Read the article

  • ASP.NET MVC using App_Code directory

    - by Ben
    I've added an App_Code directory to my ASP.NET MVC project so that I get dynamic compilation for plugins. Only slight annoyance is that when developing new plugins, I don't get intellisense on classes inside the App_Code directory. Currently I am creating them in another directory inside my project and then copying them into App_Code. is there any way around this?

    Read the article

  • Space in Directory Parameter of svcutil.exe

    - by Drew Frisk
    I'm attempting to download metadata for a WCF service using svcutil but I'm running into issues with the /directory:< parameter. The directory I want to save to has a space in it: C:\Service References\Logging so when I execute /t:metadata I receive the following error: Error: The directory 'C:\Program Files (x86)\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\References\Logging' could not be found. Verify that the directory exists and that you have the appropriate permissions to read it. It looks to me like the space in "Service References" is causing the issue. From my understanding of command shell (which is very little) spaces act as delimiters for an executable. So I tried escaping the space with a carrot Service^ References and surrounding the path in double quotes "C:\Service References\Logging" but neither of those seem to be working, as the /directory: parameter doesn't recognize them as valid characters in the value. I haven't been able to find any direction in regards to this and svcutil, so I'm at a loss right now. I could download the files to a temp folder and then move them, but I would prefer not to take that approach. I would appreciate any direction that could be given on trying to resolve this. Thanks in advance.

    Read the article

  • Source Directory MSVC

    - by PhilCK
    argh, this should be an easy one. How can I set the directory that a MSVC project uses to store source files? I wish to use a directory outside the project dir, As this is a multiplatform project which will also have an xcode directory. Thanks Phil

    Read the article

  • Mvc relative path using virtual directory..help!

    - by kevin
    When i drag and drop my image/script/css file into my view, relative path will automatically use to refer on the files. example: <link href="../../Content/style.css" rel="stylesheet" type="text/css" /> <script src="../../Scripts/jquery-min.js" type="text/javascript"></script> <img src="../../Images/logo.jpg" /> It is working fine when i host it on my root directory, but if i'm using virtual directory then only my css file able to refer correctly, the rest will return 404...as it will refer to http://{root}/Images/logo.jpg rather than http://{root}/{virtual directory}/Images/logo.jpg But why css file is working? and how to specify the relative path correctly for both root & virtual directory cases?

    Read the article

  • untar filename.tr.gz to directory "filename"

    - by Jorre
    I would like to untar an archive e.g. "tar123.tar.gz" to directory /myunzip/tar123/" using a shell command. tar -xf tar123.tar.gz will decompress the files but in the same directory as where I'm working in. If the filename would be "tar233.tar.gz" I want it to be decompressed to /myunzip/tar233.tar.gz" so destination directory would be based on the filename. Does anyone know if the tar command can do this?

    Read the article

  • pylint ignore by directory

    - by Ciantic
    Following is from pylint docs: --ignore=<file> Add <file or directory> to the black list. It should be a base name, not a path. You may set this option multiple times. [current: %default] Yet I'm not having luck getting the directory part work. I have directory called migrations, which has django-south migration files. As I enter --ignore=migrations it still keeps giving me the errors/warnings in files inside migrations directory. Could it be that --ignore is not working for directories? If I could even use regexp to match the ignored files it would work, since django-south files are all named 0001_something, 0002_something...

    Read the article

  • My HttpHandler doesn't want to create directory on a network

    - by Daok
    I use this simple line of code inside my HttpHandler: Directory.CreateDirectory(@"\\srv-001\dev\folderToCreate\"); I receive an UnauthoridezAccessException telling me that the access to the path is denied. From here, I create a little Dos application in C# doing the same thing and I was able to create the folder. So, I thought that it might be that IIS is running on a different user than myself. I went to IIS and changed the Application pool to a Custom user, myself. But, unfortunately, I got the same exception. I have try to create a Share folder on my computer and I can create directory. Also, when debugging I can see that System.Threading.Thread.CurrentPrincipal.Identity have its AuthenticationType to "", IsAuthenticated to false and name to "". So, with all those tests I can conclude that the HttpHandler that receive the file cannot create a directory because of some security access. How can I grand access to my HttpHandler to be able to create a directory (and files) to a network folder?

    Read the article

  • PHP Image Upload object won't create directory on windows

    - by ThinkingInBits
    I'm writing a class that excepts a product_id and a $_FILES array as it's constructor. The class saves these variables and uses them to create a new directory named by product_id and attempts to copy the temp file to my specified directory. For some reason my class isn't even getting as far as creating a directory (which should happen in the constructor) Here's a link to my code: http://pastie.org/955454

    Read the article

  • Textmate bundle to remove a directory and build with Jekyll

    - by m1755
    I am looking for a simple Textmate bundle that will do the following two tasks in order: Delete the entire contents (including folders) of a directory (eg. ~/Sites/my_site). Run the jekyll command in the directory of the Textmate project. I am going to associate this with a "save current file" and use it to auto build my Jekyll site into the specified directory each time I save a file inside the project. Notes If #2 isn't possible, then cd into a specified directory and run the jekyll command. Would prefer bash or ruby.

    Read the article

  • SVN Serve, Missing a Directory

    - by Ryan Smith
    I'm sure this is an asinine question, and I blame myself for not fully understanding how the SVNSERVE process works. I have an SVN repo, but it needs to be moved to a server within a clients cloud. I did this a while back and ran into the issue of the SVNSERVE.exe process not getting set to the right directory. I have the SVNSERVE.exe process running as a windows service and pointing to the right directory. There are two other repos there that are serving out fine in the same directory. I copied out the new directory just like I did with the others, but I'm getting the error "No repository found". I thought that SVNSERVE just looked at that directory and served out the repositories that were there, but I have had a hard time finding more information about that. I thought it was a Windows permission problem, but I set the whole folder to be full control to EVERYONE, so that's not it. I feel horrible I didn't fully understand this problem the first time I fought it, but it's late on a Sunday night and clients are yelling. Anyone know what I'm missing? Thanks. EDIT: It's specific to the repository. I tested the same process with some of the other repos we have on our server and when I copied them up, they worked just as expected. This bug is breaking me and I wish I could provide more details, but that's all I know. I'm going to try to do an SVN Dump instead of an XCopy and see how that goes. I'll let you know.

    Read the article

  • Python Script to backup a directory

    - by rgolwalkar
    Filename:backup_ver1 import os import time 1 Using list to specify the files and directory to be backed up source = r'C:\Documents and Settings\rgolwalkar\Desktop\Desktop\Dr Py\Final_Py' 2 define backup directory destination = r'C:\Documents and Settings\rgolwalkar\Desktop\Desktop\PyDevResourse' 3 Setting the backup name targetBackup = destination + time.strftime('%Y%m%d%H%M%S') + '.rar' rar_command = "rar.exe a -ag '%s' %s" % (targetBackup, ''.join(source)) i am sure i am doing something wrong here - rar command please let me know if os.system(rar_command) == 0: print 'Successful backup to', targetBackup else: print 'Backup FAILED' O/P:- Backup FAILED winrar is added to Path and CLASSPATH under Environment variables as well - anyone else with a suggestion for backing up the directory is most welcome

    Read the article

  • firefox open local link to directory with explorer

    - by raffael
    On a Website for our internal use i show links to local files and folders. the links are like this: href="file://C:/example/" href="file://C:/example/test.odt" The Problem is now that the link to the directory does open in firefox itself with a useless directory listing. Useless because you can just see the files or open them but not copy, insert, delete... The link to the file work normal and the file is opend by OpenOffice. By changing the configuration of firefox and setting the following key to false I can open the directory in with explorer.exe but for the file I have to choose the right application. network.protocol-handler.expose.file Does someone know a way to get both to work like i want? Means that the Directory is shown by explorer.exe and all files are opened by the right application. This can be by configuring Firefox or windows, changing the links, or even by writing a small program which opens all the file protocol correctly and will be used as protocol handler for the file protocol in firefox. Thanks Raffael

    Read the article

  • If change in a directory then do some action in linux

    - by user194469
    Hi All, I want to store the file and file information into the database automatically, when any file is inserted into the directory. Let suppose, in the /etc directory, we store some log files. And if we are inserted new file into /etc directory or change any existing file then automatically these file information should be go to specific database table. How can i do that. Regards, Amit

    Read the article

  • Conditional action based on whether any file in a directory has a ctime newer than X

    - by jberryman
    I would like to run a backup job on a directory tree from a bash script if any of the files have been modified in the last 30 minutes. I think I can hack together something using find with the -ctime flag, but I'm sure there is a standard way to examine a directory for changes. I know that I can inspect the ctime of the top level directory to see if files were added, but I need to be able to see changes also. FWIW, I am using duplicity to backup directories to S3.

    Read the article

  • How does Read-Only affect a Directory?

    - by ispiro
    I've found that I can write (say, copy a file into) a Read-Only directory. That is, a Directory with ...Attributes = FileAttributes.ReadOnly.I can even change its name. The only thing I've found that can't be done is to delete it. Is that really the only thing that ReadOnly prevents? EDIT: Here's the code: (The Directory is empty.) (new DirectoryInfo(path)).Attributes = FileAttributes.ReadOnly; Directory.Delete(path); It throws an Access to the path 'c:\... is denied. exception. But after changing ReadOnly to Normal it works fine. So what does a ReadOnly prevent, and what doesn't it prevent?

    Read the article

< Previous Page | 55 56 57 58 59 60 61 62 63 64 65 66  | Next Page >