From f5214cf64eee3fb1a6c576ef492d95054efa77d0 Mon Sep 17 00:00:00 2001 From: Disassembler Date: Fri, 8 Dec 2017 21:34:22 +0100 Subject: [PATCH] Don't allow + in Mifos X admin password --- mifosx.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mifosx.sh b/mifosx.sh index 011db2b..37cdc07 100755 --- a/mifosx.sh +++ b/mifosx.sh @@ -28,7 +28,7 @@ rm -f /tmp/mifosx-schemapwd.sql # Update admin account export MIFOSX_ADMIN_USER=admin export MIFOSX_ADMIN_EMAIL=admin@example.com -export MIFOSX_ADMIN_PWD=$(head -c 12 /dev/urandom | base64) +export MIFOSX_ADMIN_PWD=$(head -c 12 /dev/urandom | base64 | tr -d "+") export MIFOSX_ADMIN_HASH=$(echo -n "${MIFOSX_ADMIN_PWD}{1}" | sha256sum | awk '{print $1}') envsubst <${SOURCE_DIR}/tmp/mifosx-adminpwd.sql >>/srv/mifosx/fineract-provider/WEB-INF/classes/sql/migrations/core_db/V3__mifosx-permissions-and-authorisation-utf8.sql