Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ibantools

Package Overview
Dependencies
Maintainers
1
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ibantools - npm Package Compare versions

Comparing version 1.5.1 to 1.6.0

7

build/ibantools.d.ts

@@ -74,2 +74,3 @@ /*!

export interface ExtractIBANResult {
iban: string;
bban?: string;

@@ -83,7 +84,7 @@ countryCode?: string;

* @example
* // returns {bban: 'ABNA0417164300', countryCode: 'NL', countryName: 'Netherlands', valid: true}
* ibantools.extractIBAN('NL91ABNA0417164300');
* // returns {iban: 'NL91ABNA0417164300', bban: 'ABNA0417164300', countryCode: 'NL', countryName: 'Netherlands', valid: true}
* ibantools.extractIBAN('NL91 ABNA 0417 1643 00');
* @alias module:ibantools.extractIBAN
* @param {string} IBAN IBAN
* @return {ExtractIBANResult} Object {bban: string, countryCode: string, countryName: string, valid: boolean}
* @return {ExtractIBANResult} Object {iban: string, bban: string, countryCode: string, countryName: string, valid: boolean}
*/

@@ -90,0 +91,0 @@ export declare function extractIBAN(iban: string): ExtractIBANResult;

@@ -11,3 +11,3 @@ /*!

* @see module:ibantools
* @version 1.5.1
* @version 1.6.0
* @license MPL-2.0

@@ -103,7 +103,7 @@ */

* @example
* // returns {bban: 'ABNA0417164300', countryCode: 'NL', countryName: 'Netherlands', valid: true}
* ibantools.extractIBAN('NL91ABNA0417164300');
* // returns {iban: 'NL91ABNA0417164300', bban: 'ABNA0417164300', countryCode: 'NL', countryName: 'Netherlands', valid: true}
* ibantools.extractIBAN('NL91 ABNA 0417 1643 00');
* @alias module:ibantools.extractIBAN
* @param {string} IBAN IBAN
* @return {ExtractIBANResult} Object {bban: string, countryCode: string, countryName: string, valid: boolean}
* @return {ExtractIBANResult} Object {iban: string, bban: string, countryCode: string, countryName: string, valid: boolean}
*/

@@ -113,2 +113,3 @@ function extractIBAN(iban) {

iban = electronicFormatIBAN(iban);
result.iban = iban;
if (isValidIBAN(iban)) {

@@ -151,3 +152,3 @@ result.bban = iban.slice(4);

}
return iban.replace(/[^a-zA-Z0-9]/g, "").toUpperCase();
return iban.replace(/[-\ ]/g, "").toUpperCase();
}

@@ -274,15 +275,18 @@ exports.electronicFormatIBAN = electronicFormatIBAN;

