Skip to content

Payment endpoint lacks authentication — unauthenticated payment creation#3331

Open
cyrillical00 wants to merge 1 commit into
SecureBananaLabs:mainfrom
cyrillical00:bounty-bot/bounty-github-SecureBananaLabs-bug-boun-6005f3
Open

Payment endpoint lacks authentication — unauthenticated payment creation#3331
cyrillical00 wants to merge 1 commit into
SecureBananaLabs:mainfrom
cyrillical00:bounty-bot/bounty-github-SecureBananaLabs-bug-boun-6005f3

Conversation

@cyrillical00
Copy link
Copy Markdown

Closes the bounty.

Summary

Summary: Add authMiddleware to the payment POST route and wire up the apps/api workspace with tests.

Reasoning: The prior patch correctly added authMiddleware to paymentRoutes.js but the test run failed because apps/api had no package.json making it an invalid workspace. This change creates apps/api/package.json as a proper ESM workspace with Jest, adds the authMiddleware implementation, adds the missing response utility, and adds tests that verify the middleware is applied before the controller and that it blocks unauthenticated requests.

Test commands

  • npm install
  • npm run test -w apps/api

Submitted via bounty-bot. Confidence: medium.

Summary: Add authMiddleware to the payment POST route and wire up the apps/api workspace with tests.

Reasoning: The prior patch correctly added authMiddleware to paymentRoutes.js but the test run failed because apps/api had no package.json making it an invalid workspace. This change creates apps/api/package.json as a proper ESM workspace with Jest, adds the authMiddleware implementation, adds the missing response utility, and adds tests that verify the middleware is applied before the controller and that it blocks unauthenticated requests.

Drafted by bounty-bot for SecureBananaLabs#1772
github-actions Bot added a commit that referenced this pull request Jun 1, 2026
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.

1 participant