On se bouge, on signe la pétition en masse :
— Non c’est Non, Monsieur Duplomb !
— Pour la santé, la sécurité, l’intelligence collective.

👨‍💻 about me home CV/Resume News 🖊️ Contact Codeberg Github LinkedIn 🏆 Best of LuaX (tools) pub bang ypp panda lsvg ldc yreq Fizzbuzz Calculadoira TPG picfg Belenos (intro) 🔀 Git Repos

Made in Europe

ipd: IP daemon

ipd: IP daemon

A lightweight HTTP server that fetches and serves your public IPv4/IPv6 address to local clients.

Overview

ipd is an HTTP server designed to:

Requirements

Installation

Install Dependencies

sudo apt-get update
sudo apt-get install gcc libcurl4-openssl-dev

Compile ipd

git clone https://codeberg.org/cdsoft/ipd
cd ipd
gcc ipd.c -o ipd -lpthread -lcurl

Usage

Start the server

./ipd

The server listens on port 5050.

Fetch public IP

Use curl or a web browser to request your public IP:

Configuration

Change the port

Edit the ipd.c file and modify the following line to use a different port:

#define IPD_PORT            5050

Recompile the server after making changes.

Updating public IP

The server updates the public IP every hour by default. To change the update interval, modify the following line to use a different period:

#define REFRESH_PERIOD      (15*60)     /* update every 15 minutes */

Firewall

If you're using a firewall (e.g., ufw), allow the server port:

sudo ufw allow 8080/tcp

License

ipd is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

ipd is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with ipd.  If not, see <https://www.gnu.org/licenses/>.

For further information about ipd you can visit
https://codeberg.org/cdsoft/ipd

This site is powered by LuaX, bang, ypp, cdsoft.css and Pandoc.

Mirrors: cdelord.frchristophe.delord.free.frcdsoft.codeberg.page