Projet

Général

Profil

Paste
Télécharger au format
Statistiques
| Branche: | Révision:

root @ 8726ba4c

Nom Taille Révision Âge Auteur Commentaire
  .vscode ece9be27 plus de 4 ans tr Do PDK convert
  data ece9be27 plus de 4 ans tr Do PDK convert
  files 9adf6851 plus de 4 ans tr Add mld-listener-done to the list of allowed ic...
  manifests e17693e3 plus de 4 ans Steve Traylen New parameter out_all, default false In order ...
  spec b171ac7f plus de 4 ans mh fix offenses
.fixtures.yml 253 octets ecb63cef plus de 4 ans tr Add dependencies
.gitattributes 62 octets 321ae8ab plus de 4 ans tr Add Puppet module basic files
.gitignore 298 octets ece9be27 plus de 4 ans tr Do PDK convert
.gitlab-ci.yml 1,21 ko 8726ba4c plus de 4 ans tr Switch back to Ruby 2.5 ``` can't modify froze...
.pdkignore 475 octets ece9be27 plus de 4 ans tr Do PDK convert
.puppet-lint.rc 11 octets 321ae8ab plus de 4 ans tr Add Puppet module basic files
.rspec 31 octets 321ae8ab plus de 4 ans tr Add Puppet module basic files
.rubocop.yml 3,86 ko ece9be27 plus de 4 ans tr Do PDK convert
.sync.yml 564 octets 8726ba4c plus de 4 ans tr Switch back to Ruby 2.5 ``` can't modify froze...
.travis.yml 1,22 ko 705bb26f plus de 4 ans tr Add travis ci configuration
.yardopts 18 octets 321ae8ab plus de 4 ans tr Add Puppet module basic files
CHANGELOG.md 146 octets ece9be27 plus de 4 ans tr Do PDK convert
Gemfile 3,42 ko ece9be27 plus de 4 ans tr Do PDK convert
LICENSE 11,1 ko 44ac0a4e plus de 4 ans mh add license file
README.md 2,29 ko af544fea plus de 4 ans tr Create a special ingoing chain for all ingoing ...
REFERENCE.md 10,9 ko e17693e3 plus de 4 ans Steve Traylen New parameter out_all, default false In order ...
Rakefile 3,45 ko ece9be27 plus de 4 ans tr Do PDK convert
appveyor.yml 1,31 ko ece9be27 plus de 4 ans tr Do PDK convert
hiera.yaml 685 octets ece9be27 plus de 4 ans tr Do PDK convert
metadata.json 1,19 ko ece9be27 plus de 4 ans tr Do PDK convert

Dernières révisions

# Date Auteur Commentaire
8726ba4c 2020-10-23 05:55 tr

Switch back to Ruby 2.5

```
can't modify frozen String: "true"
```
[Ticket IAC-1146](https://tickets.puppetlabs.com/browse/IAC-1146)

b171ac7f 2020-10-20 12:55 mh

fix offenses

9511e610 2020-10-20 11:36 duritong

Merge pull request #1 from traylenator/all

New parameter out_all, default false

e17693e3 2020-10-20 08:29 Steve Traylen

New parameter out_all, default false

In order to allow all outbound traffic a parameter is
added to enable a simple `allow` entry on the out chain.

Default is false so backwards compatible.

If true all the other out_bound rules (ntp, ...) will be disabled...

3f91610b 2020-10-16 11:17 tr

Merge branch 'pdk' into 'master'

Add a PDK configuration and run PDK convert

See merge request immerda/puppet-modules/nftables!1

9d7d63a6 2020-10-16 11:14 tr

Only test with Ruby 2.7 and Puppet 6

01d8a819 2020-10-16 10:29 tr

Styling to make tests green

705bb26f 2020-10-16 09:52 tr

Add travis ci configuration

ece9be27 2020-10-15 17:44 tr

Do PDK convert

a074dec2 2020-10-14 12:23 tr

Allow index numbers

Voir toutes les révisions | Voir les révisions

README


nftables puppet module

This module manages an opinionated nftables configuration

By default it sets up a firewall that drops every incoming and outgoing connection.

It only allows outgoing dns, ntp and web and ingoing ssh traffic.

The config file has a inet filter and a ip nat table setup.

Additionally, the module comes with a basic infrastrcuture to hook into different places.

nftables config

The main configuration file loaded by the nftables service will be files/config/puppet.nft, all other files created by that module go into files/config/puppet and will also be purged if not managed anymore.

The main configuration file includes dedicated files for the filter and nat tables, as well as processes any custom-*.nft files before hand.

The filter and NAT tables both have all the master chains (INPUT, OUTPUT, FORWARD in case of filter and PREROUTING and POSTROUTING in case of NAT) configured, to which you can hook in your own chains that can contain specific rules.

All filter masterchains drop by default. By default we have a set of default_MASTERCHAIN chains configured to which you can easily add your custom rules.

For specific needs you can add your own chain.

There is a global chain, that defines the default behavior for all masterchains.

INPUT and OUTPUT to the loopback device is allowed by default, though you could restrict it later.

nftables::config

Manages a raw file in /etc/nftables/puppet/${name}.nft

Use this for any custom table files.

nftables::chain

Prepares a chain file as a concat file to which you will be able to add dedicated rules through nftables::rule.

The name must be unique for all chains. The inject parameter can be used to directly add a jump to a masterchain. inject must follow the pattern ORDER-MASTERCHAIN, where order references a 2-digit number which defines the rule order (by default use e.g. 20) and masterchain references the chain to hook in the new chain. It's possible to specify the in-interface name and out-interface name for the inject rule.

nftables::rule

A simple way to add rules to any chain. The name must be: CHAIN_NAME-rulename, where CHAINNAME refers to your chain and an arbitrary name for your rule. The rule will be a concat::fragment to the chain `CHAINNAME`.

You can define the order by using the order param.

Formats disponibles : Atom