Cracking Credit Card Code

Posted: May 24, 2012 in Knowledge Base
Tags: , , ,

Our e-Commerce site need detect whether a Credit is MasterCard or Visa. It’s unbelievable easy.

Below table is from Wikipedia: http://en.wikipedia.org/wiki/Bank_card_number

Issuing network IIN ranges Active Length Validation
American Express 34, 37 Yes 15 Luhn algorithm
Bankcard 5610, 560221-560225 No 16 Luhn algorithm
China UnionPay 62 Yes 16-19 no validation
Diners Club Carte Blanche 300-305 Yes 14 Luhn algorithm
Diners Club enRoute 2014, 2149 No 15 no validation
Diners Club International 36 Yes 14 Luhn algorithm
Diners Club United States & Canada 54, 55 Yes 16 Luhn algorithm
Discover Card 6011, 622126-622925, 644-649, 65 Yes 16 Luhn algorithm
InstaPayment 637-639 Yes 16 Luhn algorithm
JCB 3528-3589 Yes 16 Luhn algorithm
Laser 6304, 6706, 6771, 6709 Yes 16-19 Luhn algorithm
Maestro 5018, 5020, 5038, 6304, 6759, 6761, 6762, 6763 Yes 12-19 Luhn algorithm
MasterCard 51-55 Yes 16 Luhn algorithm
Solo 6334, 6767 No 16, 18, 19 Luhn algorithm
Switch 4903, 4905, 4911, 4936, 564182, 633110, 6333, 6759 No 16, 18, 19 Luhn algorithm
Visa 4 Yes 13, 16 Luhn algorithm
Visa Electron 4026, 417500, 4508, 4844, 4913, 4917 Yes 16 Luhn algorithm

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s