Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Give a warning when sending to a non-checksum'ed address or an address who's checksum doesn't validate the address #19532

Closed
bbondy opened this issue Nov 17, 2021 · 2 comments · Fixed by brave/brave-core#11607
Assignees
Labels
feature/web3/wallet Integrating Ethereum+ wallet support OS/Android Fixes related to Android browser functionality OS/Desktop priority/P2 A bad problem. We might uplift this to the next planned release. QA Pass-Linux QA Pass-macOS QA Pass-Win64 QA/Yes release-notes/include

Comments

@bbondy
Copy link
Member

bbondy commented Nov 17, 2021

In Ethereum an address casing is used as a checksum for validation. We should check this and if it fails give an error.

  • If an input address matches the API result for KeyringController's GetChecksumEthAddress then don't give a warning
  • If an address has each alphabetic character as lowercase, give a warning that the address has no checksum information and might be invalid.
  • If an address has each alphabetic character as uppercase, give a warning that the address has no checksum information and might be invalid.
  • If an address has both lowercase and uppercase alphabetic characters, and it doesn't match the checksum address, give an error and don't allow the user to send.
@bbondy bbondy added priority/P2 A bad problem. We might uplift this to the next planned release. OS/Android Fixes related to Android browser functionality OS/Desktop labels Nov 17, 2021
@bbondy bbondy added the feature/web3/wallet Integrating Ethereum+ wallet support label Nov 23, 2021
@bbondy bbondy self-assigned this Dec 13, 2021
@bbondy bbondy removed their assignment Dec 14, 2021
@onyb onyb self-assigned this Dec 14, 2021
@onyb onyb added this to the 1.35.x - Nightly milestone Dec 17, 2021
@srirambv
Copy link
Contributor

Brave 1.35.89 Chromium: 97.0.4692.71 (Official Build) beta (64-bit)
Revision adefa7837d02a07a604c1e6eff0b3a09422ab88d-refs/branch-heads/4692@{#1247}
OS ☑️ Linux ☑️ Windows 11 Version Dev
(Build 22523.1000)
☑️ macOS Version 12.0.1
(Build 21C52)
  • Verified steps from brave/brave-core#11607
  • Verified entering an invalid address throws message about not a valid ETH address
  • Verified an error is shown when the address is missing checksum or has an invalid checksum
19532-Linux.mp4
19532-Windows.mov
19532-macOS.mov

@Ymetro
Copy link

Ymetro commented Feb 11, 2023

So, then we have to ask, for instance, Binance for using casing in their deposit addresses, cause now it can only be sent by Brave Browser for PC/Mac/Linux and not by the Brave Mobile browser version 1.47 (23.2.1.14) on iOS 16.3, because after the check there is no way to proceed when asked; the sent button remains greyed out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature/web3/wallet Integrating Ethereum+ wallet support OS/Android Fixes related to Android browser functionality OS/Desktop priority/P2 A bad problem. We might uplift this to the next planned release. QA Pass-Linux QA Pass-macOS QA Pass-Win64 QA/Yes release-notes/include
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants