This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This script will make a local SNMP server accessible on a remote system by | |
# forwarding its UDP traffic over an SSH connection. | |
# To do this, the following port forwardings are applied (in this order): | |
# - local TCP port 42061 (arbitrary) to local UDP port 161 (SNMP) | |
# - remote TCP port 42061 to local TCP port 42061 (via SSH connection) | |
# - remote UDP port 42061 to remote TCP port 42061 |