GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Sign auth entries when the signer is passed by public key by fnando · Pull Request #2658 · stellar/stellar-cli

Conversation

@fnando

@fnando fnando commented Jul 27, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

What

Passing an account by its public key (G…) where that account must sign — e.g. an Address argument that calls require_auth() — now resolves to the local identity that holds the matching key, exactly like passing the identity alias does. Previously this failed with Missing signing key for account G…, even though the key was present in the keystore.

Fixes #2459.

Why

Every signing path only resolved in one direction: an identity name or secret to an address/secret. When a raw public key was supplied, resolve_signer → get_secret_key recognized it as a public key and concluded no secret was available, so the auth entry went unsigned. Passing the same account by its alias worked, so the two were inconsistent for what is the same account. This adds the reverse lookup so a public key and its alias behave identically when signing.

Implementation: a new Locator::secret_by_public_key scans stored identities and returns the secret whose public key matches (reusing each identity's ledger/secure-store-aware public-key derivation). UnresolvedMuxedAccount::resolve_secret uses it for literal G…/M… addresses, falling back to the existing CannotSign error only when no identity matches. Covered by unit tests and an integration regression test that reproduces the original failure.

Known limitations

N/A

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Copilot AI review requested due to automatic review settings July 27, 2026 17:12
@github-project-automation github-project-automation Bot added this to DevX Jul 27, 2026
@github-project-automation github-project-automation Bot moved this to Backlog (Not Ready) in DevX Jul 27, 2026
@fnando fnando moved this from Backlog (Not Ready) to Needs Review in DevX Jul 27, 2026
@fnando fnando self-assigned this Jul 27, 2026
Copilot started reviewing on behalf of fnando July 27, 2026 17:12
View session
Copilot AI reviewed Jul 27, 2026
View reviewed changes

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Pull request overview

Adds reverse identity lookup so public-key contract arguments can locate their stored signing secrets.

Changes:

  • Adds public-key-to-secret identity lookup.
  • Resolves public-key arguments into auth signers.
  • Adds unit and integration regression tests.

Reviewed changes

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

File Description
config/locator.rs Adds reverse identity lookup and tests.
config/address.rs Resolves literal account addresses to secrets.
contract/arg_parsing.rs Creates signers from resolved addresses.
integration/auth.rs Tests signing via a public key.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread cmd/soroban-cli/src/commands/contract/arg_parsing.rs Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread cmd/soroban-cli/src/config/address.rs Resolved

Uh oh!

There was an error while loading. Please reload this page.

@fnando
fnando force-pushed the resolve-signer-by-public-key branch from a1d20fd to 822c4a2 Compare July 27, 2026 17:39
@fnando
fnando requested review from leighmcculloch, marcelosalloum and mootz12 July 27, 2026 17:52
@fnando
fnando enabled auto-merge (squash) July 27, 2026 17:52
@fnando
fnando force-pushed the resolve-signer-by-public-key branch 2 times, most recently from 0ad0cb2 to e602827 Compare July 28, 2026 13:45
fnando added 4 commits July 29, 2026 18:49
@fnando
Find a signer when given its public key.
bf6dbb3
@fnando
Only find a signer for plain account keys.
a50e938
@fnando
Honor the derivation path when signing by public key.
01a2072
@fnando
Test signing is refused for unknown and muxed accounts.
9422b21
@fnando
fnando force-pushed the resolve-signer-by-public-key branch from dde8297 to 9422b21 Compare July 29, 2026 21:49
leighmcculloch
leighmcculloch approved these changes Jul 30, 2026
View reviewed changes
@fnando
fnando merged commit 6c3bf44 into main Jul 30, 2026
228 of 229 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@fnando
fnando deleted the resolve-signer-by-public-key branch July 30, 2026 01:37
@github-project-automation github-project-automation Bot moved this from Needs Review to Done in DevX Jul 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

Copilot code review Copilot
Copilot review effort
Applies to this pull request for everyone.Learn more about Copilot code review.
Copilot left review comments
@leighmcculloch leighmcculloch leighmcculloch approved these changes
@marcelosalloum marcelosalloum Awaiting requested review from marcelosalloum
@mootz12 mootz12 Awaiting requested review from mootz12

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@fnando fnando

Labels

None yet

Projects

DevX
Status: Done

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

stellar contract invoke can't find a signer by its public keys

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@fnando @leighmcculloch
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.