From b18e735af1bd4ad285cd197f76745f496d0b88c2 Mon Sep 17 00:00:00 2001 From: Mykola Malkov Date: Tue, 24 Mar 2020 12:53:47 +0200 Subject: [PATCH] TT#76658 Move default administrator pass from MD5 to bcrypt The using of MD5() for password was outdated and there is an appropriate warning in ngcp-status. So change the default password to salted one. Unfortunately Mariadb doesn't provide bcrypt() function so use the prepared string. Change-Id: I668e32265c5e3f0f4907ddba0f9546fafdb8acdd --- db_scripts/diff/15587.up | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 db_scripts/diff/15587.up diff --git a/db_scripts/diff/15587.up b/db_scripts/diff/15587.up new file mode 100644 index 00000000..42bf2408 --- /dev/null +++ b/db_scripts/diff/15587.up @@ -0,0 +1,10 @@ +USE billing; + +UPDATE admins + SET + saltedpass = 'AtAFGhepIuEaQ.dSfdJ6b.$TNfqchYY76HTh2FAgD3l4r9JFYmFr9i', + md5pass = NULL + WHERE + login = 'administrator' + AND md5pass = MD5('administrator') + AND saltedpass IS NULL;