Univention Bugzilla – Bug 34102
make-certificates.sh#move_cert: counter not reset
Last modified: 2016-06-22 13:38:04 CEST
move_cert() can potentially move multiple certificates at once. Then the counter is not reset for each certificate, leading to holes in the hashed file names. 222 move_cert () { 223 »···local count=0 228 »···for i in "$@" 235 »···»···»···while : 240 »···»···»···»···»···count=$((count + 1)) diff --git a/branches/ucs-3.2/ucs-3.2-0/base/univention-ssl/make-certificates.sh b/branches/ucs-3.2/ucs-3.2-0/base/univention-ssl/make-certificates.sh index b1a715c..fd0d39c 100755 --- a/branches/ucs-3.2/ucs-3.2-0/base/univention-ssl/make-certificates.sh +++ b/branches/ucs-3.2/ucs-3.2-0/base/univention-ssl/make-certificates.sh @@ -220,7 +220,6 @@ EOF } move_cert () { - local count=0 local OPWD=$(pwd) cd "$SSLBASE" @@ -232,6 +231,7 @@ move_cert () { local new="${SSLBASE}/${CA}/certs/$(basename "$i")" mv "$i" "$new" local hash=$(openssl x509 -hash -noout -in "$new") + local counter=0 while : do local linkname="${CA}/certs/${hash}.${count}"
Fixed by r64182 *** This bug has been marked as a duplicate of bug 38859 ***