1 3304ae77 2024-07-06 continue #!/bin/sh
3 f3ee4dd5 2024-09-11 continue URL=$(cat -)
4 f3ee4dd5 2024-09-11 continue URL_TAIL=$(echo $URL | awk -F "/" '{print $NF}')
6 f3ee4dd5 2024-09-11 continue if [ "$URL_TAIL" = "auth" ]; then
7 f3ee4dd5 2024-09-11 continue if [ -z "${VGI_CERT_HASH}" ]; then
8 f3ee4dd5 2024-09-11 continue echo "60 Certificate required\r"
12 f3ee4dd5 2024-09-11 continue echo "20 text/gemini\r"
13 f3ee4dd5 2024-09-11 continue echo "# VGI demo (authenticated)\r"
14 f3ee4dd5 2024-09-11 continue echo "\`\`\`\r"
15 f3ee4dd5 2024-09-11 continue echo "VGI_CERT_HASH=$VGI_CERT_HASH\r"
16 f3ee4dd5 2024-09-11 continue echo "\`\`\`\r"
20 f3ee4dd5 2024-09-11 continue echo "20 text/gemini\r"
21 6ed61a2e 2024-07-08 continue echo "# VGI demo\r"
22 3304ae77 2024-07-06 continue echo "\r"
23 6ed61a2e 2024-07-08 continue echo "Requested URL: \r"
24 f3ee4dd5 2024-09-11 continue echo "=> $URL"