GNU Affero General Public License v3.0

项目介绍

ntop/ipt_geofence 是一个托管在 GitHub 上的开源项目,主要使用 C++ 编写,采用 GNU Affero General Public License v3.0 许可证,目前获得 139 个 Star、21 次 Fork。

仓库全名
ntop/ipt_geofence
开源许可证
GNU Affero General Public License v3.0
Star 数
139
Fork 数
21
未关闭 Issue
1

README 摘要

iptgeofence Geographical host protection for Linux and FreeBSD This tool allows you to protect your host/network by preventing communications with unwanted countries (aka geofencing). Furthermore, it allows you to specify a list of blacklists that enable you to drop well-known attackers. Prerequisites You need to install GeoIP libraries, Netfilter Queue, curl and JSONCPP packages in addition to the compiler. For…

完整内容见 GitHub 原始 README 或本页 。

常见问题

ipt_geofence 用什么语言开发?

主要使用 C++ 编写,采用 GNU Affero General Public License v3.0 许可证,目前有 139 个 Star。

ipt_geofence 可以免费商用吗?

仓库标注的许可证为 GNU Affero General Public License v3.0,商用前请先阅读仓库 LICENSE 文件确认授权范围。

如何获取 ipt_geofence 的源码?

可以直接克隆仓库:git clone https://github.com/ntop/ipt_geofence.git;安装与运行步骤见仓库 README。

ipt_geofence 最近还在维护吗?

仓库最近一次更新为 6月9日,当前有 1 个未关闭 Issue;Star 数为 139,可作为社区活跃度的参考。

关于

GitHub 原始描述(英文)

Geographical host protection for Linux/FreeBSD

描述取自 GitHub 官方 API,保持仓库作者书写的原文。

简要分析

热度分
320
价值分
103
活跃状态
活跃

README

ipt_geofence

Geographical host protection for Linux and FreeBSD

This tool allows you to protect your host/network by preventing communications with unwanted countries (aka geofencing). Furthermore, it allows you to specify a list of blacklists that enable you to drop well-known attackers.

Prerequisites

You need to install GeoIP libraries, Netfilter Queue, curl and JSONCPP packages in addition to the compiler.

For Ubuntu/Debian based systems do: sudo apt-get install build-essential autoconf automake autogen libmaxminddb-dev libcurl4-openssl-dev libnetfilter-queue-dev libjsoncpp-dev cppzmq-dev

On Enterprise Linux (Red Hat, Alma Linux, Rocky Linux, Fedora, etc)

dnf install dnf-plugins-core
dnf config-manager --set-enabled crb
dnf install epel-release
dnf install autoconf automake libmaxminddb-devel libcurl-devel openssl-devel zlib-devel libidn2-devel libnetfilter_queue-devel jsoncpp-devel cppzmq-devel libtool libpcap-devel
dnf groupinstall -y "Development Tools"

On FreeBSD pkg install -y autoconf automake curl libmaxminddb jsoncpp libzmq4 python3

The tool also needs a GeoIP database that you can obtain from sites such as db-ip or maxmind.

Configuration

This tool uses NFQUEUE to receive packets from kernel and analyze them in user-space. This means that you need to confiugure the Linux firewall prior to run the application. We provide you a simple configuration file that shows you how to send selected packets to the application for inspection.

You also need to configure a configuration file for your rules. We provide sample_config.json as a configuration example.

Binary Packages

Under packages/debian you can build a binary package for easy install on Debian/Ubuntu-based systems.

Usage

Supposing the you have configure the firewall as described above, you need to start (as root) the tool as follows

ipt_geofence -c config.json -m dbip-country-lite.mmdb

Performance

On Linux as only one packet per connection is sent to user-space, you will basically not observe any noticeable performance degradation. On FreeBSD instead, all packets have to pas through the application.

评论

暂无评论