*/
countrySpecs['AD'] = { chars: 24, bban_regexp: '^[0-9]{8}[A-Z0-9]{12}$', name: 'Andorra' };
countrySpecs['AE'] = { chars: 23, bban_regexp: '^[0-9]{3}[0-9]{16}$', name: 'United Arab Emirates' };
countrySpecs['AL'] = { chars: 28, bban_regexp: '^[0-9]{8}[A-Z0-9]{16}$', name: 'Albania' };
countrySpecs['AD'] = { chars: 24, bban_regexp: '^[0-9]{8}[A-Z0-9]{12}$', name: 'Andorra' };
countrySpecs['AT'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Austria' };
countrySpecs['AZ'] = { chars: 28, bban_regexp: '^[A-Z]{4}[0-9]{20}$', name: 'Republic of Azerbaijan' };
countrySpecs['BA'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Bosnia and Herzegovina' };
countrySpecs['BE'] = { chars: 16, bban_regexp: '^[0-9]{12}$', name: 'Belgium' };
countrySpecs['BG'] = { chars: 22, bban_regexp: '^[A-Z]{4}[0-9]{6}[A-Z0-9]{8}$', name: 'Bulgaria' };
countrySpecs['BH'] = { chars: 22, bban_regexp: '^[A-Z]{4}[A-Z0-9]{14}$', name: 'Bahrain' };
countrySpecs['BE'] = { chars: 16, bban_regexp: '^[0-9]{12}$', name: 'Belgium' };
countrySpecs['BA'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Bosnia and Herzegovina' };
countrySpecs['BR'] = { chars: 29, bban_regexp: '^[0-9]{23}[A-Z]{1}[A-Z0-9]{1}$', name: 'Brazil' };
countrySpecs['BG'] = { chars: 22, bban_regexp: '^[A-Z]{4}[0-9]{6}[A-Z0-9]{8}$', name: 'Bulgaria' };
countrySpecs['CR'] = { chars: 21, bban_regexp: '^[0-9]{17}$', name: 'Costa Rica' };
countrySpecs['HR'] = { chars: 21, bban_regexp: '^[0-9]{17}$', name: 'Croatia' };
countrySpecs['BY'] = { chars: 28, bban_regexp: '^[A-Z]{4}[0-9]{4}[A-Z0-9]{16}$', name: 'Republic of Belarus' };
countrySpecs['CH'] = { chars: 21, bban_regexp: '^[0-9]{5}[A-Z0-9]{12}$', name: 'Switzerland' };
countrySpecs['CR'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Costa Rica' };
countrySpecs['CY'] = { chars: 28, bban_regexp: '^[0-9]{8}[A-Z0-9]{16}$', name: 'Cyprus' };
countrySpecs['CZ'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Czech Republic' };
countrySpecs['DE'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Germany' };
// Denmark

@@ -295,2 +299,3 @@ countrySpecs['DK'] = { chars: 18, bban_regexp: '^[0-9]{14}$', name: 'Denmark' };

countrySpecs['EE'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Estonia' };
countrySpecs['ES'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Spain' };
// Finland

@@ -315,47 +320,49 @@ countrySpecs['FI'] = { chars: 18, bban_regexp: '^[0-9]{14}$', name: 'Finland' };

// End France
// United Kingdom
countrySpecs['GB'] = { chars: 22, bban_regexp: '^[A-Z]{4}[0-9]{14}$', name: 'United Kingdom' };
// End united kingdom
countrySpecs['GE'] = { chars: 22, bban_regexp: '^[A-Z0-9]{2}[0-9]{16}$', name: 'Georgia' };
countrySpecs['DE'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Germany' };
countrySpecs['GI'] = { chars: 23, bban_regexp: '^[A-Z]{4}[A-Z0-9]{15}$', name: 'Gibraltar' };
countrySpecs['GR'] = { chars: 27, bban_regexp: '^[0-9]{7}[A-Z0-9]{16}$', name: 'Greece' };
countrySpecs['GT'] = { chars: 28, bban_regexp: '^[A-Z0-9]{24}$', name: 'Guatemala' };
countrySpecs['HR'] = { chars: 21, bban_regexp: '^[0-9]{17}$', name: 'Croatia' };
countrySpecs['HU'] = { chars: 28, bban_regexp: '^[0-9]{24}$', name: 'Hungary' };
countrySpecs['IS'] = { chars: 26, bban_regexp: '^[0-9]{22}$', name: 'Iceland' };
countrySpecs['IE'] = { chars: 22, bban_regexp: '^[A-Z0-9]{4}[0-9]{14}$', name: 'Republic of Ireland' };
countrySpecs['IL'] = { chars: 23, bban_regexp: '^[0-9]{19}$', name: 'Israel' };
countrySpecs['IQ'] = { chars: 23, bban_regexp: '^[A-Z]{4}[0-9]{15}$', name: 'Iraq' };
countrySpecs['IS'] = { chars: 26, bban_regexp: '^[0-9]{22}$', name: 'Iceland' };
countrySpecs['IT'] = { chars: 27, bban_regexp: '^[A-Z]{1}[0-9]{10}[A-Z0-9]{12}$', name: 'Italy' };
countrySpecs['JO'] = { chars: 30, bban_regexp: '^[A-Z]{4}[0-9]{4}[A-Z0-9]{18}$', name: 'Jordan' };
countrySpecs['KW'] = { chars: 30, bban_regexp: '^[A-Z]{4}[A-Z0-9]{22}$', name: 'Kuwait' };
countrySpecs['KZ'] = { chars: 20, bban_regexp: '^[0-9]{3}[A-Z0-9]{13}$', name: 'Kazakhstan' };
countrySpecs['XK'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Kosovo' };
countrySpecs['KW'] = { chars: 30, bban_regexp: '^[A-Z]{4}[A-Z0-9]{22}$', name: 'Kuwait' };
countrySpecs['LV'] = { chars: 21, bban_regexp: '^[A-Z]{4}[A-Z0-9]{13}$', name: 'Latvia' };
countrySpecs['LB'] = { chars: 28, bban_regexp: '^[0-9]{4}[A-Z0-9]{20}$', name: 'Lebanon' };
countrySpecs['LC'] = { chars: 32, bban_regexp: '^[A-Z]{4}[A-Z0-9]{24}$', name: 'Saint Lucia' };
countrySpecs['LI'] = { chars: 21, bban_regexp: '^[0-9]{5}[A-Z0-9]{12}$', name: 'Liechtenstein' };
countrySpecs['LT'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Lithuania' };
countrySpecs['LU'] = { chars: 20, bban_regexp: '^[0-9]{3}[A-Z0-9]{13}$', name: 'Luxembourg' };
countrySpecs['LV'] = { chars: 21, bban_regexp: '^[A-Z]{4}[A-Z0-9]{13}$', name: 'Latvia' };
countrySpecs['MC'] = { chars: 27, bban_regexp: '^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$', name: 'Monaco' };
countrySpecs['MD'] = { chars: 24, bban_regexp: '^[A-Z0-9]{2}[A-Z0-9]{18}$', name: 'Moldova' };
countrySpecs['ME'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Montenegro' };
countrySpecs['MK'] = { chars: 19, bban_regexp: '^[0-9]{3}[A-Z0-9]{10}[0-9]{2}$', name: 'Republic of Macedonia' };
countrySpecs['MR'] = { chars: 27, bban_regexp: '^[0-9]{23}$', name: 'Mauritania' };
countrySpecs['MT'] = { chars: 31, bban_regexp: '^[A-Z]{4}[0-9]{5}[A-Z0-9]{18}$', name: 'Malta' };
countrySpecs['MR'] = { chars: 27, bban_regexp: '^[0-9]{23}$', name: 'Mauritania' };
countrySpecs['MU'] = { chars: 30, bban_regexp: '^[A-Z]{4}[0-9]{19}[A-Z]{3}$', name: 'Mauritius' };
countrySpecs['MD'] = { chars: 24, bban_regexp: '^[A-Z0-9]{2}[A-Z0-9]{18}$', name: 'Moldova' };
countrySpecs['MC'] = { chars: 27, bban_regexp: '^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$', name: 'Monaco' };
countrySpecs['ME'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Montenegro' };
countrySpecs['NL'] = { chars: 18, bban_regexp: '^[A-Z]{4}[0-9]{10}$', name: 'Netherlands' };
countrySpecs['NO'] = { chars: 15, bban_regexp: '^[0-9]{11}$', name: 'Norway' };
countrySpecs['PK'] = { chars: 24, bban_regexp: '^[A-Z0-9]{4}[0-9]{16}$', name: 'Pakistan' };
countrySpecs['PS'] = { chars: 29, bban_regexp: '^[A-Z0-9]{4}[0-9]{21}$', name: 'Palestinian territories' };
countrySpecs['PL'] = { chars: 28, bban_regexp: '^[0-9]{24}$', name: 'Poland' };
countrySpecs['PS'] = { chars: 29, bban_regexp: '^[A-Z0-9]{4}[0-9]{21}$', name: 'State of Palestine' };
countrySpecs['PT'] = { chars: 25, bban_regexp: '^[0-9]{21}$', name: 'Portugal' };
countrySpecs['QA'] = { chars: 29, bban_regexp: '^[A-Z]{4}[A-Z0-9]{21}$', name: 'Qatar' };
countrySpecs['RO'] = { chars: 24, bban_regexp: '^[A-Z]{4}[A-Z0-9]{16}$', name: 'Romania' };
countrySpecs['LC'] = { chars: 32, bban_regexp: '^[A-Z]{4}[A-Z0-9]{24}$', name: 'Saint Lucia' };
countrySpecs['SM'] = { chars: 27, bban_regexp: '^[A-Z]{1}[0-9]{10}[A-Z0-9]{12}$', name: 'San Marino' };
countrySpecs['ST'] = { chars: 25, bban_regexp: '^[0-9]{21}$', name: 'Sao Tome And Principe' };
countrySpecs['RS'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Serbia' };
countrySpecs['SA'] = { chars: 24, bban_regexp: '^[0-9]{2}[A-Z0-9]{18}$', name: 'Saudi Arabia' };
countrySpecs['RS'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Serbia' };
countrySpecs['SC'] = { chars: 31, bban_regexp: '^[[A-Z]{4}[]0-9]{20}[A-Z]{3}$', name: 'Seychelles' };
countrySpecs['SE'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Sweden' };
countrySpecs['SI'] = { chars: 19, bban_regexp: '^[0-9]{15}$', name: 'Slovenia' };
countrySpecs['SK'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Slovak Republic' };
countrySpecs['SI'] = { chars: 19, bban_regexp: '^[0-9]{15}$', name: 'Slovenia' };
countrySpecs['ES'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Spain' };
countrySpecs['SE'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Sweden' };
countrySpecs['CH'] = { chars: 21, bban_regexp: '^[0-9]{5}[A-Z0-9]{12}$', name: 'Switzerland' };
countrySpecs['SM'] = { chars: 27, bban_regexp: '^[A-Z]{1}[0-9]{10}[A-Z0-9]{12}$', name: 'San Marino' };
countrySpecs['ST'] = { chars: 25, bban_regexp: '^[0-9]{21}$', name: 'Sao Tome And Principe' };
countrySpecs['SV'] = { chars: 28, bban_regexp: '^[A-Z]{4}[0-9]{20}$', name: 'El Salvador' };
countrySpecs['TL'] = { chars: 23, bban_regexp: '^[0-9]{19}$', name: 'Timor-Leste' };

@@ -365,4 +372,3 @@ countrySpecs['TN'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Tunisia' };

countrySpecs['UA'] = { chars: 29, bban_regexp: '^[0-9]{6}[A-Z0-9]{19}$', name: 'Ukraine' };
countrySpecs['AE'] = { chars: 23, bban_regexp: '^[0-9]{3}[0-9]{16}$', name: 'United Arab Emirates' };
countrySpecs['GB'] = { chars: 22, bban_regexp: '^[A-Z]{4}[0-9]{14}$', name: 'United Kingdom' };
countrySpecs['VG'] = { chars: 24, bban_regexp: '^[A-Z0-9]{4}[0-9]{16}$', name: 'British Virgin Islands' };
countrySpecs['XK'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Kosovo' };

@@ -11,3 +11,3 @@ /*!

* @see module:ibantools
* @version 1.5.1
* @version 1.6.0
* @license MPL-2.0

@@ -99,7 +99,7 @@ */

* @example
* // returns {bban: 'ABNA0417164300', countryCode: 'NL', countryName: 'Netherlands', valid: true}
* ibantools.extractIBAN('NL91ABNA0417164300');
* // returns {iban: 'NL91ABNA0417164300', bban: 'ABNA0417164300', countryCode: 'NL', countryName: 'Netherlands', valid: true}
* ibantools.extractIBAN('NL91 ABNA 0417 1643 00');
* @alias module:ibantools.extractIBAN
* @param {string} IBAN IBAN
* @return {ExtractIBANResult} Object {bban: string, countryCode: string, countryName: string, valid: boolean}
* @return {ExtractIBANResult} Object {iban: string, bban: string, countryCode: string, countryName: string, valid: boolean}
*/

@@ -109,2 +109,3 @@ export function extractIBAN(iban) {

iban = electronicFormatIBAN(iban);
result.iban = iban;
if (isValidIBAN(iban)) {

@@ -146,3 +147,3 @@ result.bban = iban.slice(4);

}
return iban.replace(/[^a-zA-Z0-9]/g, "").toUpperCase();
return iban.replace(/[-\ ]/g, "").toUpperCase();
}

@@ -264,15 +265,18 @@ /**

*/
countrySpecs['AD'] = { chars: 24, bban_regexp: '^[0-9]{8}[A-Z0-9]{12}$', name: 'Andorra' };
countrySpecs['AE'] = { chars: 23, bban_regexp: '^[0-9]{3}[0-9]{16}$', name: 'United Arab Emirates' };
countrySpecs['AL'] = { chars: 28, bban_regexp: '^[0-9]{8}[A-Z0-9]{16}$', name: 'Albania' };
countrySpecs['AD'] = { chars: 24, bban_regexp: '^[0-9]{8}[A-Z0-9]{12}$', name: 'Andorra' };
countrySpecs['AT'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Austria' };
countrySpecs['AZ'] = { chars: 28, bban_regexp: '^[A-Z]{4}[0-9]{20}$', name: 'Republic of Azerbaijan' };
countrySpecs['BA'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Bosnia and Herzegovina' };
countrySpecs['BE'] = { chars: 16, bban_regexp: '^[0-9]{12}$', name: 'Belgium' };
countrySpecs['BG'] = { chars: 22, bban_regexp: '^[A-Z]{4}[0-9]{6}[A-Z0-9]{8}$', name: 'Bulgaria' };
countrySpecs['BH'] = { chars: 22, bban_regexp: '^[A-Z]{4}[A-Z0-9]{14}$', name: 'Bahrain' };
countrySpecs['BE'] = { chars: 16, bban_regexp: '^[0-9]{12}$', name: 'Belgium' };
countrySpecs['BA'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Bosnia and Herzegovina' };
countrySpecs['BR'] = { chars: 29, bban_regexp: '^[0-9]{23}[A-Z]{1}[A-Z0-9]{1}$', name: 'Brazil' };
countrySpecs['BG'] = { chars: 22, bban_regexp: '^[A-Z]{4}[0-9]{6}[A-Z0-9]{8}$', name: 'Bulgaria' };
countrySpecs['CR'] = { chars: 21, bban_regexp: '^[0-9]{17}$', name: 'Costa Rica' };
countrySpecs['HR'] = { chars: 21, bban_regexp: '^[0-9]{17}$', name: 'Croatia' };
countrySpecs['BY'] = { chars: 28, bban_regexp: '^[A-Z]{4}[0-9]{4}[A-Z0-9]{16}$', name: 'Republic of Belarus' };
countrySpecs['CH'] = { chars: 21, bban_regexp: '^[0-9]{5}[A-Z0-9]{12}$', name: 'Switzerland' };
countrySpecs['CR'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Costa Rica' };
countrySpecs['CY'] = { chars: 28, bban_regexp: '^[0-9]{8}[A-Z0-9]{16}$', name: 'Cyprus' };
countrySpecs['CZ'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Czech Republic' };
countrySpecs['DE'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Germany' };
// Denmark

@@ -285,2 +289,3 @@ countrySpecs['DK'] = { chars: 18, bban_regexp: '^[0-9]{14}$', name: 'Denmark' };

countrySpecs['EE'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Estonia' };
countrySpecs['ES'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Spain' };
// Finland

@@ -305,47 +310,49 @@ countrySpecs['FI'] = { chars: 18, bban_regexp: '^[0-9]{14}$', name: 'Finland' };

// End France
// United Kingdom
countrySpecs['GB'] = { chars: 22, bban_regexp: '^[A-Z]{4}[0-9]{14}$', name: 'United Kingdom' };
// End united kingdom
countrySpecs['GE'] = { chars: 22, bban_regexp: '^[A-Z0-9]{2}[0-9]{16}$', name: 'Georgia' };
countrySpecs['DE'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Germany' };
countrySpecs['GI'] = { chars: 23, bban_regexp: '^[A-Z]{4}[A-Z0-9]{15}$', name: 'Gibraltar' };
countrySpecs['GR'] = { chars: 27, bban_regexp: '^[0-9]{7}[A-Z0-9]{16}$', name: 'Greece' };
countrySpecs['GT'] = { chars: 28, bban_regexp: '^[A-Z0-9]{24}$', name: 'Guatemala' };
countrySpecs['HR'] = { chars: 21, bban_regexp: '^[0-9]{17}$', name: 'Croatia' };
countrySpecs['HU'] = { chars: 28, bban_regexp: '^[0-9]{24}$', name: 'Hungary' };
countrySpecs['IS'] = { chars: 26, bban_regexp: '^[0-9]{22}$', name: 'Iceland' };
countrySpecs['IE'] = { chars: 22, bban_regexp: '^[A-Z0-9]{4}[0-9]{14}$', name: 'Republic of Ireland' };
countrySpecs['IL'] = { chars: 23, bban_regexp: '^[0-9]{19}$', name: 'Israel' };
countrySpecs['IQ'] = { chars: 23, bban_regexp: '^[A-Z]{4}[0-9]{15}$', name: 'Iraq' };
countrySpecs['IS'] = { chars: 26, bban_regexp: '^[0-9]{22}$', name: 'Iceland' };
countrySpecs['IT'] = { chars: 27, bban_regexp: '^[A-Z]{1}[0-9]{10}[A-Z0-9]{12}$', name: 'Italy' };
countrySpecs['JO'] = { chars: 30, bban_regexp: '^[A-Z]{4}[0-9]{4}[A-Z0-9]{18}$', name: 'Jordan' };
countrySpecs['KW'] = { chars: 30, bban_regexp: '^[A-Z]{4}[A-Z0-9]{22}$', name: 'Kuwait' };
countrySpecs['KZ'] = { chars: 20, bban_regexp: '^[0-9]{3}[A-Z0-9]{13}$', name: 'Kazakhstan' };
countrySpecs['XK'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Kosovo' };
countrySpecs['KW'] = { chars: 30, bban_regexp: '^[A-Z]{4}[A-Z0-9]{22}$', name: 'Kuwait' };
countrySpecs['LV'] = { chars: 21, bban_regexp: '^[A-Z]{4}[A-Z0-9]{13}$', name: 'Latvia' };
countrySpecs['LB'] = { chars: 28, bban_regexp: '^[0-9]{4}[A-Z0-9]{20}$', name: 'Lebanon' };
countrySpecs['LC'] = { chars: 32, bban_regexp: '^[A-Z]{4}[A-Z0-9]{24}$', name: 'Saint Lucia' };
countrySpecs['LI'] = { chars: 21, bban_regexp: '^[0-9]{5}[A-Z0-9]{12}$', name: 'Liechtenstein' };
countrySpecs['LT'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Lithuania' };
countrySpecs['LU'] = { chars: 20, bban_regexp: '^[0-9]{3}[A-Z0-9]{13}$', name: 'Luxembourg' };
countrySpecs['LV'] = { chars: 21, bban_regexp: '^[A-Z]{4}[A-Z0-9]{13}$', name: 'Latvia' };
countrySpecs['MC'] = { chars: 27, bban_regexp: '^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$', name: 'Monaco' };
countrySpecs['MD'] = { chars: 24, bban_regexp: '^[A-Z0-9]{2}[A-Z0-9]{18}$', name: 'Moldova' };
countrySpecs['ME'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Montenegro' };
countrySpecs['MK'] = { chars: 19, bban_regexp: '^[0-9]{3}[A-Z0-9]{10}[0-9]{2}$', name: 'Republic of Macedonia' };
countrySpecs['MR'] = { chars: 27, bban_regexp: '^[0-9]{23}$', name: 'Mauritania' };
countrySpecs['MT'] = { chars: 31, bban_regexp: '^[A-Z]{4}[0-9]{5}[A-Z0-9]{18}$', name: 'Malta' };
countrySpecs['MR'] = { chars: 27, bban_regexp: '^[0-9]{23}$', name: 'Mauritania' };
countrySpecs['MU'] = { chars: 30, bban_regexp: '^[A-Z]{4}[0-9]{19}[A-Z]{3}$', name: 'Mauritius' };
countrySpecs['MD'] = { chars: 24, bban_regexp: '^[A-Z0-9]{2}[A-Z0-9]{18}$', name: 'Moldova' };
countrySpecs['MC'] = { chars: 27, bban_regexp: '^[0-9]{10}[A-Z0-9]{11}[0-9]{2}$', name: 'Monaco' };
countrySpecs['ME'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Montenegro' };
countrySpecs['NL'] = { chars: 18, bban_regexp: '^[A-Z]{4}[0-9]{10}$', name: 'Netherlands' };
countrySpecs['NO'] = { chars: 15, bban_regexp: '^[0-9]{11}$', name: 'Norway' };
countrySpecs['PK'] = { chars: 24, bban_regexp: '^[A-Z0-9]{4}[0-9]{16}$', name: 'Pakistan' };
countrySpecs['PS'] = { chars: 29, bban_regexp: '^[A-Z0-9]{4}[0-9]{21}$', name: 'Palestinian territories' };
countrySpecs['PL'] = { chars: 28, bban_regexp: '^[0-9]{24}$', name: 'Poland' };
countrySpecs['PS'] = { chars: 29, bban_regexp: '^[A-Z0-9]{4}[0-9]{21}$', name: 'State of Palestine' };
countrySpecs['PT'] = { chars: 25, bban_regexp: '^[0-9]{21}$', name: 'Portugal' };
countrySpecs['QA'] = { chars: 29, bban_regexp: '^[A-Z]{4}[A-Z0-9]{21}$', name: 'Qatar' };
countrySpecs['RO'] = { chars: 24, bban_regexp: '^[A-Z]{4}[A-Z0-9]{16}$', name: 'Romania' };
countrySpecs['LC'] = { chars: 32, bban_regexp: '^[A-Z]{4}[A-Z0-9]{24}$', name: 'Saint Lucia' };
countrySpecs['SM'] = { chars: 27, bban_regexp: '^[A-Z]{1}[0-9]{10}[A-Z0-9]{12}$', name: 'San Marino' };
countrySpecs['ST'] = { chars: 25, bban_regexp: '^[0-9]{21}$', name: 'Sao Tome And Principe' };
countrySpecs['RS'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Serbia' };
countrySpecs['SA'] = { chars: 24, bban_regexp: '^[0-9]{2}[A-Z0-9]{18}$', name: 'Saudi Arabia' };
countrySpecs['RS'] = { chars: 22, bban_regexp: '^[0-9]{18}$', name: 'Serbia' };
countrySpecs['SC'] = { chars: 31, bban_regexp: '^[[A-Z]{4}[]0-9]{20}[A-Z]{3}$', name: 'Seychelles' };
countrySpecs['SE'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Sweden' };
countrySpecs['SI'] = { chars: 19, bban_regexp: '^[0-9]{15}$', name: 'Slovenia' };
countrySpecs['SK'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Slovak Republic' };
countrySpecs['SI'] = { chars: 19, bban_regexp: '^[0-9]{15}$', name: 'Slovenia' };
countrySpecs['ES'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Spain' };
countrySpecs['SE'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Sweden' };
countrySpecs['CH'] = { chars: 21, bban_regexp: '^[0-9]{5}[A-Z0-9]{12}$', name: 'Switzerland' };
countrySpecs['SM'] = { chars: 27, bban_regexp: '^[A-Z]{1}[0-9]{10}[A-Z0-9]{12}$', name: 'San Marino' };
countrySpecs['ST'] = { chars: 25, bban_regexp: '^[0-9]{21}$', name: 'Sao Tome And Principe' };
countrySpecs['SV'] = { chars: 28, bban_regexp: '^[A-Z]{4}[0-9]{20}$', name: 'El Salvador' };
countrySpecs['TL'] = { chars: 23, bban_regexp: '^[0-9]{19}$', name: 'Timor-Leste' };

@@ -355,4 +362,3 @@ countrySpecs['TN'] = { chars: 24, bban_regexp: '^[0-9]{20}$', name: 'Tunisia' };

countrySpecs['UA'] = { chars: 29, bban_regexp: '^[0-9]{6}[A-Z0-9]{19}$', name: 'Ukraine' };
countrySpecs['AE'] = { chars: 23, bban_regexp: '^[0-9]{3}[0-9]{16}$', name: 'United Arab Emirates' };
countrySpecs['GB'] = { chars: 22, bban_regexp: '^[A-Z]{4}[0-9]{14}$', name: 'United Kingdom' };
countrySpecs['VG'] = { chars: 24, bban_regexp: '^[A-Z0-9]{4}[0-9]{16}$', name: 'British Virgin Islands' };
countrySpecs['XK'] = { chars: 20, bban_regexp: '^[0-9]{16}$', name: 'Kosovo' };
{
"name": "ibantools",
"version": "1.5.1",
"version": "1.6.0",
"description": "Validation, extraction and creation of IBAN, BBAN, BIC/SWIFT numbers plus some other helpful stuff",

@@ -49,5 +49,5 @@ "keywords": [

"devDependencies": {
"@types/chai": "^4.0.4",
"@types/mocha": "^2.2.42",
"chai": "^4.1",
"@types/chai": "^4.1.2",
"@types/mocha": "^2.2.48",
"chai": "^4.1.2",
"cheerio": "^0.22",

@@ -57,21 +57,21 @@ "coveralls": "^3.0",

"gulp": "^3.9",
"gulp-mocha": "^4.3",
"gulp-mocha": "^5.0",
"gulp-rename": "^1.2",
"gulp-shell": "^0.6.3",
"gulp-typescript": "^3.2",
"gulp-shell": "^0.6.5",
"gulp-typescript": "^4.0",
"istanbul": "^0.4",
"jasmine-core": "^2.7",
"jasmine-core": "^2.99.1",
"jsdoc": "^3.5.5",
"karma": "^1.7",
"karma": "^2.0",
"karma-chrome-launcher": "^2.2",
"karma-jasmine": "^1.1",
"karma-jasmine": "^1.1.1",
"karma-requirejs": "^1.1",
"merge2": "^1.1",
"mocha": "^4.0",
"merge2": "^1.2.1",
"mocha": "^5.0",
"mocha-lcov-reporter": "^1.2.0",
"request": "^2.81",
"request": "^2.83.0",
"requirejs": "^2.3",
"run-sequence": "^2.1",
"typescript": "^2.4"
"run-sequence": "^2.2.1",
"typescript": "^2.7"
}
}

@@ -18,3 +18,3 @@ # IBANTools

For more information about IBAN/BBAN see [wikipedia page](https://en.wikipedia.org/wiki/International_Bank_Account_Number) and
[IBAN registry](https://www.swift.com/sites/default/files/resources/swift_standards_ibanregistry.pdf).
[IBAN registry](https://www.swift.com/sites/default/files/resources/iban_registry.pdf).

@@ -21,0 +21,0 @@ For more information about BIC/SWIFT see [this wikipedia page](https://en.wikipedia.org/wiki/ISO_9362).

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc