Hack Forums
Shell Uploaded - Can't back connect? - 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: Website Hacking (https://hackforums.net/forumdisplay.php?fid=43)
+----- Forum: SQL Injection Attacks (https://hackforums.net/forumdisplay.php?fid=103)
+----- Thread: Shell Uploaded - Can't back connect? (/showthread.php?tid=3438291)

Pages: Pages 1 2


Shell Uploaded - Can't back connect? - SIM-1241186 - Apr 26, 2013

So after some quick SQLi, I've got my shell uploaded. I'd like to begin rooting the server, but I can't get netcat to establish a connection with my shell.

I successfully listen on my port:
[Image: cfbf74ee5872d1daa3bccce2b1e6e497.png?1367003999]

however when I connect through my shell nothing happens. It's worked in the past, can't seem to figure out what's wrong now.

Any ideas?
Thanks. 🤝


* - Processor - Apr 26, 2013

May I ask what shell you are using?


* - vmkbot - Apr 26, 2013

did you port forward the port 1604, you need to have the port open before it can be addressed.


* - SIM-1241186 - Apr 26, 2013

(Apr 26, 2013 12:34 PM)vmkbot Wrote:  did you port forward the port 1604?

Of course. I've had it forwarded for quite a while, and I just re-checked It's still forwarded.
[Image: 874d9321b22312275c9fe272a65ab28d.png?1367005041]


(Apr 26, 2013 12:31 PM)Processor Wrote:  May I ask what shell you are using?

I'm using Dhanush. But I've tried uploading other shells and connecting with those, still getting the same result.

I've also tried re-downloading netcat.


* - vmkbot - Apr 26, 2013

presuming that it's forwarded for the correct address, have you checked your firewall?


* - SIM-1241186 - Apr 26, 2013

(Apr 26, 2013 12:39 PM)vmkbot Wrote:  presuming that it's forwarded for the correct address, have you checked your firewall?

It is. And yes, I've checked my firewall. I've even tried disabling it and trying again. Still the same result. 😵


* - vmkbot - Apr 26, 2013

have you tried other ports? my guess is that the server's security may be blocking outgoing connections


* - SIM-1241186 - Apr 26, 2013

(Apr 26, 2013 12:44 PM)vmkbot Wrote:  have you tried other ports? my guess is that the server's security may be blocking outgoing connections

Yes I've tried other ports. And that shouldn't be the case, because I've successfully connected to it in the past. This problem has occurred with every other site I have shelled as well.


* - Pendragon - Apr 26, 2013

What language is the backconnect coded in? Have you checked to see if it's installed on the sever? Also try using ports < 1000.


* - SIM-1241186 - Apr 26, 2013

(Apr 26, 2013 12:52 PM)Pendragon Wrote:  What language is the backconnect coded in? Have you checked to see if it's installed on the sever? Also try using ports < 1000.

There's options for Perl, Python, and PHP. I've tried all of them. Yes, I've checked to see if it's installed on the server, and they are.
PHP Code

<?php 
Where is Perl
?: perl: /usr/bin/perl.1355319536 /usr/bin/perl /usr/local/bin/perl /usr/share/man/man1/perl.1.gz
Where is Python
?: python: /usr/bin/python2.6-config /usr/bin/python2.6 /usr/bin/python /usr/lib/python2.6 /usr/lib64/python2.6 /usr/include/python2.6 /usr/share/man/man1/python.1.gz 

What difference would a port lower than 1000 make..?


* - Cathal - Apr 26, 2013

(Apr 26, 2013 12:56 PM)hackforumspang Wrote:  There's options for Perl, Python, and PHP. I've tried all of them. Yes, I've checked to see if it's installed on the server, and they are.
PHP Code

<?php 
Where is Perl
?: perl: /usr/bin/perl.1355319536 /usr/bin/perl /usr/local/bin/perl /usr/share/man/man1/perl.1.gz
Where is Python
?: python: /usr/bin/python2.6-config /usr/bin/python2.6 /usr/bin/python /usr/lib/python2.6 /usr/lib64/python2.6 /usr/include/python2.6 /usr/share/man/man1/python.1.gz 

What difference would a port lower than 1000 make..?

It wouldn't. Is safe mode enabled? List all disabled functions please.


* - SIM-1241186 - Apr 26, 2013

(Apr 26, 2013 12:58 PM)MrCathal09 Wrote:  It wouldn't. Is safe mode enabled? List all disabled functions please.

PHP Code

<?php 
Disable functions 
: None     Safe Mode : OFF 



* - Pendragon - Apr 26, 2013

(Apr 26, 2013 12:58 PM)MrCathal09 Wrote:  It wouldn't. Is safe mode enabled? List all disabled functions please.

Says who? Many boxes disable ports > 1000 because they are not privileged ports. This is why you need to be root when binding a port < 1000.

[Image: 9AIuh2K.png]

I have no problem with people correcting me, just make sure you're actually correcting me.


* - Cathal - Apr 26, 2013

(Apr 26, 2013 01:18 PM)Pendragon Wrote:  Says who? Many boxes disable ports > 1000 because they are not privileged ports. This is why you need to be root when binding a port < 1000.

[Image: 9AIuh2K.png]

I have no problem with people correcting me, just make sure you're actually correcting me.

Fair enough, here's your correction. Fix the inequality. And sorry, I genuinely didn't know that. Still learnin.


* - Pendragon - Apr 26, 2013

(Apr 26, 2013 01:24 PM)MrCathal09 Wrote:  Fair enough, here's your correction. Fix the inequality. And sorry, I genuinely didn't know that. Still learnin.

The "inequalities" I used are exactly what I meant to say. And if you didn't know that what I said to begin with was true, then why did you automatically deny it instead of perhaps Googling it first to do some "learnin"?