[PR #2196] [CLOSED] fix: auth side channel #2114

Closed
opened 2026-02-26 20:32:29 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/documenso/documenso/pull/2196
Author: @eithan1231
Created: 11/14/2025
Status: Closed

Base: mainHead: fix/auth-side-channel


📝 Commits (1)

📊 Changes

3 files changed (+39 additions, -0 deletions)

View changed files

📝 packages/auth/server/config.ts (+5 -0)
packages/auth/server/lib/utils/minimum-duration.ts (+29 -0)
📝 packages/auth/server/routes/email-password.ts (+5 -0)

📄 Description

Description

With the login endpoint, you can indirectly determine if a user exists based on the response time. Entering a valid email yields around 800ms, an invalid email is around 250ms.

The middleware is added to all email-password endpoints which is definitely overkill, let me know if you want me to change it to just the ones that are bcrypting. I was just hesitant to spam middleware everywhere, as there aren't many middlewares being used.

Changes Made

Added a middleware to vulnerable endpoints

Testing Performed

should be right

Checklist

  • [ passes the unit tests] I have tested these changes locally and they work as expected.
  • [ passes the unit tests] I have added/updated tests that prove the effectiveness of these changes.
  • [n/a ] I have updated the documentation to reflect these changes, if applicable.
  • [ hopefully] I have followed the project's coding style guidelines.
  • I have addressed the code review feedback from the previous submission, if applicable.

Additional Notes

looking to bankrupt documenso's bug bounty program thanks


🔄 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/documenso/documenso/pull/2196 **Author:** [@eithan1231](https://github.com/eithan1231) **Created:** 11/14/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `fix/auth-side-channel` --- ### 📝 Commits (1) - [`e1dd9a3`](https://github.com/documenso/documenso/commit/e1dd9a3877a41947dc12aad4c03fcd0ed2b9ec87) fix: auth side channel ### 📊 Changes **3 files changed** (+39 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `packages/auth/server/config.ts` (+5 -0) ➕ `packages/auth/server/lib/utils/minimum-duration.ts` (+29 -0) 📝 `packages/auth/server/routes/email-password.ts` (+5 -0) </details> ### 📄 Description ## Description With the login endpoint, you can indirectly determine if a user exists based on the response time. Entering a valid email yields around 800ms, an invalid email is around 250ms. The middleware is added to all email-password endpoints which is definitely overkill, let me know if you want me to change it to just the ones that are bcrypting. I was just hesitant to spam middleware everywhere, as there aren't many middlewares being used. ## Changes Made Added a middleware to vulnerable endpoints ## Testing Performed should be right ## Checklist - [ passes the unit tests] I have tested these changes locally and they work as expected. - [ passes the unit tests] I have added/updated tests that prove the effectiveness of these changes. - [n/a ] I have updated the documentation to reflect these changes, if applicable. - [ hopefully] I have followed the project's coding style guidelines. - [ ] I have addressed the code review feedback from the previous submission, if applicable. ## Additional Notes looking to bankrupt documenso's bug bounty program thanks --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-26 20:32:29 +03:00
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/documenso#2114
No description provided.