Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
IBAN/BBAN validation and conversion following ISO 13616.
Last update: 92 - May 2022
Install using npm:
$ npm install fast-iban
var IBAN = require('fast-iban');
IBAN.formatBBAN('54320388899944', 'FO'); // 5432-038889994-4
IBAN.formatIBAN('BG80BNBG96611020345678'); // BG80 BNBG 9661 1020 3456 78
IBAN.generateIBAN('12345600000785', 'FI', true, true); // FI21 1234 5600 0007 85
IBAN.validateIBAN('AD12-0001-2030-2003-5910-0100'); // true
IBAN.validateIBAN('AZ21NABZ00000000137010001944'); // true
IBAN.validateIBAN('HR6510010051863000160'); // false
IBAN.validateIBAN('AT611904300234573201', true); // true
IBAN.validateIBAN('BG80BNBG96611020345678', false); // true
IBAN.validateBBAN('370400440532013000', 'DE'); // true
IBAN.validateBBAN('0WBK000000007099453', 'GI'); // false
formatBBAN(rawValue: String, rawCountryCode: String, separator?: String = '-')
-> String
Check requirements.
Returns rawValue formatted as BBAN for rawCountryCode
Validate BBAN before formatting.
See method validateBBAN(rawValue, rawCountryCode)
for more informations.
Separator can be customised.
Default value is -
.
Required
Null
String
Null
String
^[A-Z]{2}$
formatIBAN(rawValue: String)
-> String
Check requirements.
Returns rawValue formatted as an IBAN.
Required
Null
String
generateIBAN(rawValue: String, rawCountryCode: String, validateBBAN?: Boolean = false, formatIBAN?: Boolean = false)
-> String
Check requirements.
Returns value as a valid IBAN using rawValue and rawCountryCode.
If validateBBAN === true
, validate BBAN before the check digits.
See method validateBBAN(rawValue, rawCountryCode)
for more informations.
Default value is false
.
If formatIBAN === true
, format IBAN after generation of the check digits.
See method formatIBAN(rawValue)
for more informations.
Default value is false
.
Required
Null
String
Null
String
^[A-Z]{2}$
validateBBAN(rawValue: String, rawCountryCode: String)
-> Boolean
Check requirements.
Returns if the BBAN format against ISO 13616 specifications is valid.
Last update: October 2019
Source: https://www.swift.com/standards/data-standards/iban
If rawCountryCode
is unknow, prints warning in console and always returns true
.
Required
Null
String
Null
String
^[A-Z]{2}$
validateIBAN(rawValue: String, validateBBAN?: Boolean = false)
-> String
Check requirements.
Returns if the IBAN check digits are valid.
If validateBBAN === true
, validate BBAN before the check digits.
See method validateBBAN(rawValue, rawCountryCode)
for more informations.
Default value is false
.
Required
Null
String
^[A-Z]{2}[0-9]{2}[0-9A-Z]{11,30}$
FAQs
IBAN/BBAN validation and conversion following ISO 13616
The npm package fast-iban receives a total of 4,096 weekly downloads. As such, fast-iban popularity was classified as popular.
We found that fast-iban demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.