Question

I am working on client side encryption for braintree payments. With out encryption the application runs fine, but when i encrypt the card number using client side encryption (braintree-1.1.0.min.js), card number encrypts (into a long string) but i get error as response saying

(Credit card type is not accepted by this merchant account. Credit card number must be 12-19 digits. CVV must be 4 digits for American Express and 3 digits for other card types)`

I am using 4111111111111111 as card number provided on braintree site.

Brain Tree site. On server side i am usng Java. Thanks in advance for helping...

Était-ce utile?

La solution

I work at Braintree.

Generally, this error indicates you've either used the wrong key, or you've somehow modified the encrypted strings before sending them to us.

Your javascript should look something like:

var braintree = Braintree.create("MIIB...")

where the string is your client-side encryption key, which is very long -- much longer than your merchant id, public key, and private key.

If you include your code, both client-side javascript and server-side Java, I might be able to spot the specific issue you're having. Please don't include your private key if you add your server side code.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top