File tree Expand file tree Collapse file tree 7 files changed +8
-8
lines changed
Expand file tree Collapse file tree 7 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -43,6 +43,7 @@ All notable changes to this project will be documented in this file.
4343- Changed WordPress name in Webapp installer (#1074 )
4444- Add a free disk space validation during backup routine (#1115 )
4545- Removed PHP validation SSH keys allowing support other types then RSA / DSA
46+ - Fixed an issue which cause wrong password generation (#1184 )
4647
4748
4849## [ 1.2.3] - Service Release
Original file line number Diff line number Diff line change 99# Variable&Function #
1010# ----------------------------------------------------------#
1111
12- keygen ()
13- {
12+ keygen () {
1413 < /dev/urandom tr -dc _A-Z-a-z-0-9 | head -c${1:- 32} ; echo ;
1514}
1615KEYS=" $HESTIA /data/keys/"
Original file line number Diff line number Diff line change @@ -186,12 +186,12 @@ generate_password() {
186186 matrix=$1
187187 length=$2
188188 if [ -z " $matrix " ]; then
189- matrix=[:alnum:]
189+ matrix=" A-Za-z0-9 "
190190 fi
191191 if [ -z " $length " ]; then
192192 length=10
193193 fi
194- cat /dev/urandom | tr -dc $matrix | head -c$length
194+ head /dev/urandom | tr -dc $matrix | head -c$length
195195}
196196
197197# Package existence check
Original file line number Diff line number Diff line change @@ -107,7 +107,7 @@ download_file() {
107107
108108# Defining password-gen function
109109gen_pass () {
110- cat /dev/urandom | tr -dc [:alnum:] | head -c16
110+ head /dev/urandom | tr -dc A-Za-z0-9 | head -c 16
111111}
112112
113113# Defining return code check function
Original file line number Diff line number Diff line change @@ -89,7 +89,7 @@ download_file() {
8989
9090# Defining password-gen function
9191gen_pass () {
92- cat /dev/urandom | tr -dc [:alnum:] | head -c16
92+ head /dev/urandom | tr -dc A-Za-z0-9 | head -c 16
9393}
9494
9595# Defining return code check function
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ load 'test_helper/bats-file/load'
66
77
88function random() {
9- cat /dev/urandom | tr -dc [:digit:] | head -c$1
9+ head /dev/urandom | tr -dc A-Za-z0-9 | head -c$1
1010}
1111
1212function setup() {
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ V_TEST="$HESTIA/test"
77
88# Define functions
99random () {
10- cat /dev/urandom | tr -dc [:digit:] | head -c$1
10+ head /dev/urandom | tr -dc A-Za-z0-9 | head -c$1
1111}
1212
1313echo_result () {
You can’t perform that action at this time.
0 commit comments