Socket
Socket
Sign inDemoInstall

wallet-validator

Package Overview
Dependencies
7
Maintainers
1
Versions
24
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.12 to 0.3.14

3

package.json
{
"name": "wallet-validator",
"version": "0.3.12",
"version": "0.3.14",
"description": "Fast Wallet address validator for Bitcoin and other Altcoins.",
"keywords": [
"flux",
"smartholdem",

@@ -7,0 +8,0 @@ "sth",

@@ -100,3 +100,4 @@ # wallet-validator

* Raptoreum/RTM, `'rtm'` or `'RTM'`
* ReddCoin/RDD, `'rdd'` or `'rdd'`
* ReddCoin/RDD, `'rdd'` or `'RDD'`
* Flux/FLUX, `'flux'` or `'FLUX'`

@@ -103,0 +104,0 @@ ### Usage example

@@ -352,3 +352,10 @@ var XRPValidator = require('./ripple_validator');

validator: BTCValidator
},{
name: 'flux',
symbol: 'flux',
expectedLength: 26,
addressTypes: {prod: ['1cb8', '1cbd'], testnet: ['1d25', '1cba']},
validator: BTCValidator
}
];

@@ -355,0 +362,0 @@

const WAValidator = require('./src/wallet_address_validator');
let valid = WAValidator.validate('Rmhzj2GptZxkKBMqbUL6VjFcX8npDneAXR', 'rdd');
let valid = WAValidator.validate('t1U731sGEsYeArCBs55YiDtnvpoJLbCKPBU', 'flux');
if(valid)

@@ -6,0 +6,0 @@ console.log('This is a valid address');

@@ -598,2 +598,8 @@ var isNode = typeof module !== 'undefined' && typeof module.exports !== 'undefined';

it('should return true for correct flux addresses', function () {
valid('t1KDXgiVGmXiCPYbFnCuGzXqnHX3uLnQccr', 'flux');
valid('t1JrHUzZ6ToSAL313QjUS6zYCRrhMArcZy5', 'FLUX');
valid('t1U731sGEsYeArCBs55YiDtnvpoJLbCKPBU', 'Flux');
});
});

@@ -766,2 +772,9 @@

it('should return false for incorrect flux addresses', function () {
commonTests('flux');
invalid('t1kDXgiVGmXiCPYbFnCuGzXqnHX3uLnQccr', 'flux');
invalid('t1JrHUzZ6ToSAL313QjUS6zYCRrhMArczy5', 'FLUX');
invalid('t1U731sGEsYeArCBs55YiDtnvpoJLbCKPBu', 'Flux');
});
it('should return false for incorrect bitcoinprivate addresses', function () {

@@ -768,0 +781,0 @@ commonTests('bitcoinprivate');

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc