Jump to content

How Prestashop 1.7.7.4 Encryption Password works.


Skuiz

Recommended Posts

Good day,
I am trying to check how to the prestashop backoffice password encryption works.
Checking some examples as the follow:

 

<?php

namespace PrestaShop\PrestaShop\Core\Crypto;
include('config/config.inc.php');

$plaintextPassword = '123456';
$crypto = new Hashing();
$encryptedPassword = $crypto->hash($plaintextPassword, _COOKIE_KEY_);

echo 'Clear: '.$plaintextPassword.'<br />Encrypted: '.$encryptedPassword;

/* Result (example)
Clear: 123456
Encrypted: $2y$10$6b460aRLklgWblz75NAMteYXLJwjfV6a/uN8GJKgJgPDBuNhHs.ym */


?>

Seems not to work anymore with version 1.7.7.4 as i just get error when trying to test.

What is the encryption method prestashop is using? is it still md5 or hash?

I am developing an external API to modify some database info on out shop tables and i want to set a login like the one of the backoffice uses with encrypting the password for more security.

Can someone tell me how it works with this new version please?

Thanks in advance and have a good day

Edited by Skuiz (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...