File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed
app/code/Magento/EncryptionKey/Model/ResourceModel/Key
setup/src/Magento/Setup/Model Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -108,6 +108,9 @@ public function changeEncryptionKey($key = null)
108
108
}
109
109
110
110
if (null === $ key ) {
111
+ // md5() here is not for cryptographic use. It used for generate encryption key itself
112
+ // and do not encrypt any passwords
113
+ // phpcs:ignore Magento2.Security.InsecureFunction
111
114
$ key = md5 ($ this ->random ->getRandomString (ConfigOptionsListConstants::STORE_KEY_RANDOM_STRING_SIZE ));
112
115
}
113
116
$ this ->encryptor ->setNewKey ($ key );
Original file line number Diff line number Diff line change @@ -37,6 +37,9 @@ public function __construct(Random $random)
37
37
*/
38
38
public function generate ()
39
39
{
40
+ // md5() here is not for cryptographic use. It used for generate encryption key itself
41
+ // and do not encrypt any passwords
42
+ // phpcs:ignore Magento2.Security.InsecureFunction
40
43
return md5 ($ this ->getRandomString ());
41
44
}
42
45
You can’t perform that action at this time.
0 commit comments