To test my php script ( add your link ), I put it one a website, and some of you remember that when I began learning php, I was sharing with you here my experience, and some e-friends here tried many times to hack the script, to test it in the goal to make it better.
Anyway, I left the script online to let friends and visitors add their links, BUT, from 2 weeks, I discovered that someone hacked my script, and than Google blocks the access to visit the website, anyway, I moved the website now to another server, but I don’t know how the hacker can do that?? so I’m asking you to try to hack my script, to test it and to let me know if I should do something to protect it better… the link is :
If you want to check the script for XSS vulnerability this is a good place to start: http://ha.ckers.org/xss.html
In addition, do you connect to the FTP over SSH/SSL or do you use a normal connection to port 21? If, you might want to change that as in that case all traffic/information is transferred in clear text, so anyone in between you and the server can listen in and capture the information.
To me it seems they hacked the FTP server and altered you code. I don’t really see how they could have your script to alter itself. Especially when the script isn’t writable by the web process (which it shouldn’t be).