Bitcoin Forum
October 17, 2018, 07:38:48 PM *
News: Make sure you are not using versions of Bitcoin Core other than 0.17.0 [Torrent], 0.16.3, 0.15.2, or 0.14.3. More info.
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: JavaScript library for cryptocurrency address validation  (Read 154 times)
iron888
Newbie
*
Offline Offline

Activity: 6
Merit: 0


View Profile
March 16, 2018, 10:01:48 AM
 #1

Is there any good JS library for cryptocurrency address validation? I've found this one https://github.com/ivands/crypto-address-validator, but it doesn't support a lot of currencies.
1539805128
Hero Member
*
Offline Offline

Posts: 1539805128

View Profile Personal Message (Offline)

Ignore
1539805128
Reply with quote  #2

1539805128
Report to moderator
1539805128
Hero Member
*
Offline Offline

Posts: 1539805128

View Profile Personal Message (Offline)

Ignore
1539805128
Reply with quote  #2

1539805128
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1539805128
Hero Member
*
Offline Offline

Posts: 1539805128

View Profile Personal Message (Offline)

Ignore
1539805128
Reply with quote  #2

1539805128
Report to moderator
1539805128
Hero Member
*
Offline Offline

Posts: 1539805128

View Profile Personal Message (Offline)

Ignore
1539805128
Reply with quote  #2

1539805128
Report to moderator
bob123
Hero Member
*****
Offline Offline

Activity: 714
Merit: 580



View Profile WWW
March 17, 2018, 02:09:42 PM
 #2

You might try this one out: https://github.com/ognus/wallet-address-validator
This one supports 21 currencies (the majority are low cap coins). But this should be enough information to build a libary which meets your requirements.
I'm not sure whether you will find a JS libary with every coin you need.

amargow
Newbie
*
Offline Offline

Activity: 1
Merit: 0


View Profile WWW
September 03, 2018, 11:01:49 AM
 #3

wallet-address-validator
Simple wallet address validator for validating Bitcoin and other altcoins addresses in Node.js and browser.

Forked from ryanralph/altcoin-address.

I forked it to remove all Node.js dependencies (crypro, Buffer etc.) to make it usable in the browser as well. I didn't use browserify to achieve smaller footprint, file size is 4.0 kB (minifed and gzipped).

Installation
Node
npm install wallet-address-validator
Browser
<script src="wallet-address-validator.min.js"></script>
Using bower
bower install wallet-address-validator

Read more : https://www.mytectra.com/python-training-in-bangalore.html
RGBKey
Hero Member
*****
Offline Offline

Activity: 840
Merit: 628


rgbkey.github.io/pgp.txt


View Profile WWW
September 04, 2018, 02:33:58 PM
 #4

How many currencies are we talking about? If it's not that many, you could probably just write your own library. The checksum or equivalent for most cryptos is not that complicated.

Initscri
Hero Member
*****
Online Online

Activity: 812
Merit: 559


OneHash.com - Mutual Betting & Casino


View Profile WWW
September 12, 2018, 05:28:08 AM
 #5

I'd use a switch case, and just use different libraries to support different cryptocurrencies. Default to not validating unless a validation library is found.

Personally what I would do is use ognus's library, and try to code the needed languages yourself; or create an issue for missing languages.
https://github.com/ognus/wallet-address-validator

If you're willing to leverage a backend API for validations: (since these things are mostly verified on the backend for enforcement, you may be able to find more).
https://github.com/murich/php-cryptocurrency-address-validation
https://github.com/LinusU/php-bitcoin-address-validator

Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!