GithubHelp home page GithubHelp logo

joyshmitz / ansible-iptables Goto Github PK

View Code? Open in Web Editor NEW

This project forked from supertarto/ansible-iptables

0.0 1.0 0.0 56 KB

Ansible role meant to install iptable and configure some rules

License: GNU General Public License v3.0

Shell 93.62% Jinja 6.38%

ansible-iptables's Introduction

Ansible Iptables

CI

Ansible role meant to install iptable and configure some rules.

Requirements

None

Tested plateform

  • Debian 10 (Buster)
  • Debian 11 (Bulleyes)

Role variables

The path where the rule file will be created:

iptables_rules_path: /usr/local/iptables

List of all allowed output TCP port, for everywhere:

iptables_allowed_output_tcp_ports: []

List of all allowed output UDP port, for everywhere:

iptables_allowed_output_udp_ports: []

List of all allowed input TCP port, from everywhere:

iptables_input_allowed_tcp_port: []

List of all allowed input UDP port, from everywhere:

iptables_input_allowed_udp_port: []

List of all allowed input TCP port, but with restricted source:

iptables_allowed_restricted_input_tcp_ports:
  - {ip:xx.xx.xx.xx, port:yyy}
  - {ip:zz.zz.zz.zz, port:yyy}

List of all allowed input UDP port, but with restricted source:

iptables_allowed_restricted_input_udp_ports:
  - {ip:zz.zz.zz.zz, port:yyy}

List of all allowed input TCP port, with restricted source, with transfer from a port to another:

iptables_input_transfert_allowed_tcp_port:
  - {ip:xx.xx.xx.xx, sport:yyy, dport:zzz}

List of specific adress to block - ALL PORT

iptables_drop_specific_adress: []
  - {ip: xx.xx.xx.xx}

Example(s)

---
- hosts: somehost
  roles:
    - supertarto.iptables
  vars:
    iptables_allowed_restricted_input_tcp_ports:
      - {ip:xx.xx.xx.xx, port:yyy}
      - {ip:zz.zz.zz.zz, port:yyy}

Installation

ansible-galaxy install supertarto.iptables

License

GPL V3.0

ansible-iptables's People

Contributors

supertarto avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.