Mastering SSH Port Forwarding: Local, Remote, and Dynamic SOCKS Proxies

SSH is far more than an encrypted remote terminal—it is an extensible transport protocol capable of encapsulating arbitrary TCP traffic across segmented network boundaries, NAT gateways, and restrictive firewalls. Here is how to leverage Dynamic, Local, and Remote Reverse SSH tunnels. 1. Dynamic Port Forwarding (-D): SOCKS Proxy Dynamic port forwarding turns your SSH client into a local SOCKS5 proxy server. Any application configured to use this proxy routes its network requests through the remote SSH host. ...

August 12, 2015 · 2 min · 306 words · Ahmad Mahfouz

Network Pivoting and Port Forwarding with Metasploit and Meterpreter

During penetration tests and red team operations, an initial compromised foothold often resides in a perimeter network (DMZ) or employee subnet. These dual-homed hosts can act as springboards (pivots) to reach isolated internal segments unreachable from your attack workstation. The Network Scenario Attacker Workstation: 10.0.0.5 Compromised Host (Dual-Homed Foothold): External NIC: 10.0.0.10 Internal Private Subnet NIC: 10.0.2.15 Internal Target Host (Isolated): 10.0.2.30 Step 1: Internal Subnet Discovery (arp_scanner) From your active Meterpreter session on the compromised host, discover live hosts on the internal 10.0.2.0/24 subnet using ARP requests: ...

January 8, 2015 · 2 min · 278 words · Ahmad Mahfouz