Skip to content

Conversation

@chihunmanse
Copy link
Contributor

Pull Request

Thank you for raising a Pull Request. Please follow the instruction.

  • I’ve read CONTRIBUTING.md and followed the guidelines.

Summary

Links (Issue References, etc, if there's any)

@chihunmanse chihunmanse requested a review from eldenpark January 28, 2026 08:40
@chihunmanse
Copy link
Contributor Author

@eldenpark Ready for review

import { addStatusRoutes } from "./status";
import { makeKeyshareRouter } from "./key_share/v1";
import { makeKeyshareV2Router } from "./key_share_v2";
import { makeCommitRevealRouter } from "./commit_reveal";
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure why we would need yet another router. I'll modify

@eldenpark
Copy link
Collaborator

@chihunmanse Please review the changes I've made!

@chihunmanse
Copy link
Contributor Author

@chihunmanse Please review the changes I've made!

I’ve reviewed the changes

router.post("/register", bearerTokenMiddleware, keyshareV2Register);
router.post(
"/register",
commitRevealMiddleware("register"),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@chihunmanse Question. Why do we need this middleware for almost all route handlers of V2?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@chihunmanse Question. Why do we need this middleware for almost all route handlers of V2?

Because any handler that requires OAuth authentication must ensure the OAuth token was committed and passes reveal validation before executing.

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.

3 participants