https://github.com/islandcontroller/droplist
Manage and update iptables blocklists for Spamhaus' Do not Route Or Peer list
https://github.com/islandcontroller/droplist
iptables spamhaus
Last synced: 17 days ago
JSON representation
Manage and update iptables blocklists for Spamhaus' Do not Route Or Peer list
- Host: GitHub
- URL: https://github.com/islandcontroller/droplist
- Owner: islandcontroller
- Created: 2020-09-23T22:48:44.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2020-10-31T16:27:56.000Z (over 5 years ago)
- Last Synced: 2025-03-06T03:35:53.095Z (over 1 year ago)
- Topics: iptables, spamhaus
- Language: Shell
- Homepage:
- Size: 3.91 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# droplist
A simple systemd service to fetch *Do not Route Or Peer* records from the Spamhaus DROP list, and maintain them in an iptables chain.
## Requirements
The following packages are required for this service:
* iptables
* socat
* wget
## Installation
Download or clone the repo. Extract the ZIP archive, if necessary. Prepare the installation directory
sudo mkdir -p /opt/droplist
Copy the script files and set up permissions
sudo cp droplist* /opt/droplist/
cd /opt/droplist
sudo chown root:root droplist*
sudo chmod 644 droplist.service
sudo chmod 755 droplist_cmd
sudo chmod 700 droplistd
Link to the service file from systemd
cd /etc/systemd/system
sudo ln -s /opt/droplist/droplist.service
Reload systemd and configure service to start automatically on reboot
sudo systemctl daemon-reload
sudo systemctl enable droplist
## Usage
| Function | Shell Commands |
|--------------------|------------------------------------------|
| Start service | `sudo service droplist start` |
| Stop service | `sudo service droplist stop` |
| Check log messages | `sudo service droplist status` |
| Update IP list | `sudo /opt/droplist/droplist_cmd update` |
The update command can be called from a cronjob.
## Notes
* Check and modify access permissions to fit your application
* No responsibility for you locking yourself out of the system