Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Review the following alerts detected in dependencies. According to your organization's Security Policy, it is recommended to resolve "Warn" alerts. Learn more about Socket for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 54cfca5e9d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
src/pages/api/sidecar/[...path].ts
Outdated
| try { | ||
| const response = await fetch(targetUrl, { | ||
| method: req.method, | ||
| headers: { "Content-Type": "application/json" }, |
There was a problem hiding this comment.
Add sidecar authorization header in proxy
The proxy call to the sidecar only sets Content-Type and never sends an Authorization header, but the new sidecar middleware (sidecar/src/auth.rs) rejects every request without Authorization: Bearer <BEARER_TOKEN> and even returns 500 when the token is unset. In practice this makes the v4 flow fail for all /api/sidecar/* calls (401/500 from sidecar) even when the frontend request is otherwise valid.
Useful? React with 👍 / 👎.
|
|
||
| setStatus(Status.Pending); | ||
|
|
||
| const identityIndex = parseInt(activeIdentity.id, 10); |
There was a problem hiding this comment.
Use a real identity index for v4 sidecar requests
Computing identityIndex with parseInt(activeIdentity.id, 10) is incorrect because simulator identity IDs are hex commitment strings (e.g. 0x...), so this expression evaluates to 0 and always targets the first sidecar identity. When multiple identities are configured, selecting any non-first identity will generate/submit a proof for the wrong identity, corrupting verification results.
Useful? React with 👍 / 👎.
* chore: Run linter * spellcheck * add bearer token
v4-simulator-demo.mp4