mTLS support #46
Replies: 8 comments 15 replies
-
|
perhaps via https://plugins.traefik.io/plugins/6637c92c3f17a1aeb061e27e/mtls-or-whitelist ? |
Beta Was this translation helpful? Give feedback.
-
|
i would love this feature. is there a way to contribute here? |
Beta Was this translation helpful? Give feedback.
-
|
I'd use the hell out of this feature if it were added Currently I need to choose between using Tailscale which limits me from using any other VPN on mobile devices, and using Cloudflare Tunnels with mTLS rules which I'm not a huge fan of because Cloudflare act as a MITM Most of the services I use support mTLS on their clients, obviously the clients aren't able to auth with Pangolin and I'm not keen on creating bypass rules for paths because I feel as though that makes services just as vulnerable as they would be if I didn't use any auth at all |
Beta Was this translation helpful? Give feedback.
-
|
Alright guys, I just tried this and it seems to work pretty good. What I achieved so far:
you can extend your dynamic conf stored in ### NEW
tls:
options:
default:
clientAuth:
caFiles:
- /etc/traefik/certs/rootCa.pem
clientAuthType: RequireAndVerifyClientCert
### NEW
http:
middlewares:
redirect-to-https:
redirectScheme:
scheme: https
routers:
# HTTP to HTTPS redirect router
main-app-router-redirect:
rule: "Host(`pangolin.domain.de`)"
service: next-service
entryPoints:
- web
middlewares:
- redirect-to-https
# Next.js router (handles everything except API and WebSocket paths)
next-router:
rule: "Host(`pangolin.domain.de`) && !PathPrefix(`/api/v1`)"
service: next-service
entryPoints:
- websecure
tls:
certResolver: letsencrypt
### NEW
options: default
### NEW
# API router (handles /api/v1 paths)
api-router:
rule: "Host(`pangolin.domain.de`) && PathPrefix(`/api/v1`)"
service: api-service
entryPoints:
- websecure
tls:
certResolver: letsencrypt
# WebSocket router
ws-router:
rule: "Host(`pangolin.domain.de`)"
service: api-service
entryPoints:
- websecure
tls:
certResolver: letsencrypt
services:
next-service:
loadBalancer:
servers:
- url: "http://pangolin:3002" # Next.js server
api-service:
loadBalancer:
servers:
- url: "http://pangolin:3000" # API/WebSocket serveryou still need to create your own rootCa and clientCert, which i created using these commands: # Create root CA private key
openssl genrsa -out rootCA.key 4096
# Create root CA certificate
openssl req -x509 -new -nodes -key rootCA.key -sha256 -days 3650 -out rootCA.pem
# Create client private key
openssl genrsa -out client.key 2048
# Create client CSR
openssl req -new -key client.key -out client.csr
# Create client certificate
openssl x509 -req -in client.csr -CA rootCA.pem -CAkey rootCA.key -CAcreateserial -out client.crt -days 365 -sha256
# Create client PFX file
openssl pkcs12 -export -out client.pfx -inkey client.key -in client.crt -certfile rootCA.pemthe file rootCa.pem should be placed at Please test this and give me Feedback. If it works for you too, I will look into how to secure specific Domains/Urls only. regards |
Beta Was this translation helpful? Give feedback.
-
|
This feature is really needed! The sharelink with auth headers are great for mobile applications that supported it but for apples like NextCloud and Home Assistant, we really need and mTLS feature to compete with CloudFlare. Thanks for this awesome app guys! |
Beta Was this translation helpful? Give feedback.
-
|
Would like to see this implemented. That's a gamechanger for enhanced security. |
Beta Was this translation helpful? Give feedback.
-
|
I've set up mTLS in Pangolin. I have the instructions here in both German and English. It's important to note that you can also secure domains/subdomains with mTLS once mTLS is configured for the dashboard using Pangolin SSO for the website. This allows you to decide whether or not to use mTLS for individual subdomains. German Instructions For suggestions, comments, or questions, please feel free to contact me. |
Beta Was this translation helpful? Give feedback.
-
|
mtls for individual routers coming with middleware manager next saturday. |
Beta Was this translation helpful? Give feedback.


Uh oh!
There was an error while loading. Please reload this page.
-
Requesting mTLS support to be able to do seamless client authentication.
Example (with CF): https://kcore.org/2024/06/28/using-cloudflare-zerotrust-and-mtls-with-home-assistant-via-the-internet/
Beta Was this translation helpful? Give feedback.
All reactions