Checking strange activity on account
Hello
I have a user which i believe has been hacked and sends spam, well i have CSF and it let me know which file was doing this, got rid of it (yesterday) but today more php files showed up on the same folder, so i assume this is not over. Even i got some gif files with strange code like this:
Now i want to know where can i look to see the origin of this, tried ftp logs and nothing, /var/log/messages nothing regarding the location (or even mentioning the user account). What i do know that this user has an old joomla install i know for a fact that is probably the reason of this, what i need to know is a server-side solution to stop the creation of those files. Maybe changing permission of folders? Any ideas? Thanks.
GIF89aGbkht
Now i want to know where can i look to see the origin of this, tried ftp logs and nothing, /var/log/messages nothing regarding the location (or even mentioning the user account). What i do know that this user has an old joomla install i know for a fact that is probably the reason of this, what i need to know is a server-side solution to stop the creation of those files. Maybe changing permission of folders? Any ideas? Thanks.
-
You shold check that account's access logs: /home/CPANELUSERNAME/access_logs 0 -
[quote="quietFinn, post: 1482182">You shold check that account's access logs: /home/CPANELUSERNAME/access_logs
Hi Im afraid that directory is empty maybe i have something disabled that prevents the log from appearing??0 -
Check /usr/local/apache/domlogs However, they need to update / patch their software. No amount of server-side security can make up for users running hackable applications. Do not allow people to run vulnerable appliations on your server. A good modsecurity ruleset can stop a lot of hacks but it is not foolproof. If the file in quesiton is in public_html/images/stories/ or public_html/tmp/ they probably have a hackable com_jce component. Check the date on files inside of public_html/components/com_jce/. If they are more than a year or two old that is the easiest way for an attacker to upload that code to a joomla site. 0 -
Hello :) Also, check to see if any of the directories within this account are using insecure permissions (e.g. 0777). It's possible the scripts are uploaded through a Joomla plugin that allows uploads of this nature. Thank you. 0 -
There is another cool way they use to do this, once they compromise an account, they upload a file, execute it and delete it, while leaving the process alive and kicking in memory! Thus, there is no file for you to find, its just not there because it deletes itself. Once this process is started, the file will open a TCP port and listen for remote commands, execute code, upload files in tmp directories, send information about the server to a remote listener, so on and so forth. So check the running processes, I've seen them use process names like "mysql" and similar ones. I found their trick quite effective and imaginative! :) 0
Please sign in to leave a comment.
Comments
5 comments