Credit Card Validation Algorithm
Verification Process
This article outlines procedures and algorithms for Verifying the accuracy and validity of credit card numbers. Most credit card numbers are encoded with a “Check Digit”. A check digit is a digit added to a number (either at the end or the beginning) that validates the authenticity of the number. By running the algorithm, and comparing the check digit you get from the algorithm with the check digit encoded with the credit card number, you can verify that you have correctly read all of the digits and that they make a valid combination. Its useful when a user has keyed in a credit card number (or scanned it) and you want to validate it before sending it our for debit authorization.
Here is a table outlining the major credit cards that you might want to validate.
Read the rest of this entry »