Re: OpenSSH_4.7p1, reverse shell

This is a discussion on Re: OpenSSH_4.7p1, reverse shell within the OpenSSH Development forums, part of the Networking and Network Related category; Hayder Mouhammed wrote: > What I am trying: > > On C: ssh -N -R 10000:localhost:22 root@machineB &...


Go Back   Usenet Forums > Networking and Network Related > OpenSSH Development

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-01-2008
Bob Proulx
 
Posts: n/a
Default Re: OpenSSH_4.7p1, reverse shell

Hayder Mouhammed wrote:
> What I am trying:
>
> On C: ssh -N -R 10000:localhost:22 root@machineB
> On B: running sshd
> On A: ssh root@machineB -p 10000


A useful tool to double check where ports are open for listening is
'netstat'. Try this to see all listening connections:

netstat -na | grep LISTEN

netstat -na | grep :10000

Try that on all of the involved systems and verify where you are
listening. That can clear up a lot of confusion.

The next thing to look for when trying to connect remotely is what IP
address the listening port is bound. This is controlled by
GatewayPorts=yes and I see that you set it in your sshd configuration.
Did you restart the daemon after changes to make sure they could take
effect?
127.0.0.1 only accepts connections from the loopback interface.
0.0.0.0 accepts connections from any network interface. Any specific
IP address would be assocated with that specific network device.

After this I would simply 'connect'[*], or 'telnet' if that isn't
available, to the port and verify that you are getting an ssh banner.

On C:
connect localhost 22

On B:
connect localhost 10000

On A:
connect B 10000

If the port is open and available but still blocked then I would look
for a firewall that is blocking the connection.

Bob
[*] http://www.meadowy.org/~gotoh/projects/connect
_______________________________________________
openssh-unix-dev mailing list
openssh-unix-dev@mindrot.org
https://lists.mindrot.org/mailman/li...enssh-unix-dev
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 09:04 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0