home

Supported platforms

Vyatta NOS documentation

Learn how to install, configure, and operate Vyatta Network Operating System (Vyatta NOS), which helps to drive our virtual networking and physical platforms portfolio.

Source address translations

SNAT rules substitute the translation address for the source address of a packet. Port translation is also available and can be specified as part of the translation address.

Note that the translation address must be set either to one of the addresses defined on the outbound interface or to masquerade, indicating that the primary IP address of the outbound interface is to be used as the translation address.

Substituting a source IP address

The following example shows how to apply a SNAT rule, rule 10, that substitutes the address of 12.34.56.78 as the source IP address of outbound packets that match its filter criteria.

vyatta@vyatta# set service nat source rule 10 translation address 12.34.56.78

Substituting a range of source IP addresses

The following example shows how to apply a SNAT rule, rule 20, that substitutes the addresses 12.34.56.64 through 12.34.56.79 as the range of source IP addresses for outbound packets that match its filter criteria.

vyatta@vyatta# set service nat source rule 20 translation address 12.34.56.64-12.34.56.79

Substituting the primary address of an outbound interface

The following example shows how to apply a SNAT rule, rule 30, that substitutes the primary address of the outbound interface as the source IP address of outbound packets that match its filter criteria.

vyatta@vyatta# set service nat source rule 30 translation address masquerade