Post-Quantum Cryptography (PQC) TLS Gateway for Hobbyists & Developers
"Security of the future, running on your server today."
GoPQ-Ingress is a lightweight, powerful reverse proxy written in Go. The goal? To demonstrate that Post-Quantum Cryptography isn't just for tech giants, but also for the hobbyist looking to secure their home lab against "Harvest Now, Decrypt Later" attacks.
[Proof of PQC Connection]
The screenshot above shows an active X25519MLKEM768 handshake via this ingress.
In the future, quantum computers will be capable of cracking current encryption methods (such as RSA and classical Elliptic Curves). Major players like Google and Cloudflare are already testing new standards.
With GoPQ-Ingress, you can too. This server enforces the Hybrid Post-Quantum Handshake (X25519 + Kyber/ML-KEM). This means your data traffic is already protected against the computers of 10 years from now.
-
🔒 Quantum-Safe: Uses standard CurveID(0x11ec) (X25519MLKEM768).
-
📜 Auto-SSL: Automatic certificates via Let's Encrypt (powered by CertMagic).
-
⚡ Lightweight: No heavy database required, just a simple config.yml.
-
🔌 WebSockets: Out-of-the-box support for real-time apps.
-
🕵️ Privacy Header: Adds X-PQC-Enabled: true to requests sent to your backend.
No installation required if you have Docker.
git clone https://github.com/andy-de-koning/GoPQ-Ingress.git
cd GoPQ-Ingress
docker build -t gopq-ingress .Create a file named config.yml:
# config.yml
email: "your-email@example.com" # For Let's Encrypt notifications
routes:
"mydomain.com": "http://127.0.0.1:8080"
"app.mydomain.com": "http://192.168.1.50:3000"
"socket.mydomain.com": "http://127.0.0.1:9000" # Works with WS too!This command starts the server and ensures your certificates are persisted.
docker run -d \
--name gopq-ingress \
--restart always \
-p 80:80 -p 443:443 \
-v $(pwd)/config.yml:/app/config.yml \
-v pqc_certs:/root/.local/share/certmagic \
gopq-ingress- Go 1.23 or higher (for optimal PQC support).
- A Linux server (e.g., Ubuntu) or local environment.
- Ports 80 and 443 must be available.
git clone https://github.com/andy-de-koning/GoPQ-Ingress.git
cd GoPQ-Ingress
go mod tidy
go build -o gopq-ingress main.goCreate a config.yml file next to the executable:
# config.yml
email: "your-email@example.com" # For Let's Encrypt notifications
routes:
"mydomain.com": "http://127.0.0.1:8080"
"app.mydomain.com": "http://192.168.1.50:3000"
"socket.mydomain.com": "http://127.0.0.1:9000" # Works with WS too!Since the server runs on ports 80 and 443, you will need root privileges (or use setcap):
sudo ./gopq-ingressThis project utilizes Go's crypto/tls library and overrides the default CurvePreferences. We prioritize the Hybrid Kyber method.
tlsConfig.CurvePreferences = []tls.CurveID{
tls.CurveID(0x11ec), // X25519MLKEM768
tls.X25519,
tls.CurveP256,
}This ensures that when a modern browser (such as Chrome or Edge) connects, a quantum-safe key exchange takes place. Older clients will gracefully fall back to standard X25519.
Have ideas to make this even better? Docker support? Metrics? Fork the repo and submit a Pull Request! Let's make the internet safer together.
Made with ❤️ and ☕ by Andy.