Skip to content

use preimage hash for auth entry verification#2034

Open
jeesunikim wants to merge 1 commit into
mainfrom
feature-verifyAuthEntrySignature
Open

use preimage hash for auth entry verification#2034
jeesunikim wants to merge 1 commit into
mainfrom
feature-verifyAuthEntrySignature

Conversation

@jeesunikim

Copy link
Copy Markdown
Contributor

@github-project-automation github-project-automation Bot moved this to Backlog (Not Ready) in DevX Apr 14, 2026
@stellar-jenkins-ci

Copy link
Copy Markdown

@github-actions

Copy link
Copy Markdown

This pull request is stale because it has been open for 60 days with no activity.

@github-actions github-actions Bot added the Stale label Jun 14, 2026
@jeesunikim jeesunikim marked this pull request as ready for review June 26, 2026 23:17
Copilot AI review requested due to automatic review settings June 26, 2026 23:17

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR updates the transaction signatures UI to cryptographically verify Soroban authorization entry signatures using the HashIdPreimage-based payload, aligning auth-entry verification with how Soroban signatures are actually constructed.

Changes:

  • Replaces auth-entry “public key matches address” checks with signature verification over HashIdPreimageSorobanAuthorization (network ID + nonce + invocation + expiration ledger).
  • Plumbs raw auth-entry JSON through parsing so it can be re-encoded to XDR for verification.
  • Updates generated networkLimits.ts constants (large data-only regeneration).

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
src/app/(sidebar)/transaction/dashboard/components/Signatures.tsx Implements cryptographic verification for Soroban auth entry signatures and updates UI verification logic.
src/constants/networkLimits.ts Regenerates network limit constant values (auto-generated data file).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 85 to +90
"live_soroban_state_size_window": [
"698933560",
"699854984",
"700498804",
"700342140",
"700482104",
"700881920",
"701866036",
"702327232",
"702236112",
"702418272",
"702794004",
"703655676",
"703906824",
"704134152",
"704376184",
"704566128",
"704783500",
"705684296",
"706367628",
"706533156",
"706697884",
"706985136",
"707803656",
"707819944",
"707582232",
"708142500",
"708686816",
"709541828",
"710004992",
"709889972"
"815655900",
"816156784",
"816421916",
"816448200",
"816688596",
Comment on lines +112 to +118
const isMatch =
isXdrInit &&
verifyAuthEntrySignature(
entry.rawEntry,
entry.publicKey,
entry.signature,
network.passphrase,

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3571ade049

ℹ️ About Codex in GitHub

Codex has been enabled to automatically 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 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

);
const keypair = Keypair.fromPublicKey(stellarAddress);

return keypair.verify(payload, Buffer.from(signatureHex, "hex"));

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Verify the signer is authorized for the auth address

For address auth entries where the signature map contains a public_key that is not actually authorized by entry.address, this return value can still be true: the preimage constructed above is only network/nonce/expiration/invocation and does not bind addrAuth.address(), and the derived key is never checked against the credential address or its signer set. A forged or failed auth entry can therefore display a green check next to a victim address simply by including an attacker-controlled key and a valid signature from that key over the same payload.

Useful? React with 👍 / 👎.

@github-actions github-actions Bot removed the Stale label Jun 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Backlog (Not Ready)

Development

Successfully merging this pull request may close these issues.

2 participants