I am new to Salesforce B2C. I need to use the bcrypt dependency in a Controller, but I can't get it installed on the cartridge. I am not sure if this is possible. If it is not possible. Is there a Salesforce dependency that allows me to do what the "bcrypt.hash (pass, salt)" function would do? Thanks and sorry if there is something misspelled, I don't speak too much English
You have to use sgmf-scripts: https://www.npmjs.com/package/sgmf-scripts. It's a package for SFCC that allows to build a custom SFRA cartridge app with node.js.
So you can create an app with node.js + bcrypt + sgmf-scripts. Just make sure the app is designed to override the core/default scripts where you need bcrypt.