root / REFERENCE.md @ 2b1896c1
Historique | Voir | Annoter | Télécharger (41,5 ko)
1 | e17693e3 | Steve Traylen | # Reference |
---|---|---|---|
2 | |||
3 | <!-- DO NOT EDIT: This document was generated by Puppet Strings --> |
||
4 | |||
5 | ## Table of Contents |
||
6 | |||
7 | ### Classes |
||
8 | |||
9 | * [`nftables`](#nftables): Configure nftables |
||
10 | 7f6cacc5 | Steve Traylen | * [`nftables::bridges`](#nftablesbridges): allow forwarding traffic on bridges |
11 | e17693e3 | Steve Traylen | * [`nftables::inet_filter`](#nftablesinet_filter): manage basic chains in table inet filter |
12 | * [`nftables::ip_nat`](#nftablesip_nat): manage basic chains in table ip nat |
||
13 | 771b3256 | Nacho Barrientos | * [`nftables::rules::activemq`](#nftablesrulesactivemq): Provides input rules for Apache ActiveMQ |
14 | 7f6cacc5 | Steve Traylen | * [`nftables::rules::afs3_callback`](#nftablesrulesafs3_callback): Open call back port for AFS clients |
15 | b9785000 | Steve Traylen | * [`nftables::rules::ceph`](#nftablesrulesceph): Ceph is a distributed object store and file system. Enable this to support Ceph's Object Storage Daemons (OSD), Metadata Server Daemons (MDS) |
16 | 09cba182 | Steve Traylen | * [`nftables::rules::ceph_mon`](#nftablesrulesceph_mon): Ceph is a distributed object store and file system. |
17 | Enable this option to support Ceph's Monitor Daemon. |
||
18 | * [`nftables::rules::dhcpv6_client`](#nftablesrulesdhcpv6_client): allow DHCPv6 requests in to a host |
||
19 | 7f6cacc5 | Steve Traylen | * [`nftables::rules::dns`](#nftablesrulesdns): manage in dns |
20 | 804b96e4 | Nacho Barrientos | * [`nftables::rules::docker_ce`](#nftablesrulesdocker_ce): Default firewall configuration for Docker-CE |
21 | e17693e3 | Steve Traylen | * [`nftables::rules::http`](#nftablesruleshttp): manage in http |
22 | * [`nftables::rules::https`](#nftablesruleshttps): manage in https |
||
23 | * [`nftables::rules::icinga2`](#nftablesrulesicinga2): manage in icinga2 |
||
24 | 7f6cacc5 | Steve Traylen | * [`nftables::rules::icmp`](#nftablesrulesicmp) |
25 | b9785000 | Steve Traylen | * [`nftables::rules::nfs`](#nftablesrulesnfs): manage in nfs4 |
26 | * [`nftables::rules::nfs3`](#nftablesrulesnfs3): manage in nfs3 |
||
27 | 7f6cacc5 | Steve Traylen | * [`nftables::rules::node_exporter`](#nftablesrulesnode_exporter): manage in node exporter |
28 | e17693e3 | Steve Traylen | * [`nftables::rules::ospf`](#nftablesrulesospf): manage in ospf |
29 | * [`nftables::rules::ospf3`](#nftablesrulesospf3): manage in ospf3 |
||
30 | * [`nftables::rules::out::all`](#nftablesrulesoutall): allow all outbound |
||
31 | 09cba182 | Steve Traylen | * [`nftables::rules::out::ceph_client`](#nftablesrulesoutceph_client): Ceph is a distributed object store and file system. |
32 | Enable this to be a client of Ceph's Monitor (MON), |
||
33 | Object Storage Daemons (OSD), Metadata Server Daemons (MDS), |
||
34 | and Manager Daemons (MGR). |
||
35 | e17693e3 | Steve Traylen | * [`nftables::rules::out::chrony`](#nftablesrulesoutchrony): manage out chrony |
36 | * [`nftables::rules::out::dhcp`](#nftablesrulesoutdhcp): manage out dhcp |
||
37 | 09cba182 | Steve Traylen | * [`nftables::rules::out::dhcpv6_client`](#nftablesrulesoutdhcpv6_client): Allow DHCPv6 requests out of a host |
38 | e17693e3 | Steve Traylen | * [`nftables::rules::out::dns`](#nftablesrulesoutdns): manage out dns |
39 | * [`nftables::rules::out::http`](#nftablesrulesouthttp): manage out http |
||
40 | * [`nftables::rules::out::https`](#nftablesrulesouthttps): manage out https |
||
41 | 09cba182 | Steve Traylen | * [`nftables::rules::out::icmp`](#nftablesrulesouticmp): control outbound icmp packages |
42 | 19908f41 | mh | * [`nftables::rules::out::imap`](#nftablesrulesoutimap): allow outgoing imap |
43 | 7f6cacc5 | Steve Traylen | * [`nftables::rules::out::kerberos`](#nftablesrulesoutkerberos): allows outbound access for kerberos |
44 | e17693e3 | Steve Traylen | * [`nftables::rules::out::mysql`](#nftablesrulesoutmysql): manage out mysql |
45 | b9785000 | Steve Traylen | * [`nftables::rules::out::nfs`](#nftablesrulesoutnfs): manage out nfs |
46 | * [`nftables::rules::out::nfs3`](#nftablesrulesoutnfs3): manage out nfs3 |
||
47 | 7f6cacc5 | Steve Traylen | * [`nftables::rules::out::openafs_client`](#nftablesrulesoutopenafs_client): allows outbound access for afs clients |
48 | 09cba182 | Steve Traylen | 7000 - afs3-fileserver |
49 | 7002 - afs3-ptserver |
||
50 | 7003 - vlserver |
||
51 | e17693e3 | Steve Traylen | * [`nftables::rules::out::ospf`](#nftablesrulesoutospf): manage out ospf |
52 | * [`nftables::rules::out::ospf3`](#nftablesrulesoutospf3): manage out ospf3 |
||
53 | 19908f41 | mh | * [`nftables::rules::out::pop3`](#nftablesrulesoutpop3): allow outgoing pop3 |
54 | e17693e3 | Steve Traylen | * [`nftables::rules::out::postgres`](#nftablesrulesoutpostgres): manage out postgres |
55 | * [`nftables::rules::out::puppet`](#nftablesrulesoutpuppet): manage outgoing puppet |
||
56 | 194e05d5 | Tim Meusel | * [`nftables::rules::out::pxp_agent`](#nftablesrulesoutpxp_agent): manage outgoing pxp-agent |
57 | 19908f41 | mh | * [`nftables::rules::out::smtp`](#nftablesrulesoutsmtp): allow outgoing smtp |
58 | * [`nftables::rules::out::smtp_client`](#nftablesrulesoutsmtp_client): allow outgoing smtp client |
||
59 | e17693e3 | Steve Traylen | * [`nftables::rules::out::ssh`](#nftablesrulesoutssh): manage out ssh |
60 | * [`nftables::rules::out::ssh::remove`](#nftablesrulesoutsshremove): disable outgoing ssh |
||
61 | * [`nftables::rules::out::tor`](#nftablesrulesouttor): manage out tor |
||
62 | 2b1896c1 | Tim Meusel | * [`nftables::rules::out::whois`](#nftablesrulesoutwhois): allow clients to query remote whois server |
63 | e17693e3 | Steve Traylen | * [`nftables::rules::out::wireguard`](#nftablesrulesoutwireguard): manage out wireguard |
64 | * [`nftables::rules::puppet`](#nftablesrulespuppet): manage in puppet |
||
65 | 7f74df2e | Tim Meusel | * [`nftables::rules::pxp_agent`](#nftablesrulespxp_agent): manage in pxp-agent |
66 | cd2a3cbf | Nacho Barrientos | * [`nftables::rules::qemu`](#nftablesrulesqemu): Bridged network configuration for qemu/libvirt |
67 | 19908f41 | mh | * [`nftables::rules::samba`](#nftablesrulessamba): manage Samba, the suite to allow Windows file sharing on Linux resources. |
68 | e17693e3 | Steve Traylen | * [`nftables::rules::smtp`](#nftablesrulessmtp): manage in smtp |
69 | * [`nftables::rules::smtp_submission`](#nftablesrulessmtp_submission): manage in smtp submission |
||
70 | * [`nftables::rules::smtps`](#nftablesrulessmtps): manage in smtps |
||
71 | * [`nftables::rules::ssh`](#nftablesrulesssh): manage in ssh |
||
72 | * [`nftables::rules::tor`](#nftablesrulestor): manage in tor |
||
73 | * [`nftables::rules::wireguard`](#nftablesruleswireguard): manage in wireguard |
||
74 | 09cba182 | Steve Traylen | * [`nftables::services::dhcpv6_client`](#nftablesservicesdhcpv6_client): Allow in and outbound traffic for DHCPv6 server |
75 | * [`nftables::services::openafs_client`](#nftablesservicesopenafs_client): Open inbound and outbound ports for an AFS client |
||
76 | e17693e3 | Steve Traylen | |
77 | ### Defined types |
||
78 | |||
79 | * [`nftables::chain`](#nftableschain): manage a chain |
||
80 | * [`nftables::config`](#nftablesconfig): manage a config snippet |
||
81 | 13f26dfc | Nacho Barrientos | * [`nftables::rule`](#nftablesrule): Provides an interface to create a firewall rule |
82 | e17693e3 | Steve Traylen | * [`nftables::rules::dnat4`](#nftablesrulesdnat4): manage a ipv4 dnat rule |
83 | * [`nftables::rules::masquerade`](#nftablesrulesmasquerade): masquerade all outgoing traffic |
||
84 | * [`nftables::rules::snat4`](#nftablesrulessnat4): manage a ipv4 snat rule |
||
85 | 7f6cacc5 | Steve Traylen | * [`nftables::set`](#nftablesset): manage a named set |
86 | b46c9ce9 | Nacho Barrientos | * [`nftables::simplerule`](#nftablessimplerule): Provides a simplified interface to nftables::rule |
87 | 4d63adda | Nacho Barrientos | |
88 | ### Data types |
||
89 | |||
90 | * [`Nftables::Addr`](#nftablesaddr): Represents an address expression to be used within a rule. |
||
91 | * [`Nftables::Addr::Set`](#nftablesaddrset): Represents a set expression to be used within a rule. |
||
92 | * [`Nftables::Port`](#nftablesport): Represents a port expression to be used within a rule. |
||
93 | * [`Nftables::Port::Range`](#nftablesportrange): Represents a port range expression to be used within a rule. |
||
94 | 8c00b818 | Nacho Barrientos | * [`Nftables::RuleName`](#nftablesrulename): Represents a rule name to be used in a raw rule created via nftables::rule. |
95 | It's a dash separated string. The first component describes the chain to |
||
96 | add the rule to, the second the rule name and the (optional) third a number. |
||
97 | Ex: 'default_in-sshd', 'default_out-my_service-2'. |
||
98 | * [`Nftables::SimpleRuleName`](#nftablessimplerulename): Represents a simple rule name to be used in a rule created via nftables::simplerule |
||
99 | e17693e3 | Steve Traylen | |
100 | ## Classes |
||
101 | |||
102 | 09cba182 | Steve Traylen | ### <a name="nftables"></a>`nftables` |
103 | e17693e3 | Steve Traylen | |
104 | Configure nftables |
||
105 | |||
106 | #### Examples |
||
107 | |||
108 | b9785000 | Steve Traylen | ##### allow dns out and do not allow ntp out |
109 | e17693e3 | Steve Traylen | |
110 | ```puppet |
||
111 | 2063deaf | hashworks | class{ 'nftables': |
112 | out_ntp => false, |
||
113 | out_dns => true, |
||
114 | e17693e3 | Steve Traylen | } |
115 | ``` |
||
116 | |||
117 | b9785000 | Steve Traylen | ##### do not flush particular tables, fail2ban in this case |
118 | |||
119 | ```puppet |
||
120 | 2063deaf | hashworks | class{ 'nftables': |
121 | noflush_tables => ['inet-f2b-table'], |
||
122 | b9785000 | Steve Traylen | } |
123 | ``` |
||
124 | |||
125 | e17693e3 | Steve Traylen | #### Parameters |
126 | |||
127 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables` class: |
128 | |||
129 | * [`out_all`](#out_all) |
||
130 | * [`out_ntp`](#out_ntp) |
||
131 | * [`out_http`](#out_http) |
||
132 | * [`out_dns`](#out_dns) |
||
133 | * [`out_https`](#out_https) |
||
134 | * [`out_icmp`](#out_icmp) |
||
135 | * [`in_ssh`](#in_ssh) |
||
136 | * [`in_icmp`](#in_icmp) |
||
137 | 7b9d6ffc | Nacho Barrientos | * [`inet_filter`](#inet_filter) |
138 | 09cba182 | Steve Traylen | * [`nat`](#nat) |
139 | b02d6ea9 | Nacho Barrientos | * [`nat_table_name`](#nat_table_name) |
140 | 09cba182 | Steve Traylen | * [`sets`](#sets) |
141 | * [`log_prefix`](#log_prefix) |
||
142 | * [`log_limit`](#log_limit) |
||
143 | * [`reject_with`](#reject_with) |
||
144 | * [`in_out_conntrack`](#in_out_conntrack) |
||
145 | * [`fwd_conntrack`](#fwd_conntrack) |
||
146 | * [`firewalld_enable`](#firewalld_enable) |
||
147 | * [`noflush_tables`](#noflush_tables) |
||
148 | * [`rules`](#rules) |
||
149 | d0a1ffef | hashworks | * [`configuration_path`](#configuration_path) |
150 | 8842a597 | Tim Meusel | * [`nft_path`](#nft_path) |
151 | 821ec83a | Tim Meusel | * [`echo`](#echo) |
152 | 09cba182 | Steve Traylen | |
153 | ##### <a name="out_all"></a>`out_all` |
||
154 | e17693e3 | Steve Traylen | |
155 | Data type: `Boolean` |
||
156 | |||
157 | Allow all outbound connections. If `true` then all other |
||
158 | out parameters `out_ntp`, `out_dns`, ... will be assuemed |
||
159 | false. |
||
160 | |||
161 | Default value: ``false`` |
||
162 | |||
163 | 09cba182 | Steve Traylen | ##### <a name="out_ntp"></a>`out_ntp` |
164 | e17693e3 | Steve Traylen | |
165 | Data type: `Boolean` |
||
166 | |||
167 | Allow outbound to ntp servers. |
||
168 | |||
169 | Default value: ``true`` |
||
170 | |||
171 | 09cba182 | Steve Traylen | ##### <a name="out_http"></a>`out_http` |
172 | e17693e3 | Steve Traylen | |
173 | Data type: `Boolean` |
||
174 | |||
175 | Allow outbound to http servers. |
||
176 | |||
177 | Default value: ``true`` |
||
178 | |||
179 | 09cba182 | Steve Traylen | ##### <a name="out_dns"></a>`out_dns` |
180 | e17693e3 | Steve Traylen | |
181 | Data type: `Boolean` |
||
182 | |||
183 | 09cba182 | Steve Traylen | Allow outbound to dns servers. |
184 | e17693e3 | Steve Traylen | |
185 | Default value: ``true`` |
||
186 | |||
187 | 09cba182 | Steve Traylen | ##### <a name="out_https"></a>`out_https` |
188 | |||
189 | Data type: `Boolean` |
||
190 | e17693e3 | Steve Traylen | |
191 | Allow outbound to https servers. |
||
192 | |||
193 | Default value: ``true`` |
||
194 | |||
195 | 09cba182 | Steve Traylen | ##### <a name="out_icmp"></a>`out_icmp` |
196 | 7f6cacc5 | Steve Traylen | |
197 | Data type: `Boolean` |
||
198 | |||
199 | Allow outbound ICMPv4/v6 traffic. |
||
200 | |||
201 | Default value: ``true`` |
||
202 | |||
203 | 09cba182 | Steve Traylen | ##### <a name="in_ssh"></a>`in_ssh` |
204 | e17693e3 | Steve Traylen | |
205 | Data type: `Boolean` |
||
206 | |||
207 | Allow inbound to ssh servers. |
||
208 | |||
209 | Default value: ``true`` |
||
210 | |||
211 | 09cba182 | Steve Traylen | ##### <a name="in_icmp"></a>`in_icmp` |
212 | 7f6cacc5 | Steve Traylen | |
213 | Data type: `Boolean` |
||
214 | |||
215 | Allow inbound ICMPv4/v6 traffic. |
||
216 | |||
217 | Default value: ``true`` |
||
218 | |||
219 | 7b9d6ffc | Nacho Barrientos | ##### <a name="inet_filter"></a>`inet_filter` |
220 | |||
221 | Data type: `Boolean` |
||
222 | |||
223 | Add default tables, chains and rules to process traffic. |
||
224 | |||
225 | Default value: ``true`` |
||
226 | |||
227 | 09cba182 | Steve Traylen | ##### <a name="nat"></a>`nat` |
228 | 7f6cacc5 | Steve Traylen | |
229 | Data type: `Boolean` |
||
230 | |||
231 | Add default tables and chains to process NAT traffic. |
||
232 | |||
233 | Default value: ``true`` |
||
234 | |||
235 | b02d6ea9 | Nacho Barrientos | ##### <a name="nat_table_name"></a>`nat_table_name` |
236 | |||
237 | Data type: `String[1]` |
||
238 | |||
239 | The name of the 'nat' table. |
||
240 | |||
241 | Default value: `'nat'` |
||
242 | |||
243 | 09cba182 | Steve Traylen | ##### <a name="sets"></a>`sets` |
244 | b9785000 | Steve Traylen | |
245 | Data type: `Hash` |
||
246 | |||
247 | Allows sourcing set definitions directly from Hiera. |
||
248 | |||
249 | Default value: `{}` |
||
250 | |||
251 | 09cba182 | Steve Traylen | ##### <a name="log_prefix"></a>`log_prefix` |
252 | 7f6cacc5 | Steve Traylen | |
253 | Data type: `String` |
||
254 | |||
255 | String that will be used as prefix when logging packets. It can contain |
||
256 | two variables using standard sprintf() string-formatting: |
||
257 | * chain: Will be replaced by the name of the chain. |
||
258 | * comment: Allows chains to add extra comments. |
||
259 | |||
260 | Default value: `'[nftables] %<chain>s %<comment>s'` |
||
261 | |||
262 | 09cba182 | Steve Traylen | ##### <a name="log_limit"></a>`log_limit` |
263 | b9785000 | Steve Traylen | |
264 | Data type: `Variant[Boolean[false], String]` |
||
265 | |||
266 | String with the content of a limit statement to be applied |
||
267 | to the rules that log discarded traffic. Set to false to |
||
268 | disable rate limiting. |
||
269 | |||
270 | Default value: `'3/minute burst 5 packets'` |
||
271 | |||
272 | 09cba182 | Steve Traylen | ##### <a name="reject_with"></a>`reject_with` |
273 | 7f6cacc5 | Steve Traylen | |
274 | b9785000 | Steve Traylen | Data type: `Variant[Boolean[false], Pattern[/icmp(v6|x)? type .+|tcp reset/]]` |
275 | 7f6cacc5 | Steve Traylen | |
276 | How to discard packets not matching any rule. If `false`, the |
||
277 | fate of the packet will be defined by the chain policy (normally |
||
278 | drop), otherwise the packet will be rejected with the REJECT_WITH |
||
279 | policy indicated by the value of this parameter. |
||
280 | |||
281 | Default value: `'icmpx type port-unreachable'` |
||
282 | |||
283 | 09cba182 | Steve Traylen | ##### <a name="in_out_conntrack"></a>`in_out_conntrack` |
284 | 7f6cacc5 | Steve Traylen | |
285 | Data type: `Boolean` |
||
286 | |||
287 | Adds INPUT and OUTPUT rules to allow traffic that's part of an |
||
288 | established connection and also to drop invalid packets. |
||
289 | |||
290 | Default value: ``true`` |
||
291 | |||
292 | 09cba182 | Steve Traylen | ##### <a name="fwd_conntrack"></a>`fwd_conntrack` |
293 | b9785000 | Steve Traylen | |
294 | Data type: `Boolean` |
||
295 | |||
296 | Adds FORWARD rules to allow traffic that's part of an |
||
297 | established connection and also to drop invalid packets. |
||
298 | |||
299 | Default value: ``false`` |
||
300 | |||
301 | 09cba182 | Steve Traylen | ##### <a name="firewalld_enable"></a>`firewalld_enable` |
302 | 7f6cacc5 | Steve Traylen | |
303 | Data type: `Variant[Boolean[false], Enum['mask']]` |
||
304 | |||
305 | Configures how the firewalld systemd service unit is enabled. It might be |
||
306 | useful to set this to false if you're externaly removing firewalld from |
||
307 | the system completely. |
||
308 | |||
309 | Default value: `'mask'` |
||
310 | |||
311 | 09cba182 | Steve Traylen | ##### <a name="noflush_tables"></a>`noflush_tables` |
312 | b9785000 | Steve Traylen | |
313 | Data type: `Optional[Array[Pattern[/^(ip|ip6|inet)-[-a-zA-Z0-9_]+$/],1]]` |
||
314 | |||
315 | If specified only other existings tables will be flushed. |
||
316 | If left unset all tables will be flushed via a `flush ruleset` |
||
317 | |||
318 | Default value: ``undef`` |
||
319 | |||
320 | 09cba182 | Steve Traylen | ##### <a name="rules"></a>`rules` |
321 | 7f6cacc5 | Steve Traylen | |
322 | Data type: `Hash` |
||
323 | |||
324 | 09cba182 | Steve Traylen | Specify hashes of `nftables::rule`s via hiera |
325 | 7f6cacc5 | Steve Traylen | |
326 | Default value: `{}` |
||
327 | |||
328 | d0a1ffef | hashworks | ##### <a name="configuration_path"></a>`configuration_path` |
329 | |||
330 | Data type: `Stdlib::Unixpath` |
||
331 | |||
332 | The absolute path to the principal nftables configuration file. The default |
||
333 | varies depending on the system, and is set in the module's data. |
||
334 | |||
335 | 8842a597 | Tim Meusel | ##### <a name="nft_path"></a>`nft_path` |
336 | |||
337 | Data type: `Stdlib::Unixpath` |
||
338 | |||
339 | Path to the nft binary |
||
340 | |||
341 | 821ec83a | Tim Meusel | ##### <a name="echo"></a>`echo` |
342 | |||
343 | Data type: `Stdlib::Unixpath` |
||
344 | |||
345 | Path to the echo binary |
||
346 | |||
347 | 09cba182 | Steve Traylen | ### <a name="nftablesbridges"></a>`nftables::bridges` |
348 | 7f6cacc5 | Steve Traylen | |
349 | allow forwarding traffic on bridges |
||
350 | |||
351 | #### Parameters |
||
352 | |||
353 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::bridges` class: |
354 | 7f6cacc5 | Steve Traylen | |
355 | 09cba182 | Steve Traylen | * [`ensure`](#ensure) |
356 | * [`bridgenames`](#bridgenames) |
||
357 | |||
358 | ##### <a name="ensure"></a>`ensure` |
||
359 | 7f6cacc5 | Steve Traylen | |
360 | Data type: `Enum['present','absent']` |
||
361 | |||
362 | |||
363 | |||
364 | Default value: `'present'` |
||
365 | |||
366 | 09cba182 | Steve Traylen | ##### <a name="bridgenames"></a>`bridgenames` |
367 | 7f6cacc5 | Steve Traylen | |
368 | Data type: `Regexp` |
||
369 | |||
370 | |||
371 | |||
372 | Default value: `/^br.+/` |
||
373 | |||
374 | 09cba182 | Steve Traylen | ### <a name="nftablesinet_filter"></a>`nftables::inet_filter` |
375 | e17693e3 | Steve Traylen | |
376 | manage basic chains in table inet filter |
||
377 | |||
378 | 09cba182 | Steve Traylen | ### <a name="nftablesip_nat"></a>`nftables::ip_nat` |
379 | e17693e3 | Steve Traylen | |
380 | manage basic chains in table ip nat |
||
381 | |||
382 | 771b3256 | Nacho Barrientos | ### <a name="nftablesrulesactivemq"></a>`nftables::rules::activemq` |
383 | |||
384 | Provides input rules for Apache ActiveMQ |
||
385 | |||
386 | #### Parameters |
||
387 | |||
388 | The following parameters are available in the `nftables::rules::activemq` class: |
||
389 | |||
390 | * [`tcp`](#tcp) |
||
391 | * [`udp`](#udp) |
||
392 | * [`port`](#port) |
||
393 | |||
394 | ##### <a name="tcp"></a>`tcp` |
||
395 | |||
396 | Data type: `Boolean` |
||
397 | |||
398 | Create the rule for TCP traffic. |
||
399 | |||
400 | Default value: ``true`` |
||
401 | |||
402 | ##### <a name="udp"></a>`udp` |
||
403 | |||
404 | Data type: `Boolean` |
||
405 | |||
406 | Create the rule for UDP traffic. |
||
407 | |||
408 | Default value: ``true`` |
||
409 | |||
410 | ##### <a name="port"></a>`port` |
||
411 | |||
412 | Data type: `Stdlib::Port` |
||
413 | |||
414 | The port number for the ActiveMQ daemon. |
||
415 | |||
416 | Default value: `61616` |
||
417 | |||
418 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesafs3_callback"></a>`nftables::rules::afs3_callback` |
419 | |||
420 | Open call back port for AFS clients |
||
421 | 7f6cacc5 | Steve Traylen | |
422 | 09cba182 | Steve Traylen | #### Examples |
423 | |||
424 | ##### allow call backs from particular hosts |
||
425 | |||
426 | ```puppet |
||
427 | 7f6cacc5 | Steve Traylen | class{'nftables::rules::afs3_callback': |
428 | saddr => ['192.168.0.0/16', '10.0.0.222'] |
||
429 | } |
||
430 | 09cba182 | Steve Traylen | ``` |
431 | 7f6cacc5 | Steve Traylen | |
432 | #### Parameters |
||
433 | |||
434 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::afs3_callback` class: |
435 | |||
436 | * [`saddr`](#saddr) |
||
437 | 7f6cacc5 | Steve Traylen | |
438 | 09cba182 | Steve Traylen | ##### <a name="saddr"></a>`saddr` |
439 | 7f6cacc5 | Steve Traylen | |
440 | Data type: `Array[Stdlib::IP::Address::V4,1]` |
||
441 | |||
442 | list of source network ranges to a |
||
443 | |||
444 | Default value: `['0.0.0.0/0']` |
||
445 | |||
446 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesceph"></a>`nftables::rules::ceph` |
447 | b9785000 | Steve Traylen | |
448 | Ceph is a distributed object store and file system. |
||
449 | Enable this to support Ceph's Object Storage Daemons (OSD), |
||
450 | Metadata Server Daemons (MDS), or Manager Daemons (MGR). |
||
451 | |||
452 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesceph_mon"></a>`nftables::rules::ceph_mon` |
453 | b9785000 | Steve Traylen | |
454 | Ceph is a distributed object store and file system. |
||
455 | Enable this option to support Ceph's Monitor Daemon. |
||
456 | |||
457 | #### Parameters |
||
458 | |||
459 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::ceph_mon` class: |
460 | b9785000 | Steve Traylen | |
461 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
462 | b9785000 | Steve Traylen | |
463 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
464 | b9785000 | Steve Traylen | |
465 | 09cba182 | Steve Traylen | Data type: `Array[Stdlib::Port,1]` |
466 | b9785000 | Steve Traylen | |
467 | 09cba182 | Steve Traylen | specify ports for ceph service |
468 | b9785000 | Steve Traylen | |
469 | Default value: `[3300, 6789]` |
||
470 | |||
471 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesdhcpv6_client"></a>`nftables::rules::dhcpv6_client` |
472 | 7f6cacc5 | Steve Traylen | |
473 | 09cba182 | Steve Traylen | allow DHCPv6 requests in to a host |
474 | 7f6cacc5 | Steve Traylen | |
475 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesdns"></a>`nftables::rules::dns` |
476 | 7f6cacc5 | Steve Traylen | |
477 | manage in dns |
||
478 | |||
479 | #### Parameters |
||
480 | |||
481 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::dns` class: |
482 | 7f6cacc5 | Steve Traylen | |
483 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
484 | 7f6cacc5 | Steve Traylen | |
485 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
486 | 7f6cacc5 | Steve Traylen | |
487 | 09cba182 | Steve Traylen | Data type: `Array[Stdlib::Port,1]` |
488 | 7f6cacc5 | Steve Traylen | |
489 | 09cba182 | Steve Traylen | Specify ports for dns. |
490 | 7f6cacc5 | Steve Traylen | |
491 | Default value: `[53]` |
||
492 | |||
493 | 804b96e4 | Nacho Barrientos | ### <a name="nftablesrulesdocker_ce"></a>`nftables::rules::docker_ce` |
494 | |||
495 | The configuration distributed in this class represents the default firewall |
||
496 | configuration done by docker-ce when the iptables integration is enabled. |
||
497 | |||
498 | This class is needed as the default docker-ce rules added to ip-filter conflict |
||
499 | with the inet-filter forward rules set by default in this module. |
||
500 | |||
501 | When using this class 'docker::iptables: false' should be set. |
||
502 | |||
503 | #### Parameters |
||
504 | |||
505 | The following parameters are available in the `nftables::rules::docker_ce` class: |
||
506 | |||
507 | * [`docker_interface`](#docker_interface) |
||
508 | * [`docker_prefix`](#docker_prefix) |
||
509 | * [`manage_docker_chains`](#manage_docker_chains) |
||
510 | * [`manage_base_chains`](#manage_base_chains) |
||
511 | |||
512 | ##### <a name="docker_interface"></a>`docker_interface` |
||
513 | |||
514 | Data type: `String[1]` |
||
515 | |||
516 | Interface name used by docker. |
||
517 | |||
518 | Default value: `'docker0'` |
||
519 | |||
520 | ##### <a name="docker_prefix"></a>`docker_prefix` |
||
521 | |||
522 | Data type: `Stdlib::IP::Address::V4::CIDR` |
||
523 | |||
524 | The address space used by docker. |
||
525 | |||
526 | Default value: `'172.17.0.0/16'` |
||
527 | |||
528 | ##### <a name="manage_docker_chains"></a>`manage_docker_chains` |
||
529 | |||
530 | Data type: `Boolean` |
||
531 | |||
532 | Flag to control whether the class should create the docker related chains. |
||
533 | |||
534 | Default value: ``true`` |
||
535 | |||
536 | ##### <a name="manage_base_chains"></a>`manage_base_chains` |
||
537 | |||
538 | Data type: `Boolean` |
||
539 | |||
540 | Flag to control whether the class should create the base common chains. |
||
541 | |||
542 | Default value: ``true`` |
||
543 | |||
544 | 09cba182 | Steve Traylen | ### <a name="nftablesruleshttp"></a>`nftables::rules::http` |
545 | e17693e3 | Steve Traylen | |
546 | manage in http |
||
547 | |||
548 | 09cba182 | Steve Traylen | ### <a name="nftablesruleshttps"></a>`nftables::rules::https` |
549 | e17693e3 | Steve Traylen | |
550 | manage in https |
||
551 | |||
552 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesicinga2"></a>`nftables::rules::icinga2` |
553 | e17693e3 | Steve Traylen | |
554 | manage in icinga2 |
||
555 | |||
556 | #### Parameters |
||
557 | |||
558 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::icinga2` class: |
559 | e17693e3 | Steve Traylen | |
560 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
561 | e17693e3 | Steve Traylen | |
562 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
563 | e17693e3 | Steve Traylen | |
564 | 09cba182 | Steve Traylen | Data type: `Array[Stdlib::Port,1]` |
565 | e17693e3 | Steve Traylen | |
566 | 09cba182 | Steve Traylen | Specify ports for icinga1 |
567 | e17693e3 | Steve Traylen | |
568 | Default value: `[5665]` |
||
569 | |||
570 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesicmp"></a>`nftables::rules::icmp` |
571 | 7f6cacc5 | Steve Traylen | |
572 | The nftables::rules::icmp class. |
||
573 | |||
574 | #### Parameters |
||
575 | |||
576 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::icmp` class: |
577 | |||
578 | * [`v4_types`](#v4_types) |
||
579 | * [`v6_types`](#v6_types) |
||
580 | * [`order`](#order) |
||
581 | 7f6cacc5 | Steve Traylen | |
582 | 09cba182 | Steve Traylen | ##### <a name="v4_types"></a>`v4_types` |
583 | 7f6cacc5 | Steve Traylen | |
584 | Data type: `Optional[Array[String]]` |
||
585 | |||
586 | |||
587 | |||
588 | Default value: ``undef`` |
||
589 | |||
590 | 09cba182 | Steve Traylen | ##### <a name="v6_types"></a>`v6_types` |
591 | 7f6cacc5 | Steve Traylen | |
592 | Data type: `Optional[Array[String]]` |
||
593 | |||
594 | |||
595 | |||
596 | Default value: ``undef`` |
||
597 | |||
598 | 09cba182 | Steve Traylen | ##### <a name="order"></a>`order` |
599 | 7f6cacc5 | Steve Traylen | |
600 | Data type: `String` |
||
601 | |||
602 | |||
603 | |||
604 | Default value: `'10'` |
||
605 | |||
606 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesnfs"></a>`nftables::rules::nfs` |
607 | b9785000 | Steve Traylen | |
608 | manage in nfs4 |
||
609 | |||
610 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesnfs3"></a>`nftables::rules::nfs3` |
611 | b9785000 | Steve Traylen | |
612 | manage in nfs3 |
||
613 | |||
614 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesnode_exporter"></a>`nftables::rules::node_exporter` |
615 | 7f6cacc5 | Steve Traylen | |
616 | manage in node exporter |
||
617 | |||
618 | #### Parameters |
||
619 | |||
620 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::node_exporter` class: |
621 | 7f6cacc5 | Steve Traylen | |
622 | 09cba182 | Steve Traylen | * [`prometheus_server`](#prometheus_server) |
623 | * [`port`](#port) |
||
624 | 7f6cacc5 | Steve Traylen | |
625 | 09cba182 | Steve Traylen | ##### <a name="prometheus_server"></a>`prometheus_server` |
626 | 7f6cacc5 | Steve Traylen | |
627 | 09cba182 | Steve Traylen | Data type: `Optional[Variant[String,Array[String,1]]]` |
628 | 7f6cacc5 | Steve Traylen | |
629 | 09cba182 | Steve Traylen | Specify server name |
630 | 7f6cacc5 | Steve Traylen | |
631 | Default value: ``undef`` |
||
632 | |||
633 | 09cba182 | Steve Traylen | ##### <a name="port"></a>`port` |
634 | 7f6cacc5 | Steve Traylen | |
635 | bc1b0f1a | Steve Traylen | Data type: `Stdlib::Port` |
636 | 7f6cacc5 | Steve Traylen | |
637 | 09cba182 | Steve Traylen | Specify port to open |
638 | 7f6cacc5 | Steve Traylen | |
639 | Default value: `9100` |
||
640 | |||
641 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesospf"></a>`nftables::rules::ospf` |
642 | e17693e3 | Steve Traylen | |
643 | manage in ospf |
||
644 | |||
645 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesospf3"></a>`nftables::rules::ospf3` |
646 | e17693e3 | Steve Traylen | |
647 | manage in ospf3 |
||
648 | |||
649 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutall"></a>`nftables::rules::out::all` |
650 | e17693e3 | Steve Traylen | |
651 | allow all outbound |
||
652 | |||
653 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutceph_client"></a>`nftables::rules::out::ceph_client` |
654 | b9785000 | Steve Traylen | |
655 | Ceph is a distributed object store and file system. |
||
656 | Enable this to be a client of Ceph's Monitor (MON), |
||
657 | Object Storage Daemons (OSD), Metadata Server Daemons (MDS), |
||
658 | and Manager Daemons (MGR). |
||
659 | |||
660 | #### Parameters |
||
661 | |||
662 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::out::ceph_client` class: |
663 | b9785000 | Steve Traylen | |
664 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
665 | b9785000 | Steve Traylen | |
666 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
667 | b9785000 | Steve Traylen | |
668 | 09cba182 | Steve Traylen | Data type: `Array[Stdlib::Port,1]` |
669 | b9785000 | Steve Traylen | |
670 | 09cba182 | Steve Traylen | Specify ports to open |
671 | b9785000 | Steve Traylen | |
672 | Default value: `[3300, 6789]` |
||
673 | |||
674 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutchrony"></a>`nftables::rules::out::chrony` |
675 | e17693e3 | Steve Traylen | |
676 | manage out chrony |
||
677 | |||
678 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutdhcp"></a>`nftables::rules::out::dhcp` |
679 | e17693e3 | Steve Traylen | |
680 | manage out dhcp |
||
681 | |||
682 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutdhcpv6_client"></a>`nftables::rules::out::dhcpv6_client` |
683 | 7f6cacc5 | Steve Traylen | |
684 | 09cba182 | Steve Traylen | Allow DHCPv6 requests out of a host |
685 | 7f6cacc5 | Steve Traylen | |
686 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutdns"></a>`nftables::rules::out::dns` |
687 | e17693e3 | Steve Traylen | |
688 | manage out dns |
||
689 | |||
690 | #### Parameters |
||
691 | |||
692 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::out::dns` class: |
693 | e17693e3 | Steve Traylen | |
694 | 09cba182 | Steve Traylen | * [`dns_server`](#dns_server) |
695 | e17693e3 | Steve Traylen | |
696 | 09cba182 | Steve Traylen | ##### <a name="dns_server"></a>`dns_server` |
697 | e17693e3 | Steve Traylen | |
698 | 09cba182 | Steve Traylen | Data type: `Optional[Variant[String,Array[String,1]]]` |
699 | e17693e3 | Steve Traylen | |
700 | 09cba182 | Steve Traylen | specify dns_server name |
701 | e17693e3 | Steve Traylen | |
702 | Default value: ``undef`` |
||
703 | |||
704 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesouthttp"></a>`nftables::rules::out::http` |
705 | e17693e3 | Steve Traylen | |
706 | manage out http |
||
707 | |||
708 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesouthttps"></a>`nftables::rules::out::https` |
709 | e17693e3 | Steve Traylen | |
710 | manage out https |
||
711 | |||
712 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesouticmp"></a>`nftables::rules::out::icmp` |
713 | 7f6cacc5 | Steve Traylen | |
714 | 09cba182 | Steve Traylen | control outbound icmp packages |
715 | 7f6cacc5 | Steve Traylen | |
716 | #### Parameters |
||
717 | |||
718 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::out::icmp` class: |
719 | |||
720 | * [`v4_types`](#v4_types) |
||
721 | * [`v6_types`](#v6_types) |
||
722 | * [`order`](#order) |
||
723 | 7f6cacc5 | Steve Traylen | |
724 | 09cba182 | Steve Traylen | ##### <a name="v4_types"></a>`v4_types` |
725 | 7f6cacc5 | Steve Traylen | |
726 | Data type: `Optional[Array[String]]` |
||
727 | |||
728 | |||
729 | |||
730 | Default value: ``undef`` |
||
731 | |||
732 | 09cba182 | Steve Traylen | ##### <a name="v6_types"></a>`v6_types` |
733 | 7f6cacc5 | Steve Traylen | |
734 | Data type: `Optional[Array[String]]` |
||
735 | |||
736 | |||
737 | |||
738 | Default value: ``undef`` |
||
739 | |||
740 | 09cba182 | Steve Traylen | ##### <a name="order"></a>`order` |
741 | 7f6cacc5 | Steve Traylen | |
742 | Data type: `String` |
||
743 | |||
744 | |||
745 | |||
746 | Default value: `'10'` |
||
747 | |||
748 | 19908f41 | mh | ### <a name="nftablesrulesoutimap"></a>`nftables::rules::out::imap` |
749 | |||
750 | allow outgoing imap |
||
751 | |||
752 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutkerberos"></a>`nftables::rules::out::kerberos` |
753 | 7f6cacc5 | Steve Traylen | |
754 | allows outbound access for kerberos |
||
755 | |||
756 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutmysql"></a>`nftables::rules::out::mysql` |
757 | e17693e3 | Steve Traylen | |
758 | manage out mysql |
||
759 | |||
760 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutnfs"></a>`nftables::rules::out::nfs` |
761 | b9785000 | Steve Traylen | |
762 | manage out nfs |
||
763 | |||
764 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutnfs3"></a>`nftables::rules::out::nfs3` |
765 | b9785000 | Steve Traylen | |
766 | manage out nfs3 |
||
767 | |||
768 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutopenafs_client"></a>`nftables::rules::out::openafs_client` |
769 | 7f6cacc5 | Steve Traylen | |
770 | 09cba182 | Steve Traylen | allows outbound access for afs clients |
771 | 7f6cacc5 | Steve Traylen | 7000 - afs3-fileserver |
772 | 7002 - afs3-ptserver |
||
773 | 7003 - vlserver |
||
774 | |||
775 | * **See also** |
||
776 | * https://wiki.openafs.org/devel/AFSServicePorts/ |
||
777 | * AFS Service Ports |
||
778 | |||
779 | #### Parameters |
||
780 | |||
781 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::out::openafs_client` class: |
782 | 7f6cacc5 | Steve Traylen | |
783 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
784 | 7f6cacc5 | Steve Traylen | |
785 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
786 | 7f6cacc5 | Steve Traylen | |
787 | 09cba182 | Steve Traylen | Data type: `Array[Stdlib::Port,1]` |
788 | 7f6cacc5 | Steve Traylen | |
789 | 09cba182 | Steve Traylen | port numbers to use |
790 | 7f6cacc5 | Steve Traylen | |
791 | Default value: `[7000, 7002, 7003]` |
||
792 | |||
793 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutospf"></a>`nftables::rules::out::ospf` |
794 | e17693e3 | Steve Traylen | |
795 | manage out ospf |
||
796 | |||
797 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutospf3"></a>`nftables::rules::out::ospf3` |
798 | e17693e3 | Steve Traylen | |
799 | manage out ospf3 |
||
800 | |||
801 | 19908f41 | mh | ### <a name="nftablesrulesoutpop3"></a>`nftables::rules::out::pop3` |
802 | |||
803 | allow outgoing pop3 |
||
804 | |||
805 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutpostgres"></a>`nftables::rules::out::postgres` |
806 | e17693e3 | Steve Traylen | |
807 | manage out postgres |
||
808 | |||
809 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutpuppet"></a>`nftables::rules::out::puppet` |
810 | e17693e3 | Steve Traylen | |
811 | manage outgoing puppet |
||
812 | |||
813 | #### Parameters |
||
814 | |||
815 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::out::puppet` class: |
816 | e17693e3 | Steve Traylen | |
817 | 09cba182 | Steve Traylen | * [`puppetserver`](#puppetserver) |
818 | * [`puppetserver_port`](#puppetserver_port) |
||
819 | e17693e3 | Steve Traylen | |
820 | 09cba182 | Steve Traylen | ##### <a name="puppetserver"></a>`puppetserver` |
821 | e17693e3 | Steve Traylen | |
822 | 09cba182 | Steve Traylen | Data type: `Variant[Stdlib::IP::Address,Array[Stdlib::IP::Address,1]]` |
823 | e17693e3 | Steve Traylen | |
824 | 09cba182 | Steve Traylen | puppetserver hostname |
825 | e17693e3 | Steve Traylen | |
826 | 09cba182 | Steve Traylen | ##### <a name="puppetserver_port"></a>`puppetserver_port` |
827 | e17693e3 | Steve Traylen | |
828 | bc1b0f1a | Steve Traylen | Data type: `Stdlib::Port` |
829 | e17693e3 | Steve Traylen | |
830 | 09cba182 | Steve Traylen | puppetserver port |
831 | e17693e3 | Steve Traylen | |
832 | Default value: `8140` |
||
833 | |||
834 | 194e05d5 | Tim Meusel | ### <a name="nftablesrulesoutpxp_agent"></a>`nftables::rules::out::pxp_agent` |
835 | |||
836 | manage outgoing pxp-agent |
||
837 | |||
838 | * **See also** |
||
839 | * also |
||
840 | * take a look at nftables::rules::out::puppet, because the PXP agent also connects to a Puppetserver |
||
841 | |||
842 | #### Parameters |
||
843 | |||
844 | The following parameters are available in the `nftables::rules::out::pxp_agent` class: |
||
845 | |||
846 | * [`broker`](#broker) |
||
847 | * [`broker_port`](#broker_port) |
||
848 | |||
849 | ##### <a name="broker"></a>`broker` |
||
850 | |||
851 | Data type: `Variant[Stdlib::IP::Address,Array[Stdlib::IP::Address,1]]` |
||
852 | |||
853 | PXP broker IP(s) |
||
854 | |||
855 | ##### <a name="broker_port"></a>`broker_port` |
||
856 | |||
857 | Data type: `Stdlib::Port` |
||
858 | |||
859 | PXP broker port |
||
860 | |||
861 | Default value: `8142` |
||
862 | |||
863 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutsmtp"></a>`nftables::rules::out::smtp` |
864 | e17693e3 | Steve Traylen | |
865 | 19908f41 | mh | allow outgoing smtp |
866 | |||
867 | ### <a name="nftablesrulesoutsmtp_client"></a>`nftables::rules::out::smtp_client` |
||
868 | |||
869 | allow outgoing smtp client |
||
870 | e17693e3 | Steve Traylen | |
871 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutssh"></a>`nftables::rules::out::ssh` |
872 | e17693e3 | Steve Traylen | |
873 | manage out ssh |
||
874 | |||
875 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutsshremove"></a>`nftables::rules::out::ssh::remove` |
876 | e17693e3 | Steve Traylen | |
877 | disable outgoing ssh |
||
878 | |||
879 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesouttor"></a>`nftables::rules::out::tor` |
880 | e17693e3 | Steve Traylen | |
881 | manage out tor |
||
882 | |||
883 | 2b1896c1 | Tim Meusel | ### <a name="nftablesrulesoutwhois"></a>`nftables::rules::out::whois` |
884 | |||
885 | allow clients to query remote whois server |
||
886 | |||
887 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesoutwireguard"></a>`nftables::rules::out::wireguard` |
888 | e17693e3 | Steve Traylen | |
889 | manage out wireguard |
||
890 | |||
891 | #### Parameters |
||
892 | |||
893 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::out::wireguard` class: |
894 | e17693e3 | Steve Traylen | |
895 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
896 | e17693e3 | Steve Traylen | |
897 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
898 | e17693e3 | Steve Traylen | |
899 | 09cba182 | Steve Traylen | Data type: `Array[Integer,1]` |
900 | e17693e3 | Steve Traylen | |
901 | 09cba182 | Steve Traylen | specify wireguard ports |
902 | e17693e3 | Steve Traylen | |
903 | Default value: `[51820]` |
||
904 | |||
905 | 09cba182 | Steve Traylen | ### <a name="nftablesrulespuppet"></a>`nftables::rules::puppet` |
906 | e17693e3 | Steve Traylen | |
907 | manage in puppet |
||
908 | |||
909 | #### Parameters |
||
910 | |||
911 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::puppet` class: |
912 | e17693e3 | Steve Traylen | |
913 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
914 | e17693e3 | Steve Traylen | |
915 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
916 | e17693e3 | Steve Traylen | |
917 | 09cba182 | Steve Traylen | Data type: `Array[Integer,1]` |
918 | e17693e3 | Steve Traylen | |
919 | 09cba182 | Steve Traylen | puppet server ports |
920 | e17693e3 | Steve Traylen | |
921 | Default value: `[8140]` |
||
922 | |||
923 | 7f74df2e | Tim Meusel | ### <a name="nftablesrulespxp_agent"></a>`nftables::rules::pxp_agent` |
924 | |||
925 | manage in pxp-agent |
||
926 | |||
927 | #### Parameters |
||
928 | |||
929 | The following parameters are available in the `nftables::rules::pxp_agent` class: |
||
930 | |||
931 | * [`ports`](#ports) |
||
932 | |||
933 | ##### <a name="ports"></a>`ports` |
||
934 | |||
935 | 2b1896c1 | Tim Meusel | Data type: `Array[Stdlib::Port,1]` |
936 | 7f74df2e | Tim Meusel | |
937 | pxp server ports |
||
938 | |||
939 | Default value: `[8142]` |
||
940 | |||
941 | cd2a3cbf | Nacho Barrientos | ### <a name="nftablesrulesqemu"></a>`nftables::rules::qemu` |
942 | |||
943 | This class configures the typical firewall setup that libvirt |
||
944 | creates. Depending on your requirements you can switch on and off |
||
945 | several aspects, for instance if you don't do DHCP to your guests |
||
946 | you can disable the rules that accept DHCP traffic on the host or if |
||
947 | you don't want your guests to talk to hosts outside you can disable |
||
948 | forwarding and/or masquerading for IPv4 traffic. |
||
949 | |||
950 | #### Parameters |
||
951 | |||
952 | The following parameters are available in the `nftables::rules::qemu` class: |
||
953 | |||
954 | * [`interface`](#interface) |
||
955 | * [`network_v4`](#network_v4) |
||
956 | * [`network_v6`](#network_v6) |
||
957 | * [`dns`](#dns) |
||
958 | * [`dhcpv4`](#dhcpv4) |
||
959 | * [`forward_traffic`](#forward_traffic) |
||
960 | * [`internal_traffic`](#internal_traffic) |
||
961 | * [`masquerade`](#masquerade) |
||
962 | |||
963 | ##### <a name="interface"></a>`interface` |
||
964 | |||
965 | Data type: `String[1]` |
||
966 | |||
967 | Interface name used by the bridge. |
||
968 | |||
969 | Default value: `'virbr0'` |
||
970 | |||
971 | ##### <a name="network_v4"></a>`network_v4` |
||
972 | |||
973 | Data type: `Stdlib::IP::Address::V4::CIDR` |
||
974 | |||
975 | The IPv4 network prefix used in the virtual network. |
||
976 | |||
977 | Default value: `'192.168.122.0/24'` |
||
978 | |||
979 | ##### <a name="network_v6"></a>`network_v6` |
||
980 | |||
981 | Data type: `Optional[Stdlib::IP::Address::V6::CIDR]` |
||
982 | |||
983 | The IPv6 network prefix used in the virtual network. |
||
984 | |||
985 | Default value: ``undef`` |
||
986 | |||
987 | ##### <a name="dns"></a>`dns` |
||
988 | |||
989 | Data type: `Boolean` |
||
990 | |||
991 | Allow DNS traffic from the guests to the host. |
||
992 | |||
993 | Default value: ``true`` |
||
994 | |||
995 | ##### <a name="dhcpv4"></a>`dhcpv4` |
||
996 | |||
997 | Data type: `Boolean` |
||
998 | |||
999 | Allow DHCPv4 traffic from the guests to the host. |
||
1000 | |||
1001 | Default value: ``true`` |
||
1002 | |||
1003 | ##### <a name="forward_traffic"></a>`forward_traffic` |
||
1004 | |||
1005 | Data type: `Boolean` |
||
1006 | |||
1007 | Allow forwarded traffic (out all, in related/established) |
||
1008 | generated by the virtual network. |
||
1009 | |||
1010 | Default value: ``true`` |
||
1011 | |||
1012 | ##### <a name="internal_traffic"></a>`internal_traffic` |
||
1013 | |||
1014 | Data type: `Boolean` |
||
1015 | |||
1016 | Allow guests in the virtual network to talk to each other. |
||
1017 | |||
1018 | Default value: ``true`` |
||
1019 | |||
1020 | ##### <a name="masquerade"></a>`masquerade` |
||
1021 | |||
1022 | Data type: `Boolean` |
||
1023 | |||
1024 | Do NAT masquerade on all IPv4 traffic generated by guests |
||
1025 | to external networks. |
||
1026 | |||
1027 | Default value: ``true`` |
||
1028 | |||
1029 | 19908f41 | mh | ### <a name="nftablesrulessamba"></a>`nftables::rules::samba` |
1030 | |||
1031 | manage Samba, the suite to allow Windows file sharing on Linux resources. |
||
1032 | |||
1033 | #### Parameters |
||
1034 | |||
1035 | The following parameters are available in the `nftables::rules::samba` class: |
||
1036 | |||
1037 | * [`ctdb`](#ctdb) |
||
1038 | |||
1039 | ##### <a name="ctdb"></a>`ctdb` |
||
1040 | |||
1041 | Data type: `Boolean` |
||
1042 | |||
1043 | Enable ctdb-driven clustered Samba setups. |
||
1044 | |||
1045 | Default value: ``false`` |
||
1046 | |||
1047 | 09cba182 | Steve Traylen | ### <a name="nftablesrulessmtp"></a>`nftables::rules::smtp` |
1048 | e17693e3 | Steve Traylen | |
1049 | manage in smtp |
||
1050 | |||
1051 | 09cba182 | Steve Traylen | ### <a name="nftablesrulessmtp_submission"></a>`nftables::rules::smtp_submission` |
1052 | e17693e3 | Steve Traylen | |
1053 | manage in smtp submission |
||
1054 | |||
1055 | 09cba182 | Steve Traylen | ### <a name="nftablesrulessmtps"></a>`nftables::rules::smtps` |
1056 | e17693e3 | Steve Traylen | |
1057 | manage in smtps |
||
1058 | |||
1059 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesssh"></a>`nftables::rules::ssh` |
1060 | e17693e3 | Steve Traylen | |
1061 | manage in ssh |
||
1062 | |||
1063 | #### Parameters |
||
1064 | |||
1065 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::ssh` class: |
1066 | e17693e3 | Steve Traylen | |
1067 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
1068 | e17693e3 | Steve Traylen | |
1069 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
1070 | e17693e3 | Steve Traylen | |
1071 | 09cba182 | Steve Traylen | Data type: `Array[Stdlib::Port,1]` |
1072 | e17693e3 | Steve Traylen | |
1073 | 09cba182 | Steve Traylen | ssh ports |
1074 | e17693e3 | Steve Traylen | |
1075 | Default value: `[22]` |
||
1076 | |||
1077 | 09cba182 | Steve Traylen | ### <a name="nftablesrulestor"></a>`nftables::rules::tor` |
1078 | e17693e3 | Steve Traylen | |
1079 | manage in tor |
||
1080 | |||
1081 | #### Parameters |
||
1082 | |||
1083 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::tor` class: |
1084 | e17693e3 | Steve Traylen | |
1085 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
1086 | e17693e3 | Steve Traylen | |
1087 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
1088 | e17693e3 | Steve Traylen | |
1089 | 09cba182 | Steve Traylen | Data type: `Array[Stdlib::Port,1]` |
1090 | e17693e3 | Steve Traylen | |
1091 | 09cba182 | Steve Traylen | ports for tor |
1092 | e17693e3 | Steve Traylen | |
1093 | Default value: `[9001]` |
||
1094 | |||
1095 | 09cba182 | Steve Traylen | ### <a name="nftablesruleswireguard"></a>`nftables::rules::wireguard` |
1096 | e17693e3 | Steve Traylen | |
1097 | manage in wireguard |
||
1098 | |||
1099 | #### Parameters |
||
1100 | |||
1101 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::wireguard` class: |
1102 | e17693e3 | Steve Traylen | |
1103 | 09cba182 | Steve Traylen | * [`ports`](#ports) |
1104 | e17693e3 | Steve Traylen | |
1105 | 09cba182 | Steve Traylen | ##### <a name="ports"></a>`ports` |
1106 | e17693e3 | Steve Traylen | |
1107 | 09cba182 | Steve Traylen | Data type: `Array[Stdlib::Port,1]` |
1108 | e17693e3 | Steve Traylen | |
1109 | 09cba182 | Steve Traylen | wiregueard port |
1110 | e17693e3 | Steve Traylen | |
1111 | Default value: `[51820]` |
||
1112 | |||
1113 | 09cba182 | Steve Traylen | ### <a name="nftablesservicesdhcpv6_client"></a>`nftables::services::dhcpv6_client` |
1114 | 7f6cacc5 | Steve Traylen | |
1115 | 09cba182 | Steve Traylen | Allow in and outbound traffic for DHCPv6 server |
1116 | 7f6cacc5 | Steve Traylen | |
1117 | 09cba182 | Steve Traylen | ### <a name="nftablesservicesopenafs_client"></a>`nftables::services::openafs_client` |
1118 | 7f6cacc5 | Steve Traylen | |
1119 | 09cba182 | Steve Traylen | Open inbound and outbound ports for an AFS client |
1120 | 7f6cacc5 | Steve Traylen | |
1121 | e17693e3 | Steve Traylen | ## Defined types |
1122 | |||
1123 | 09cba182 | Steve Traylen | ### <a name="nftableschain"></a>`nftables::chain` |
1124 | e17693e3 | Steve Traylen | |
1125 | manage a chain |
||
1126 | |||
1127 | #### Parameters |
||
1128 | |||
1129 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::chain` defined type: |
1130 | |||
1131 | * [`table`](#table) |
||
1132 | * [`chain`](#chain) |
||
1133 | * [`inject`](#inject) |
||
1134 | * [`inject_iif`](#inject_iif) |
||
1135 | * [`inject_oif`](#inject_oif) |
||
1136 | e17693e3 | Steve Traylen | |
1137 | 09cba182 | Steve Traylen | ##### <a name="table"></a>`table` |
1138 | e17693e3 | Steve Traylen | |
1139 | Data type: `Pattern[/^(ip|ip6|inet)-[a-zA-Z0-9_]+$/]` |
||
1140 | |||
1141 | |||
1142 | |||
1143 | Default value: `'inet-filter'` |
||
1144 | |||
1145 | 09cba182 | Steve Traylen | ##### <a name="chain"></a>`chain` |
1146 | e17693e3 | Steve Traylen | |
1147 | Data type: `Pattern[/^[a-zA-Z0-9_]+$/]` |
||
1148 | |||
1149 | |||
1150 | |||
1151 | Default value: `$title` |
||
1152 | |||
1153 | 09cba182 | Steve Traylen | ##### <a name="inject"></a>`inject` |
1154 | e17693e3 | Steve Traylen | |
1155 | Data type: `Optional[Pattern[/^\d\d-[a-zA-Z0-9_]+$/]]` |
||
1156 | |||
1157 | |||
1158 | |||
1159 | Default value: ``undef`` |
||
1160 | |||
1161 | 09cba182 | Steve Traylen | ##### <a name="inject_iif"></a>`inject_iif` |
1162 | e17693e3 | Steve Traylen | |
1163 | Data type: `Optional[String]` |
||
1164 | |||
1165 | |||
1166 | |||
1167 | Default value: ``undef`` |
||
1168 | |||
1169 | 09cba182 | Steve Traylen | ##### <a name="inject_oif"></a>`inject_oif` |
1170 | e17693e3 | Steve Traylen | |
1171 | Data type: `Optional[String]` |
||
1172 | |||
1173 | |||
1174 | |||
1175 | Default value: ``undef`` |
||
1176 | |||
1177 | 09cba182 | Steve Traylen | ### <a name="nftablesconfig"></a>`nftables::config` |
1178 | e17693e3 | Steve Traylen | |
1179 | manage a config snippet |
||
1180 | |||
1181 | #### Parameters |
||
1182 | |||
1183 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::config` defined type: |
1184 | e17693e3 | Steve Traylen | |
1185 | 09cba182 | Steve Traylen | * [`tablespec`](#tablespec) |
1186 | * [`content`](#content) |
||
1187 | * [`source`](#source) |
||
1188 | * [`prefix`](#prefix) |
||
1189 | |||
1190 | ##### <a name="tablespec"></a>`tablespec` |
||
1191 | 13f4e4c6 | Steve Traylen | |
1192 | Data type: `Pattern[/^\w+-\w+$/]` |
||
1193 | |||
1194 | |||
1195 | |||
1196 | Default value: `$title` |
||
1197 | |||
1198 | 09cba182 | Steve Traylen | ##### <a name="content"></a>`content` |
1199 | e17693e3 | Steve Traylen | |
1200 | Data type: `Optional[String]` |
||
1201 | |||
1202 | |||
1203 | |||
1204 | Default value: ``undef`` |
||
1205 | |||
1206 | 09cba182 | Steve Traylen | ##### <a name="source"></a>`source` |
1207 | e17693e3 | Steve Traylen | |
1208 | Data type: `Optional[Variant[String,Array[String,1]]]` |
||
1209 | |||
1210 | |||
1211 | |||
1212 | Default value: ``undef`` |
||
1213 | |||
1214 | 09cba182 | Steve Traylen | ##### <a name="prefix"></a>`prefix` |
1215 | 13f4e4c6 | Steve Traylen | |
1216 | Data type: `String` |
||
1217 | |||
1218 | |||
1219 | |||
1220 | Default value: `'custom-'` |
||
1221 | |||
1222 | 09cba182 | Steve Traylen | ### <a name="nftablesrule"></a>`nftables::rule` |
1223 | e17693e3 | Steve Traylen | |
1224 | 13f26dfc | Nacho Barrientos | Provides an interface to create a firewall rule |
1225 | |||
1226 | #### Examples |
||
1227 | |||
1228 | ##### add a rule named 'myhttp' to the 'default_in' chain to allow incoming traffic to TCP port 80 |
||
1229 | |||
1230 | ```puppet |
||
1231 | nftables::rule { |
||
1232 | 'default_in-myhttp': |
||
1233 | content => 'tcp dport 80 accept', |
||
1234 | } |
||
1235 | ``` |
||
1236 | |||
1237 | ##### add a rule named 'count' to the 'PREROUTING6' chain in table 'ip6 nat' to count traffic |
||
1238 | |||
1239 | ```puppet |
||
1240 | nftables::rule { |
||
1241 | 'PREROUTING6-count': |
||
1242 | content => 'counter', |
||
1243 | table => 'ip6-nat' |
||
1244 | } |
||
1245 | ``` |
||
1246 | e17693e3 | Steve Traylen | |
1247 | #### Parameters |
||
1248 | |||
1249 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rule` defined type: |
1250 | |||
1251 | * [`ensure`](#ensure) |
||
1252 | * [`rulename`](#rulename) |
||
1253 | * [`order`](#order) |
||
1254 | * [`table`](#table) |
||
1255 | * [`content`](#content) |
||
1256 | * [`source`](#source) |
||
1257 | e17693e3 | Steve Traylen | |
1258 | 09cba182 | Steve Traylen | ##### <a name="ensure"></a>`ensure` |
1259 | e17693e3 | Steve Traylen | |
1260 | Data type: `Enum['present','absent']` |
||
1261 | |||
1262 | 13f26dfc | Nacho Barrientos | Should the rule be created. |
1263 | e17693e3 | Steve Traylen | |
1264 | Default value: `'present'` |
||
1265 | |||
1266 | 09cba182 | Steve Traylen | ##### <a name="rulename"></a>`rulename` |
1267 | e17693e3 | Steve Traylen | |
1268 | 8c00b818 | Nacho Barrientos | Data type: `Nftables::RuleName` |
1269 | e17693e3 | Steve Traylen | |
1270 | 13f26dfc | Nacho Barrientos | The symbolic name for the rule and to what chain to add it. The |
1271 | format is defined by the Nftables::RuleName type. |
||
1272 | e17693e3 | Steve Traylen | |
1273 | Default value: `$title` |
||
1274 | |||
1275 | 09cba182 | Steve Traylen | ##### <a name="order"></a>`order` |
1276 | e17693e3 | Steve Traylen | |
1277 | Data type: `Pattern[/^\d\d$/]` |
||
1278 | |||
1279 | 13f26dfc | Nacho Barrientos | A number representing the order of the rule. |
1280 | e17693e3 | Steve Traylen | |
1281 | Default value: `'50'` |
||
1282 | |||
1283 | 09cba182 | Steve Traylen | ##### <a name="table"></a>`table` |
1284 | e17693e3 | Steve Traylen | |
1285 | b02d6ea9 | Nacho Barrientos | Data type: `String` |
1286 | e17693e3 | Steve Traylen | |
1287 | 13f26dfc | Nacho Barrientos | The name of the table to add this rule to. |
1288 | e17693e3 | Steve Traylen | |
1289 | Default value: `'inet-filter'` |
||
1290 | |||
1291 | 09cba182 | Steve Traylen | ##### <a name="content"></a>`content` |
1292 | e17693e3 | Steve Traylen | |
1293 | Data type: `Optional[String]` |
||
1294 | |||
1295 | 13f26dfc | Nacho Barrientos | The raw statements that compose the rule represented using the nftables |
1296 | language. |
||
1297 | e17693e3 | Steve Traylen | |
1298 | Default value: ``undef`` |
||
1299 | |||
1300 | 09cba182 | Steve Traylen | ##### <a name="source"></a>`source` |
1301 | e17693e3 | Steve Traylen | |
1302 | Data type: `Optional[Variant[String,Array[String,1]]]` |
||
1303 | |||
1304 | 13f26dfc | Nacho Barrientos | Same goal as content but sourcing the value from a file. |
1305 | e17693e3 | Steve Traylen | |
1306 | Default value: ``undef`` |
||
1307 | |||
1308 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesdnat4"></a>`nftables::rules::dnat4` |
1309 | e17693e3 | Steve Traylen | |
1310 | manage a ipv4 dnat rule |
||
1311 | |||
1312 | #### Parameters |
||
1313 | |||
1314 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::dnat4` defined type: |
1315 | |||
1316 | * [`daddr`](#daddr) |
||
1317 | * [`port`](#port) |
||
1318 | * [`rulename`](#rulename) |
||
1319 | * [`order`](#order) |
||
1320 | * [`chain`](#chain) |
||
1321 | * [`iif`](#iif) |
||
1322 | * [`proto`](#proto) |
||
1323 | * [`dport`](#dport) |
||
1324 | * [`ensure`](#ensure) |
||
1325 | e17693e3 | Steve Traylen | |
1326 | 09cba182 | Steve Traylen | ##### <a name="daddr"></a>`daddr` |
1327 | e17693e3 | Steve Traylen | |
1328 | Data type: `Pattern[/^[12]?\d{1,2}\.[12]?\d{1,2}\.[12]?\d{1,2}\.[12]?\d{1,2}$/]` |
||
1329 | |||
1330 | |||
1331 | |||
1332 | 09cba182 | Steve Traylen | ##### <a name="port"></a>`port` |
1333 | e17693e3 | Steve Traylen | |
1334 | bc1b0f1a | Steve Traylen | Data type: `Variant[String,Stdlib::Port]` |
1335 | e17693e3 | Steve Traylen | |
1336 | |||
1337 | |||
1338 | 09cba182 | Steve Traylen | ##### <a name="rulename"></a>`rulename` |
1339 | e17693e3 | Steve Traylen | |
1340 | Data type: `Pattern[/^[a-zA-Z0-9_]+$/]` |
||
1341 | |||
1342 | |||
1343 | |||
1344 | Default value: `$title` |
||
1345 | |||
1346 | 09cba182 | Steve Traylen | ##### <a name="order"></a>`order` |
1347 | e17693e3 | Steve Traylen | |
1348 | Data type: `Pattern[/^\d\d$/]` |
||
1349 | |||
1350 | |||
1351 | |||
1352 | Default value: `'50'` |
||
1353 | |||
1354 | 09cba182 | Steve Traylen | ##### <a name="chain"></a>`chain` |
1355 | e17693e3 | Steve Traylen | |
1356 | Data type: `String[1]` |
||
1357 | |||
1358 | |||
1359 | |||
1360 | Default value: `'default_fwd'` |
||
1361 | |||
1362 | 09cba182 | Steve Traylen | ##### <a name="iif"></a>`iif` |
1363 | e17693e3 | Steve Traylen | |
1364 | Data type: `Optional[String[1]]` |
||
1365 | |||
1366 | |||
1367 | |||
1368 | Default value: ``undef`` |
||
1369 | |||
1370 | 09cba182 | Steve Traylen | ##### <a name="proto"></a>`proto` |
1371 | e17693e3 | Steve Traylen | |
1372 | Data type: `Enum['tcp','udp']` |
||
1373 | |||
1374 | |||
1375 | |||
1376 | Default value: `'tcp'` |
||
1377 | |||
1378 | 09cba182 | Steve Traylen | ##### <a name="dport"></a>`dport` |
1379 | e17693e3 | Steve Traylen | |
1380 | bc1b0f1a | Steve Traylen | Data type: `Optional[Variant[String,Stdlib::Port]]` |
1381 | e17693e3 | Steve Traylen | |
1382 | |||
1383 | |||
1384 | b02d6ea9 | Nacho Barrientos | Default value: ``undef`` |
1385 | e17693e3 | Steve Traylen | |
1386 | 09cba182 | Steve Traylen | ##### <a name="ensure"></a>`ensure` |
1387 | e17693e3 | Steve Traylen | |
1388 | Data type: `Enum['present','absent']` |
||
1389 | |||
1390 | |||
1391 | |||
1392 | Default value: `'present'` |
||
1393 | |||
1394 | 09cba182 | Steve Traylen | ### <a name="nftablesrulesmasquerade"></a>`nftables::rules::masquerade` |
1395 | e17693e3 | Steve Traylen | |
1396 | masquerade all outgoing traffic |
||
1397 | |||
1398 | #### Parameters |
||
1399 | |||
1400 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::masquerade` defined type: |
1401 | e17693e3 | Steve Traylen | |
1402 | 09cba182 | Steve Traylen | * [`rulename`](#rulename) |
1403 | * [`order`](#order) |
||
1404 | * [`chain`](#chain) |
||
1405 | * [`oif`](#oif) |
||
1406 | * [`saddr`](#saddr) |
||
1407 | * [`daddr`](#daddr) |
||
1408 | * [`proto`](#proto) |
||
1409 | * [`dport`](#dport) |
||
1410 | * [`ensure`](#ensure) |
||
1411 | |||
1412 | ##### <a name="rulename"></a>`rulename` |
||
1413 | e17693e3 | Steve Traylen | |
1414 | Data type: `Pattern[/^[a-zA-Z0-9_]+$/]` |
||
1415 | |||
1416 | |||
1417 | |||
1418 | Default value: `$title` |
||
1419 | |||
1420 | 09cba182 | Steve Traylen | ##### <a name="order"></a>`order` |
1421 | e17693e3 | Steve Traylen | |
1422 | Data type: `Pattern[/^\d\d$/]` |
||
1423 | |||
1424 | |||
1425 | |||
1426 | Default value: `'70'` |
||
1427 | |||
1428 | 09cba182 | Steve Traylen | ##### <a name="chain"></a>`chain` |
1429 | e17693e3 | Steve Traylen | |
1430 | Data type: `String[1]` |
||
1431 | |||
1432 | |||
1433 | |||
1434 | Default value: `'POSTROUTING'` |
||
1435 | |||
1436 | 09cba182 | Steve Traylen | ##### <a name="oif"></a>`oif` |
1437 | e17693e3 | Steve Traylen | |
1438 | Data type: `Optional[String[1]]` |
||
1439 | |||
1440 | |||
1441 | |||
1442 | Default value: ``undef`` |
||
1443 | |||
1444 | 09cba182 | Steve Traylen | ##### <a name="saddr"></a>`saddr` |
1445 | e17693e3 | Steve Traylen | |
1446 | Data type: `Optional[String[1]]` |
||
1447 | |||
1448 | |||
1449 | |||
1450 | Default value: ``undef`` |
||
1451 | |||
1452 | 09cba182 | Steve Traylen | ##### <a name="daddr"></a>`daddr` |
1453 | e17693e3 | Steve Traylen | |
1454 | Data type: `Optional[String[1]]` |
||
1455 | |||
1456 | |||
1457 | |||
1458 | Default value: ``undef`` |
||
1459 | |||
1460 | 09cba182 | Steve Traylen | ##### <a name="proto"></a>`proto` |
1461 | e17693e3 | Steve Traylen | |
1462 | Data type: `Optional[Enum['tcp','udp']]` |
||
1463 | |||
1464 | |||
1465 | |||
1466 | Default value: ``undef`` |
||
1467 | |||
1468 | 09cba182 | Steve Traylen | ##### <a name="dport"></a>`dport` |
1469 | e17693e3 | Steve Traylen | |
1470 | bc1b0f1a | Steve Traylen | Data type: `Optional[Variant[String,Stdlib::Port]]` |
1471 | e17693e3 | Steve Traylen | |
1472 | |||
1473 | |||
1474 | Default value: ``undef`` |
||
1475 | |||
1476 | 09cba182 | Steve Traylen | ##### <a name="ensure"></a>`ensure` |
1477 | e17693e3 | Steve Traylen | |
1478 | Data type: `Enum['present','absent']` |
||
1479 | |||
1480 | |||
1481 | |||
1482 | Default value: `'present'` |
||
1483 | |||
1484 | 09cba182 | Steve Traylen | ### <a name="nftablesrulessnat4"></a>`nftables::rules::snat4` |
1485 | e17693e3 | Steve Traylen | |
1486 | manage a ipv4 snat rule |
||
1487 | |||
1488 | #### Parameters |
||
1489 | |||
1490 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::rules::snat4` defined type: |
1491 | |||
1492 | * [`snat`](#snat) |
||
1493 | * [`rulename`](#rulename) |
||
1494 | * [`order`](#order) |
||
1495 | * [`chain`](#chain) |
||
1496 | * [`oif`](#oif) |
||
1497 | * [`saddr`](#saddr) |
||
1498 | * [`proto`](#proto) |
||
1499 | * [`dport`](#dport) |
||
1500 | * [`ensure`](#ensure) |
||
1501 | e17693e3 | Steve Traylen | |
1502 | 09cba182 | Steve Traylen | ##### <a name="snat"></a>`snat` |
1503 | e17693e3 | Steve Traylen | |
1504 | Data type: `String[1]` |
||
1505 | |||
1506 | |||
1507 | |||
1508 | 09cba182 | Steve Traylen | ##### <a name="rulename"></a>`rulename` |
1509 | e17693e3 | Steve Traylen | |
1510 | Data type: `Pattern[/^[a-zA-Z0-9_]+$/]` |
||
1511 | |||
1512 | |||
1513 | |||
1514 | Default value: `$title` |
||
1515 | |||
1516 | 09cba182 | Steve Traylen | ##### <a name="order"></a>`order` |
1517 | e17693e3 | Steve Traylen | |
1518 | Data type: `Pattern[/^\d\d$/]` |
||
1519 | |||
1520 | |||
1521 | |||
1522 | Default value: `'70'` |
||
1523 | |||
1524 | 09cba182 | Steve Traylen | ##### <a name="chain"></a>`chain` |
1525 | e17693e3 | Steve Traylen | |
1526 | Data type: `String[1]` |
||
1527 | |||
1528 | |||
1529 | |||
1530 | Default value: `'POSTROUTING'` |
||
1531 | |||
1532 | 09cba182 | Steve Traylen | ##### <a name="oif"></a>`oif` |
1533 | e17693e3 | Steve Traylen | |
1534 | Data type: `Optional[String[1]]` |
||
1535 | |||
1536 | |||
1537 | |||
1538 | Default value: ``undef`` |
||
1539 | |||
1540 | 09cba182 | Steve Traylen | ##### <a name="saddr"></a>`saddr` |
1541 | e17693e3 | Steve Traylen | |
1542 | Data type: `Optional[String[1]]` |
||
1543 | |||
1544 | |||
1545 | |||
1546 | Default value: ``undef`` |
||
1547 | |||
1548 | 09cba182 | Steve Traylen | ##### <a name="proto"></a>`proto` |
1549 | e17693e3 | Steve Traylen | |
1550 | Data type: `Optional[Enum['tcp','udp']]` |
||
1551 | |||
1552 | |||
1553 | |||
1554 | Default value: ``undef`` |
||
1555 | |||
1556 | 09cba182 | Steve Traylen | ##### <a name="dport"></a>`dport` |
1557 | e17693e3 | Steve Traylen | |
1558 | bc1b0f1a | Steve Traylen | Data type: `Optional[Variant[String,Stdlib::Port]]` |
1559 | e17693e3 | Steve Traylen | |
1560 | |||
1561 | |||
1562 | Default value: ``undef`` |
||
1563 | |||
1564 | 09cba182 | Steve Traylen | ##### <a name="ensure"></a>`ensure` |
1565 | e17693e3 | Steve Traylen | |
1566 | Data type: `Enum['present','absent']` |
||
1567 | |||
1568 | |||
1569 | |||
1570 | Default value: `'present'` |
||
1571 | |||
1572 | 09cba182 | Steve Traylen | ### <a name="nftablesset"></a>`nftables::set` |
1573 | 7f6cacc5 | Steve Traylen | |
1574 | manage a named set |
||
1575 | |||
1576 | 13f4e4c6 | Steve Traylen | #### Examples |
1577 | |||
1578 | ##### simple set |
||
1579 | |||
1580 | ```puppet |
||
1581 | nftables::set{'my_set': |
||
1582 | type => 'ipv4_addr', |
||
1583 | flags => ['interval'], |
||
1584 | elements => ['192.168.0.1/24', '10.0.0.2'], |
||
1585 | auto_merge => true, |
||
1586 | } |
||
1587 | ``` |
||
1588 | |||
1589 | 7f6cacc5 | Steve Traylen | #### Parameters |
1590 | |||
1591 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::set` defined type: |
1592 | |||
1593 | * [`ensure`](#ensure) |
||
1594 | * [`setname`](#setname) |
||
1595 | * [`order`](#order) |
||
1596 | * [`type`](#type) |
||
1597 | * [`table`](#table) |
||
1598 | * [`flags`](#flags) |
||
1599 | * [`timeout`](#timeout) |
||
1600 | * [`gc_interval`](#gc_interval) |
||
1601 | * [`elements`](#elements) |
||
1602 | * [`size`](#size) |
||
1603 | * [`policy`](#policy) |
||
1604 | * [`auto_merge`](#auto_merge) |
||
1605 | * [`content`](#content) |
||
1606 | * [`source`](#source) |
||
1607 | |||
1608 | ##### <a name="ensure"></a>`ensure` |
||
1609 | 7f6cacc5 | Steve Traylen | |
1610 | Data type: `Enum['present','absent']` |
||
1611 | |||
1612 | 13f4e4c6 | Steve Traylen | should the set be created. |
1613 | 7f6cacc5 | Steve Traylen | |
1614 | Default value: `'present'` |
||
1615 | |||
1616 | 09cba182 | Steve Traylen | ##### <a name="setname"></a>`setname` |
1617 | 7f6cacc5 | Steve Traylen | |
1618 | Data type: `Pattern[/^[-a-zA-Z0-9_]+$/]` |
||
1619 | |||
1620 | 13f4e4c6 | Steve Traylen | name of set, equal to to title. |
1621 | 7f6cacc5 | Steve Traylen | |
1622 | Default value: `$title` |
||
1623 | |||
1624 | 09cba182 | Steve Traylen | ##### <a name="order"></a>`order` |
1625 | 7f6cacc5 | Steve Traylen | |
1626 | Data type: `Pattern[/^\d\d$/]` |
||
1627 | |||
1628 | 13f4e4c6 | Steve Traylen | concat ordering. |
1629 | 7f6cacc5 | Steve Traylen | |
1630 | Default value: `'10'` |
||
1631 | |||
1632 | 09cba182 | Steve Traylen | ##### <a name="type"></a>`type` |
1633 | 7f6cacc5 | Steve Traylen | |
1634 | Data type: `Optional[Enum['ipv4_addr', 'ipv6_addr', 'ether_addr', 'inet_proto', 'inet_service', 'mark']]` |
||
1635 | |||
1636 | 13f4e4c6 | Steve Traylen | type of set. |
1637 | 7f6cacc5 | Steve Traylen | |
1638 | Default value: ``undef`` |
||
1639 | |||
1640 | 09cba182 | Steve Traylen | ##### <a name="table"></a>`table` |
1641 | 7f6cacc5 | Steve Traylen | |
1642 | c94658e1 | Nacho Barrientos | Data type: `Variant[String, Array[String, 1]]` |
1643 | 7f6cacc5 | Steve Traylen | |
1644 | c94658e1 | Nacho Barrientos | table or array of tables to add the set to. |
1645 | 7f6cacc5 | Steve Traylen | |
1646 | Default value: `'inet-filter'` |
||
1647 | |||
1648 | 09cba182 | Steve Traylen | ##### <a name="flags"></a>`flags` |
1649 | 7f6cacc5 | Steve Traylen | |
1650 | Data type: `Array[Enum['constant', 'dynamic', 'interval', 'timeout'], 0, 4]` |
||
1651 | |||
1652 | 13f4e4c6 | Steve Traylen | specify flags for set |
1653 | 7f6cacc5 | Steve Traylen | |
1654 | Default value: `[]` |
||
1655 | |||
1656 | 09cba182 | Steve Traylen | ##### <a name="timeout"></a>`timeout` |
1657 | 7f6cacc5 | Steve Traylen | |
1658 | Data type: `Optional[Integer]` |
||
1659 | |||
1660 | 13f4e4c6 | Steve Traylen | timeout in seconds |
1661 | 7f6cacc5 | Steve Traylen | |
1662 | Default value: ``undef`` |
||
1663 | |||
1664 | 09cba182 | Steve Traylen | ##### <a name="gc_interval"></a>`gc_interval` |
1665 | 7f6cacc5 | Steve Traylen | |
1666 | Data type: `Optional[Integer]` |
||
1667 | |||
1668 | 13f4e4c6 | Steve Traylen | garbage collection interval. |
1669 | 7f6cacc5 | Steve Traylen | |
1670 | Default value: ``undef`` |
||
1671 | |||
1672 | 09cba182 | Steve Traylen | ##### <a name="elements"></a>`elements` |
1673 | 7f6cacc5 | Steve Traylen | |
1674 | Data type: `Optional[Array[String]]` |
||
1675 | |||
1676 | 13f4e4c6 | Steve Traylen | initialize the set with some elements in it. |
1677 | 7f6cacc5 | Steve Traylen | |
1678 | Default value: ``undef`` |
||
1679 | |||
1680 | 09cba182 | Steve Traylen | ##### <a name="size"></a>`size` |
1681 | 7f6cacc5 | Steve Traylen | |
1682 | Data type: `Optional[Integer]` |
||
1683 | |||
1684 | 13f4e4c6 | Steve Traylen | limits the maximum number of elements of the set. |
1685 | 7f6cacc5 | Steve Traylen | |
1686 | Default value: ``undef`` |
||
1687 | |||
1688 | 09cba182 | Steve Traylen | ##### <a name="policy"></a>`policy` |
1689 | 7f6cacc5 | Steve Traylen | |
1690 | Data type: `Optional[Enum['performance', 'memory']]` |
||
1691 | |||
1692 | 13f4e4c6 | Steve Traylen | determines set selection policy. |
1693 | 7f6cacc5 | Steve Traylen | |
1694 | Default value: ``undef`` |
||
1695 | |||
1696 | 09cba182 | Steve Traylen | ##### <a name="auto_merge"></a>`auto_merge` |
1697 | 7f6cacc5 | Steve Traylen | |
1698 | Data type: `Boolean` |
||
1699 | |||
1700 | 13f4e4c6 | Steve Traylen | ? |
1701 | 7f6cacc5 | Steve Traylen | |
1702 | Default value: ``false`` |
||
1703 | |||
1704 | 09cba182 | Steve Traylen | ##### <a name="content"></a>`content` |
1705 | 7f6cacc5 | Steve Traylen | |
1706 | Data type: `Optional[String]` |
||
1707 | |||
1708 | 13f4e4c6 | Steve Traylen | specify content of set. |
1709 | 7f6cacc5 | Steve Traylen | |
1710 | Default value: ``undef`` |
||
1711 | |||
1712 | 09cba182 | Steve Traylen | ##### <a name="source"></a>`source` |
1713 | 7f6cacc5 | Steve Traylen | |
1714 | Data type: `Optional[Variant[String,Array[String,1]]]` |
||
1715 | |||
1716 | 13f4e4c6 | Steve Traylen | specify source of set. |
1717 | 7f6cacc5 | Steve Traylen | |
1718 | Default value: ``undef`` |
||
1719 | |||
1720 | 09cba182 | Steve Traylen | ### <a name="nftablessimplerule"></a>`nftables::simplerule` |
1721 | 4d63adda | Nacho Barrientos | |
1722 | b46c9ce9 | Nacho Barrientos | Provides a simplified interface to nftables::rule |
1723 | 4d63adda | Nacho Barrientos | |
1724 | b46c9ce9 | Nacho Barrientos | #### Examples |
1725 | 4d63adda | Nacho Barrientos | |
1726 | b46c9ce9 | Nacho Barrientos | ##### allow incoming traffic from port 541 on port 543 TCP to a given IP range and count packets |
1727 | 4d63adda | Nacho Barrientos | |
1728 | b46c9ce9 | Nacho Barrientos | ```puppet |
1729 | nftables::simplerule{'my_service_in': |
||
1730 | action => 'accept', |
||
1731 | comment => 'allow traffic to port 543', |
||
1732 | counter => true, |
||
1733 | proto => 'tcp', |
||
1734 | dport => 543, |
||
1735 | daddr => '2001:1458::/32', |
||
1736 | sport => 541, |
||
1737 | } |
||
1738 | ``` |
||
1739 | 4d63adda | Nacho Barrientos | |
1740 | b46c9ce9 | Nacho Barrientos | #### Parameters |
1741 | 4d63adda | Nacho Barrientos | |
1742 | 09cba182 | Steve Traylen | The following parameters are available in the `nftables::simplerule` defined type: |
1743 | |||
1744 | * [`ensure`](#ensure) |
||
1745 | * [`rulename`](#rulename) |
||
1746 | * [`order`](#order) |
||
1747 | * [`chain`](#chain) |
||
1748 | * [`table`](#table) |
||
1749 | * [`action`](#action) |
||
1750 | * [`comment`](#comment) |
||
1751 | * [`dport`](#dport) |
||
1752 | * [`proto`](#proto) |
||
1753 | * [`daddr`](#daddr) |
||
1754 | * [`set_type`](#set_type) |
||
1755 | * [`sport`](#sport) |
||
1756 | * [`saddr`](#saddr) |
||
1757 | * [`counter`](#counter) |
||
1758 | |||
1759 | ##### <a name="ensure"></a>`ensure` |
||
1760 | 13f4e4c6 | Steve Traylen | |
1761 | Data type: `Enum['present','absent']` |
||
1762 | |||
1763 | Should the rule be created. |
||
1764 | |||
1765 | Default value: `'present'` |
||
1766 | |||
1767 | 09cba182 | Steve Traylen | ##### <a name="rulename"></a>`rulename` |
1768 | 4d63adda | Nacho Barrientos | |
1769 | 8c00b818 | Nacho Barrientos | Data type: `Nftables::SimpleRuleName` |
1770 | 4d63adda | Nacho Barrientos | |
1771 | b46c9ce9 | Nacho Barrientos | The symbolic name for the rule to add. Defaults to the resource's title. |
1772 | 4d63adda | Nacho Barrientos | |
1773 | Default value: `$title` |
||
1774 | |||
1775 | 09cba182 | Steve Traylen | ##### <a name="order"></a>`order` |
1776 | 4d63adda | Nacho Barrientos | |
1777 | Data type: `Pattern[/^\d\d$/]` |
||
1778 | |||
1779 | b46c9ce9 | Nacho Barrientos | A number representing the order of the rule. |
1780 | 4d63adda | Nacho Barrientos | |
1781 | Default value: `'50'` |
||
1782 | |||
1783 | 09cba182 | Steve Traylen | ##### <a name="chain"></a>`chain` |
1784 | 4d63adda | Nacho Barrientos | |
1785 | Data type: `String` |
||
1786 | |||
1787 | b46c9ce9 | Nacho Barrientos | The name of the chain to add this rule to. |
1788 | 4d63adda | Nacho Barrientos | |
1789 | Default value: `'default_in'` |
||
1790 | |||
1791 | 09cba182 | Steve Traylen | ##### <a name="table"></a>`table` |
1792 | 4d63adda | Nacho Barrientos | |
1793 | Data type: `String` |
||
1794 | |||
1795 | b46c9ce9 | Nacho Barrientos | The name of the table to add this rule to. |
1796 | 4d63adda | Nacho Barrientos | |
1797 | Default value: `'inet-filter'` |
||
1798 | |||
1799 | 09cba182 | Steve Traylen | ##### <a name="action"></a>`action` |
1800 | 4d63adda | Nacho Barrientos | |
1801 | Data type: `Enum['accept', 'continue', 'drop', 'queue', 'return']` |
||
1802 | |||
1803 | b46c9ce9 | Nacho Barrientos | The verdict for the matched traffic. |
1804 | 4d63adda | Nacho Barrientos | |
1805 | Default value: `'accept'` |
||
1806 | |||
1807 | 09cba182 | Steve Traylen | ##### <a name="comment"></a>`comment` |
1808 | 4d63adda | Nacho Barrientos | |
1809 | Data type: `Optional[String]` |
||
1810 | |||
1811 | b46c9ce9 | Nacho Barrientos | A typically human-readable comment for the rule. |
1812 | 4d63adda | Nacho Barrientos | |
1813 | Default value: ``undef`` |
||
1814 | |||
1815 | 09cba182 | Steve Traylen | ##### <a name="dport"></a>`dport` |
1816 | 4d63adda | Nacho Barrientos | |
1817 | Data type: `Optional[Nftables::Port]` |
||
1818 | |||
1819 | b46c9ce9 | Nacho Barrientos | The destination port, ports or port range. |
1820 | 4d63adda | Nacho Barrientos | |
1821 | Default value: ``undef`` |
||
1822 | |||
1823 | 09cba182 | Steve Traylen | ##### <a name="proto"></a>`proto` |
1824 | 4d63adda | Nacho Barrientos | |
1825 | Data type: `Optional[Enum['tcp', 'tcp4', 'tcp6', 'udp', 'udp4', 'udp6']]` |
||
1826 | |||
1827 | b46c9ce9 | Nacho Barrientos | The transport-layer protocol to match. |
1828 | 4d63adda | Nacho Barrientos | |
1829 | Default value: ``undef`` |
||
1830 | |||
1831 | 09cba182 | Steve Traylen | ##### <a name="daddr"></a>`daddr` |
1832 | 4d63adda | Nacho Barrientos | |
1833 | Data type: `Optional[Nftables::Addr]` |
||
1834 | |||
1835 | b46c9ce9 | Nacho Barrientos | The destination address, CIDR or set to match. |
1836 | 4d63adda | Nacho Barrientos | |
1837 | Default value: ``undef`` |
||
1838 | |||
1839 | 09cba182 | Steve Traylen | ##### <a name="set_type"></a>`set_type` |
1840 | 4d63adda | Nacho Barrientos | |
1841 | Data type: `Enum['ip', 'ip6']` |
||
1842 | |||
1843 | b46c9ce9 | Nacho Barrientos | When using sets as saddr or daddr, the type of the set. |
1844 | Use `ip` for sets of type `ipv4_addr`. |
||
1845 | 4d63adda | Nacho Barrientos | |
1846 | Default value: `'ip6'` |
||
1847 | |||
1848 | 09cba182 | Steve Traylen | ##### <a name="sport"></a>`sport` |
1849 | 4d63adda | Nacho Barrientos | |
1850 | Data type: `Optional[Nftables::Port]` |
||
1851 | |||
1852 | b46c9ce9 | Nacho Barrientos | The source port, ports or port range. |
1853 | 4d63adda | Nacho Barrientos | |
1854 | Default value: ``undef`` |
||
1855 | |||
1856 | 09cba182 | Steve Traylen | ##### <a name="saddr"></a>`saddr` |
1857 | 4d63adda | Nacho Barrientos | |
1858 | Data type: `Optional[Nftables::Addr]` |
||
1859 | |||
1860 | b46c9ce9 | Nacho Barrientos | The source address, CIDR or set to match. |
1861 | 4d63adda | Nacho Barrientos | |
1862 | Default value: ``undef`` |
||
1863 | |||
1864 | 09cba182 | Steve Traylen | ##### <a name="counter"></a>`counter` |
1865 | 4d63adda | Nacho Barrientos | |
1866 | Data type: `Boolean` |
||
1867 | |||
1868 | b46c9ce9 | Nacho Barrientos | Enable traffic counters for the matched traffic. |
1869 | 4d63adda | Nacho Barrientos | |
1870 | Default value: ``false`` |
||
1871 | |||
1872 | ## Data types |
||
1873 | |||
1874 | 09cba182 | Steve Traylen | ### <a name="nftablesaddr"></a>`Nftables::Addr` |
1875 | 4d63adda | Nacho Barrientos | |
1876 | Represents an address expression to be used within a rule. |
||
1877 | |||
1878 | 09cba182 | Steve Traylen | Alias of |
1879 | |||
1880 | ```puppet |
||
1881 | Variant[Stdlib::IP::Address::V6, Stdlib::IP::Address::V4, Nftables::Addr::Set] |
||
1882 | ``` |
||
1883 | 4d63adda | Nacho Barrientos | |
1884 | 09cba182 | Steve Traylen | ### <a name="nftablesaddrset"></a>`Nftables::Addr::Set` |
1885 | 4d63adda | Nacho Barrientos | |
1886 | Represents a set expression to be used within a rule. |
||
1887 | |||
1888 | 09cba182 | Steve Traylen | Alias of |
1889 | 4d63adda | Nacho Barrientos | |
1890 | 09cba182 | Steve Traylen | ```puppet |
1891 | Pattern[/^@[-a-zA-Z0-9_]+$/] |
||
1892 | ``` |
||
1893 | |||
1894 | ### <a name="nftablesport"></a>`Nftables::Port` |
||
1895 | 4d63adda | Nacho Barrientos | |
1896 | Represents a port expression to be used within a rule. |
||
1897 | |||
1898 | 09cba182 | Steve Traylen | Alias of |
1899 | |||
1900 | ```puppet |
||
1901 | Variant[Array[Stdlib::Port, 1], Stdlib::Port, Nftables::Port::Range] |
||
1902 | ``` |
||
1903 | 4d63adda | Nacho Barrientos | |
1904 | 09cba182 | Steve Traylen | ### <a name="nftablesportrange"></a>`Nftables::Port::Range` |
1905 | 4d63adda | Nacho Barrientos | |
1906 | Represents a port range expression to be used within a rule. |
||
1907 | |||
1908 | 09cba182 | Steve Traylen | Alias of |
1909 | 4d63adda | Nacho Barrientos | |
1910 | 09cba182 | Steve Traylen | ```puppet |
1911 | Pattern[/^\d+-\d+$/] |
||
1912 | ``` |
||
1913 | |||
1914 | ### <a name="nftablesrulename"></a>`Nftables::RuleName` |
||
1915 | 8c00b818 | Nacho Barrientos | |
1916 | Represents a rule name to be used in a raw rule created via nftables::rule. |
||
1917 | It's a dash separated string. The first component describes the chain to |
||
1918 | add the rule to, the second the rule name and the (optional) third a number. |
||
1919 | Ex: 'default_in-sshd', 'default_out-my_service-2'. |
||
1920 | |||
1921 | 09cba182 | Steve Traylen | Alias of |
1922 | |||
1923 | ```puppet |
||
1924 | Pattern[/^[a-zA-Z0-9_]+-[a-zA-Z0-9_]+(-\d+)?$/] |
||
1925 | ``` |
||
1926 | 8c00b818 | Nacho Barrientos | |
1927 | 09cba182 | Steve Traylen | ### <a name="nftablessimplerulename"></a>`Nftables::SimpleRuleName` |
1928 | 8c00b818 | Nacho Barrientos | |
1929 | Represents a simple rule name to be used in a rule created via nftables::simplerule |
||
1930 | |||
1931 | 09cba182 | Steve Traylen | Alias of |
1932 | |||
1933 | ```puppet |
||
1934 | Pattern[/^[a-zA-Z0-9_]+(-\d+)?$/] |
||
1935 | ``` |