Module bobsh/iptables
| Download |
|
Module description
Module for handling iptables.
Release notes for version 1.2.0
- Added Puppet 2.6.x support
- Fix reloads of empty fields
- Add ability to specify hostname for source and destination
Types
iptables
Description
Manipulate iptables rules
Parameters
- name
The name of the resource
- chain
holds value of iptables -A parameter. Possible values are: ‘INPUT’, ‘FORWARD’, ‘OUTPUT’, ‘PREROUTING’, ‘POSTROUTING’. Default value is ‘INPUT’ Valid values are
INPUT,FORWARD,OUTPUT,PREROUTING,POSTROUTING.
- table
one of the following tables: ‘nat’, ‘mangle’, ‘filter’ and ‘raw’. Default one is ‘filter’ Valid values are
nat,mangle,filter,raw.
- proto
holds value of iptables –protocol parameter. Possible values are: ‘tcp’, ‘udp’, ‘icmp’, ‘esp’, ‘ah’, ‘vrrp’, ‘igmp’, ‘all’. Default value is ‘tcp’ Valid values are
tcp,udp,icmp,esp,ah,vrrp,igmp,all.
- jump
holds value of iptables –jump target Possible values are: ‘ACCEPT’, ‘DROP’, ‘REJECT’, ‘DNAT’, ‘SNAT’, ‘LOG’, ‘MASQUERADE’, ‘REDIRECT’. Default value is ‘ACCEPT’. While this is not the accepted norm, this is the more commonly used jump target. Users should ensure they do an explicit DROP for all packets after all the ACCEPT rules are specified. Valid values are
ACCEPT,DROP,REJECT,DNAT,SNAT,LOG,MASQUERADE,REDIRECT.
- source
value for iptables –source parameter. Accepts a single string or array.
- destination
value for iptables –destination parameter
- sport
holds value of iptables [..] –source-port parameter. If array is specified, values will be passed to multiport module. Only applies to tcp/udp.
- dport
holds value of iptables [..] –destination-port parameter. If array is specified, values will be passed to multiport module. Only applies to tcp/udp.
- iniface
value for iptables –in-interface parameter
- outiface
value for iptables –out-interface parameter
- tosource
value for iptables ‘-j SNAT –to-source’ parameter
- todest
value for iptables ‘-j DNAT –to-destination’ parameter
- toports
value for iptables ‘-j REDIRECT –to-ports’ parameter
- reject
value for iptables ‘-j REJECT –reject-with’ parameter
- log_level
value for iptables ‘-j LOG –log-level’ parameter
- log_prefix
value for iptables ‘-j LOG –log-prefix’ parameter
- icmp
value for iptables ‘-p icmp –icmp-type’ parameter
- state
value for iptables ‘-m state –state’ parameter. Possible values are: ‘INVALID’, ‘ESTABLISHED’, ‘NEW’, ‘RELATED’. Also accepts an array of multiple values.
- limit
value for iptables ‘-m limit –limit’ parameter. Example values are: ‘50/sec’, ‘40/min’, ‘30/hour’, ‘10/day’.
- burst
value for ‘–limit-burst’ parameter. Example values are: ‘5’, ‘10’.
- redirect
value for iptables ‘-j REDIRECT –to-ports’ parameter.