[PR #4345] Feature: Add multi factor authentication #3865

Open
opened 2026-02-26 08:32:14 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/NginxProxyManager/nginx-proxy-manager/pull/4345
Author: @badkeyy
Created: 2/5/2025
Status: 🔄 Open

Base: developHead: feature/add-multi-factor-authentication


📝 Commits (10+)

📊 Changes

19 files changed (+597 additions, -121 deletions)

View changed files

backend/internal/mfa.js (+97 -0)
📝 backend/internal/token.js (+59 -24)
📝 backend/internal/user.js (+2 -1)
backend/migrations/20250115041439_mfa_integeration.js (+45 -0)
📝 backend/package.json (+2 -0)
📝 backend/routes/main.js (+1 -0)
backend/routes/mfa.js (+81 -0)
backend/schema/paths/mfa/delete/delete.json (+44 -0)
backend/schema/paths/mfa/enable/post.json (+44 -0)
📝 backend/schema/paths/tokens/post.json (+4 -0)
📝 backend/schema/paths/users/post.json (+1 -1)
📝 backend/schema/swagger.json (+10 -0)
📝 backend/yarn.lock (+0 -88)
📝 frontend/js/app/api.js (+42 -0)
📝 frontend/js/app/user/form.ejs (+21 -0)
📝 frontend/js/app/user/form.js (+93 -2)
📝 frontend/js/i18n/messages.json (+12 -1)
📝 frontend/js/login/ui/login.ejs (+8 -1)
📝 frontend/js/login/ui/login.js (+31 -3)

📄 Description

🚨 Contains Database Migration 🚨

Issue

Fixes https://github.com/NginxProxyManager/nginx-proxy-manager/issues/4276

Description:

This PR implements multi-factor authentication (MFA) to secure the login process. The new MFA feature adds an extra layer of security by requiring users to provide a second form of authentication, significantly reducing the risk of unauthorized access even if primary credentials (over http) are compromised.

Screenshots

image
image
image
image


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/NginxProxyManager/nginx-proxy-manager/pull/4345 **Author:** [@badkeyy](https://github.com/badkeyy) **Created:** 2/5/2025 **Status:** 🔄 Open **Base:** `develop` ← **Head:** `feature/add-multi-factor-authentication` --- ### 📝 Commits (10+) - [`2c15957`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/2c1595756d53167c15be3a3665157988a2edb88c) Add hosts to cert list - [`c6ab315`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/c6ab315165282cdfb11507f0e72f919bb20519f7) Add status indicator to certificates and show active domain names - [`6bbe7d4`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/6bbe7d4cc4193163e0e321318ffde869469e8593) Fix alignment - [`cea9a17`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/cea9a172182f5d8d40321dad6fa0443064c17847) Retrigger build - [`8fb9d9f`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/8fb9d9fec66f8cb9dd38b414ad1685e76670dd4e) Removed whitespace - [`50f7bfc`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/50f7bfc7261d16bc1ecbcba5b8bbfd8549e5783c) Add dead_hosts and redirection_hosts - [`f3fee7d`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/f3fee7d8867f05f25c70983c0ad900dccfcf9bb8) Merge - [`45fc638`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/45fc63875c116a387d00d753be2d2257fadc7a14) Merge branch 'feature/show-active-host-in-cert-list' of https://github.com/badkeyy/nginx-proxy-manager into feature/show-active-host-in-cert-list - [`69f7920`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/69f792067569a33fd9d8152b5d7f3f3378fba9d2) Remove console.logs - [`35938db`](https://github.com/NginxProxyManager/nginx-proxy-manager/commit/35938db24b1474f6358877cc537f7492322d7271) Added MFA to model and internal user ### 📊 Changes **19 files changed** (+597 additions, -121 deletions) <details> <summary>View changed files</summary> ➕ `backend/internal/mfa.js` (+97 -0) 📝 `backend/internal/token.js` (+59 -24) 📝 `backend/internal/user.js` (+2 -1) ➕ `backend/migrations/20250115041439_mfa_integeration.js` (+45 -0) 📝 `backend/package.json` (+2 -0) 📝 `backend/routes/main.js` (+1 -0) ➕ `backend/routes/mfa.js` (+81 -0) ➕ `backend/schema/paths/mfa/delete/delete.json` (+44 -0) ➕ `backend/schema/paths/mfa/enable/post.json` (+44 -0) 📝 `backend/schema/paths/tokens/post.json` (+4 -0) 📝 `backend/schema/paths/users/post.json` (+1 -1) 📝 `backend/schema/swagger.json` (+10 -0) 📝 `backend/yarn.lock` (+0 -88) 📝 `frontend/js/app/api.js` (+42 -0) 📝 `frontend/js/app/user/form.ejs` (+21 -0) 📝 `frontend/js/app/user/form.js` (+93 -2) 📝 `frontend/js/i18n/messages.json` (+12 -1) 📝 `frontend/js/login/ui/login.ejs` (+8 -1) 📝 `frontend/js/login/ui/login.js` (+31 -3) </details> ### 📄 Description 🚨 Contains Database Migration 🚨 ### Issue Fixes https://github.com/NginxProxyManager/nginx-proxy-manager/issues/4276 ### Description: This PR implements multi-factor authentication (MFA) to secure the login process. The new MFA feature adds an extra layer of security by requiring users to provide a second form of authentication, significantly reducing the risk of unauthorized access even if primary credentials (over http) are compromised. ### Screenshots ![image](https://github.com/user-attachments/assets/6d0245dd-0352-469f-9bfe-29eaf60d3dea) ![image](https://github.com/user-attachments/assets/4a974630-189a-4896-a241-f64d9fd701e6) ![image](https://github.com/user-attachments/assets/e10f03dc-d615-42a8-a465-2a97437ffe35) ![image](https://github.com/user-attachments/assets/f7759f0b-328d-4ebe-87b6-3abb4fc8ad36) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/nginx-proxy-manager-NginxProxyManager#3865
No description provided.