Mastering Port 179: A Comprehensive HackTricks Guide to BGP Pentesting
To discover if a target router is running BGP, use nmap to verify if port 179 is open or filtered: nmap -p 179 -sV -sC Use code with caution. Banner Grabbing and Passive Intelligence
Allow traffic on port 179 only from known, trusted peer IP addresses.
In security audits, red team engagements, and penetration testing workflows—such as those popularized by the HackTricks Wiki —understanding port 179 is crucial for assessing network resiliency, catching misconfigurations, and preventing malicious traffic interception. hacktricks 179
: To stay up-to-date or get help, you can join the project's Discord or Telegram group. You can also follow the official Twitter account, @hacktricks_live .
This comprehensive guide details the network enumeration, vulnerability assessment, exploitation vectors (such as BGP Hijacking and Session Resets), and remediation strategies associated with TCP Port 179. 1. Banner Grabbing & Active Enumeration
An attacker can attempt to spoof the IP address of a legitimate BGP peer and establish a session, injecting fraudulent routing updates. 2. BGP Route Poisoning Mastering Port 179: A Comprehensive HackTricks Guide to
: For offline access or if you want to contribute, you can clone the GitHub repository and build it yourself.
When we think of penetration testing, we often focus on web apps or internal active directories. But what about the protocol that holds the entire internet together? is the home of the Border Gateway Protocol (BGP) , the "postal service" of the internet that manages how packets are routed between autonomous systems.
: The router acts as a client, actively initiating a TCP handshake out to a designated neighbor's port 179. : To stay up-to-date or get help, you
BGP is the "postal service" of the internet, responsible for routing data across different autonomous systems (AS). Because it handles core internet infrastructure, it is a high-value target for sophisticated network attacks. PentestPad Common BGP Attacks BGP Hijacking (Prefix Hijacking):
Port 179 is rarely used for typical application-level exploitation, but it is a "golden ticket" for network-level disruption. By utilizing techniques focused on BGP auditing (often described within the HackTricks methodology), professionals can identify improperly secured routers and prevent critical BGP hijacking events.
: The router acts as a server, listening continuously on TCP port 179 for inbound synchronization requests.