Node 17 (all versions) return the following error:
https://sandbox.bluesnap.com/services/2/payment-fields-tokens failed, reason: write EPROTO 00DE371301000000:error:0A000152:SSL routines:final_renegotiate:unsafe legacy renegotiation disabled
I don't have the same issue when using Node 16.
I tried setting
fetch( // node-fetch
'https://sandbox.bluesnap.com/services/2/payment-fields-tokens',
{
agent: new https.Agent({ // fix attempt
rejectUnauthorized: false,
}),
body, // defined somewhere else
}
);
I also set NODE_TLS_REJECT_UNAUTHORIZED=0
in my .env file
and NODE_OPTIONS=--openssl-legacy-provider
and the same issue happens
I know this is probably a problem with bluesnap but a workaround would help while they resolve their issues and I can keep using the latest node version
The new version/endpoints for Bluesnap API, are OK with the latest version of NodeJS.