473,320 Members | 1,951 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

chance of php file gets deleted

Hi members,

My question is:

Is there a way through which anyone can delete a php file from server. like some hacker delete registeration.php file from server (live server) ???

If so. then how?? and how can I avoid this?
I do have knowledge about sql injection n xss attacks. but no really sure that a FILE can be deleted?

waiting for your responses

Regards
Nov 27 '09 #1
2 1559
Basically i want to know.. is there any flaw in the code can lead to deletion of a file???
Nov 27 '09 #2
Markus
6,050 Expert 4TB
If you're working with user-supplied data, be it through a form, file upload, etc., there's always a chance that data could be malicious. However, you, being the security-conscious developer can overcome these malicious attacks by assuming one thing: all user-supplied data is malicious! Never trust people who use your site.

The only 2 ways I can think of a user being able to delete files from your system would be through calls to system() (and the related functions) and eval().

Using the aforementioned mantra of: trust none, filter all, you should be pretty safe.

Mark.
Nov 27 '09 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

14
by: ajikoe | last post by:
Hello, If I use os.remove(fileName), does it always assure that the code will move to the next code only if the fileName is deleted completely? Pujo
2
by: Lei Jiang | last post by:
I created a WinForms app (MyApp.exe), and created a config file(MyApp.exe.config) in it's output directory. However, whenever the build finished, the config file is deleted automatically!!!...
0
by: robert naujokas | last post by:
I'm using VB.NET 2003. I'm working on a simple windows application project type. I've added an application config file to the bin directory in my project. When I build, rebuild or run the project...
3
by: Prakash | last post by:
Below is my code to delete a record in a continuous form. I can't figure out any reason but sometimes (another) record gets deleted instead of where the record pointer is positioned. Small table...
6
by: Kiran | last post by:
Hi, I have program, which opens file at the startup and logs error messages to the file, file handle is closed at the end of the program. However if file is deleted in-between, program do not...
1
by: bob | last post by:
I'm using visual studio and working on some webforms. the last few forms that I have created have been very long and after I save the form - parts of the html get deleted and I lose the objects...
1
by: crka.crka | last post by:
Does anyone know a way to prevent a file being deleted so the only way to delete is via unistallation? Help would be very much appreciated.
0
by: John Dalberg | last post by:
When I add an xsd file to a project, VS2005 created a few files including the designer.cs file. So far so good. However when I change a data type for a column, the whole designer.cs disappers. Is...
0
by: deneb | last post by:
Hello all? When I restart the page or just logout the page, cookie file is deleted automatically. What's wrong with me?? here is my code. ' If I success in Login process, Save user ID in...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.