Skip to content

Add OpenAlias for Monero sends - #1456

Draft
sneurlax wants to merge 5 commits into
stagingfrom
feat/openalias
Draft

sneurlax wants to merge 5 commits into
stagingfrom
feat/openalias

Conversation

@sneurlax

@sneurlax sneurlax commented Sep 30, 2026 •

Copy link
Copy Markdown
Member

Adds a DohOpenAlias class for handling DNS requests for OpenAlias records. Adds a DnsProxyConnection because of issues with socks5_proxy et al

@sneurlax
sneurlax marked this pull request as draft October 1, 2026 17:42
@codecov

codecov Bot commented Oct 1, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 96.72131% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 10.50%. Comparing base (1e2e4d9) to head (623d018).
⚠️ Report is 28 commits behind head on staging.

Files with missing lines Patch % Lines
lib/services/openalias/open_alias_service.dart 82.60% 4 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           staging    #1456      +/-   ##
===========================================
+ Coverage     7.85%   10.50%   +2.64%     
===========================================
  Files         1125     1130       +5     
  Lines       112820   113670     +850     
===========================================
+ Hits          8866    11938    +3072     
+ Misses      103954   101732    -2222     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@sneurlax
sneurlax marked this pull request as ready for review October 1, 2026 18:23
@sneurlax
sneurlax marked this pull request as draft October 7, 2026 02:17
@sneurlax

sneurlax commented Oct 7, 2026

Copy link
Copy Markdown
Member Author

this is a valid impl but we are taking another approach that is WIP and the last few PRs merged in various cypherstack repos today indicate the approach (DYOR)

@sneurlax

sneurlax commented Oct 7, 2026

Copy link
Copy Markdown
Member Author

TODO: drop Util.debugIsDesktopOverride and its test because #1465 added Util.layoutPlatform for the same purpose. Port open_alias_preview_test.dart to use it.

@sneurlax
sneurlax force-pushed the feat/openalias branch 2 times, most recently from 11db864 to 6357703 Compare October 15, 2026 01:07
@sneurlax
sneurlax marked this pull request as ready for review October 15, 2026 20:32
@julian-CStack
julian-CStack marked this pull request as draft October 16, 2026 12:40
Add cs_openalias, pinned by commit, and override its unpublished
constituents openalias, dnssec_resolver and doh_transport with pinned
commits too. doh_transport needs socks_socket ^2.0.0, so socks_socket
becomes a direct dependency at 2.0.0, and fusiondart and electrum_adapter
move to the revisions that accept it (electrum_adapter 3.0.2 -> 4.0.1,
the merge of cypherstack/electrum_adapter#15). The lock was resolved from
local checkouts of the pinned commits and carries the GitHub URLs, so it
resolves without local paths once those commits are on GitHub.
…a send

On Monero, an address field holding a name that has the form of an
OpenAlias counts as a valid recipient, so Preview is enabled and no
"Invalid address" is shown. Previewing such a send first looks the alias
up through cs_openalias behind the usual progress dialog, whose Cancel
cancels the lookup. The resolved address replaces the alias in the field
as a paste would, and the preview continues as for any literal address.
A failed or unavailable lookup shows the OpenAlias error and stops
before anything else runs.

OpenAliasService reads the Incognito and Tor settings for each lookup.
With Incognito mode on, or Tor on but unavailable, nothing is sent and
the error says why; otherwise it returns the facade's operation, routed
through the Tor proxy when Tor is on.
TxData gains an optional openAlias: the alias, trimmed and lowercased,
that the recipient's address was resolved from. copyWith keeps it.
The preview functions keep the alias they resolved in a local and pass it
as TxData.openAlias with the single recipient, so it is set only for the
send that resolved it. Other coins, literal addresses and multiple
recipients leave it null.
When the transaction carries an OpenAlias, the confirm screen shows it
labelled "OpenAlias" above the recipient on mobile and above "Send to" on
desktop.
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