]> git.plutz.net Git - cgilite/commitdiff
cleaner display of activation link, include port number in activation link
authorPaul Hänsch <paul@plutz.net>
Thu, 7 Oct 2021 22:31:46 +0000 (00:31 +0200)
committerPaul Hänsch <paul@plutz.net>
Thu, 7 Oct 2021 22:31:46 +0000 (00:31 +0200)
users.sh

index c13703b418fc057adcdc936d26b515c55a3a74f7..eaf4c272a721b87642f338f3d888155fea9fd47d 100755 (executable)
--- a/users.sh
+++ b/users.sh
@@ -151,7 +151,7 @@ user_register(){
       RELEASE "$user_db"
 
       debug "Sending Activation Link:" \
-            "https://${HTTP_HOST%:*}/${_BASE}${PATH_INFO}?user_confirm=${uid}+$(session_mac "$uid")"
+            "https://${HTTP_HOST}${_BASE}${PATH_INFO}?user_confirm=${uid}+$(session_mac "$uid")"
       sendmail -t -f "$MAILFROM" <<-EOF
        From: ${MAILFROM}
        To: ${email}
@@ -161,7 +161,7 @@ user_register(){
 
        You can activate your account using this link:
 
-           https://${HTTP_HOST%:*}/${_BASE}${PATH_INFO}?user_confirm=${uid}+$(session_mac "$uid")
+           https://${HTTP_HOST}${_BASE}${PATH_INFO}?user_confirm=${uid}+$(session_mac "$uid")
 
        This registration link will expire after 24 hours.
 
@@ -220,7 +220,7 @@ user_invite(){
            >>"$user_db"
     RELEASE "$user_db"
     debug "Sending Invitation Link:" \
-          "https://${HTTP_HOST%:*}/${_BASE}${PATH_INFO}?user_confirm=${uid}+$(session_mac "$uid")"
+          "https://${HTTP_HOST}${BASE}${PATH_INFO}?user_confirm=${uid}+$(session_mac "$uid")"
     sendmail -t -f "$MAILFROM" <<-EOF
        From: ${MAILFROM}
        To: ${email}
@@ -232,7 +232,7 @@ user_invite(){
 
        You can create your account using this link:
 
-           https://${HTTP_HOST%:*}/${_BASE}${PATH_INFO}?user_confirm=${uid}+$(session_mac "$uid")
+           https://${HTTP_HOST}${_BASE}${PATH_INFO}?user_confirm=${uid}+$(session_mac "$uid")
 
        This registration link will expire after 24 hours.