Adyen / adyen-cse-web

[DEPRECATED] Client-side encryption on JavaScript
MIT License
15 stars 39 forks source link

Webpack loading & roboto font #50

Closed Nainterceptor closed 5 years ago

Nainterceptor commented 7 years ago

Hello,

Can I require adyen-cse-js and take only the javascript sdk ? Currently, I do something like that :

const adyen = require('adyen-cse-js');
const encryptor = adyen.createEncryption(publicEncryptionKey);
const cseToken = encryptor.encrypt(Object.assign({ generationtime }, card));

Then, my website is loading Roboto font, from your javascript :( I'm using VueJs with Nuxt, in the same way, when server side rendering append, adyen try to find navigator var, but it's not available. Why this variable is needed ? Maybe the same reason than css is loading :/

Thanks, Gaël

ArnoudAdyen commented 7 years ago

Hi,

Apology for being so amazingly late. The font loading is part of device fingerprinting. It makes little sense to run this server-side. Or at minimum render the generated fingerprinting irrelevant for fraud prevention purposes.

The navigator dependency is used in the encryption library as part of the JavaScript that does the encryption of card data. See http://www-cs-students.stanford.edu/~tjw/jsbn/

Please note that this JavaScript should not be executed server-side as the card data should not reach your servers.

Best,

Arnoud