θΏ™ζ˜―indexlocζδΎ›ηš„ζœεŠ‘οΌŒδΈθ¦θΎ“ε…₯任何密码
Skip to content

Conversation

@timothycarambat
Copy link
Member

Pull Request Type

  • ✨ feat
  • πŸ› fix
  • ♻️ refactor
  • πŸ’„ style
  • πŸ”¨ chore
  • πŸ“ docs

What is in this change?

For single-user mode, move === to bcrypt comparison to prevent efficacy of timing attack potential. This is already covered for Multi-user.

The risk of this is low as the overhead for the HTTP response varies from request to request making this opportunity near-impossible to execute, but why not patch it πŸ‘

Developer Validations

  • I ran yarn lint from the root of the repo & committed changes
  • Relevant documentation has been updated
  • I have tested my code functionality
  • Docker build succeeds locally

@timothycarambat timothycarambat changed the title Change pwd check to O(1) check to prevent timing attacks Change pwd check to O(1) check to prevent timing attacks - single user mode Jan 11, 2024
@timothycarambat timothycarambat merged commit 3c859ba into master Jan 11, 2024
@timothycarambat timothycarambat deleted the security/constant-time-authtoken-check branch January 11, 2024 18:54
AStevensTaylor pushed a commit to PacktDev/anything-llm that referenced this pull request Jan 12, 2024
…r mode (Mintplex-Labs#575)

Change pwd check to O(1) check to prevent timing attacks
cabwds pushed a commit to cabwds/anything-llm that referenced this pull request Jul 3, 2025
…r mode (Mintplex-Labs#575)

Change pwd check to O(1) check to prevent timing attacks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants