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

(NOBIDS) fix scam token detection #2773

Merged
merged 1 commit into from
Dec 14, 2023
Merged

Conversation

LuccaBitfly
Copy link
Collaborator

Previously we used confusables.IsDangerous to detect tokens with weird token symbols. If you look into the code of that function, you'll see it checks isConfusable && isMixedScript, i.e. whether the string is confusable with Latin letters AND uses symbols from multiple scripts. If the token symbol entirely consists of symbols in another script (e.g. https://beaconcha.in/token/0xb4db731771601654322c1a469e747a69363813e7 is "ЕТН", which is actually from the Cyrillic script) this detection failed.

With this PR, we will now check isConfusable || isMixedScript, which will detect this token as sus.

@peterbitfly
Copy link
Collaborator

utACK

@LuccaBitfly LuccaBitfly merged commit bf09674 into master Dec 14, 2023
3 checks passed
@LuccaBitfly LuccaBitfly deleted the NOBIDS/fixScamTokenDetection branch December 14, 2023 08:59
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.

2 participants