Sync from server

Signed-off-by: Aleksandar 'The Cobra' Widulski <thecobra@riseup.net>
This commit is contained in:
Aleksandar 'The Cobra' Widulski 2022-06-01 20:15:18 -04:00
parent 7aba073610
commit 559fcc1a54
Signed by: cobra
GPG Key ID: 4FD8F812083FF6F9
14 changed files with 328 additions and 311 deletions

View File

@ -2,19 +2,19 @@
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="style.css">
<link rel="stylesheet" href="/style.css">
<title>~vern admins</title>
</head>
<body>
<!--#include file="nav" -->
<!--#include file="nav" -->
<h1>Admins</h1>
<p>This is the list of admins of ~vern. Anyone claiming to be an admin that isn't on this list is lying. This list may be updated at any point, so please check it to see if someone is an admin.</p>
<ul>
<li>Arya (aryak) - Maintains servers and hosts the offsite backups</li>
<li>neopenk - Pays for VPS and vern.cc domain, basically owns ~vern</li>
<li>Aleksandar (cobra) - Hosts the main tilde server</li>
<li>Daksh (daksh) - Maintains website</li>
<li>Neo (neopenk) - Pays for VPS and vern.cc domain, basically owns ~vern</li>
<li>Aleksandar (cobra) - Hosts the main tilde server</li>
<li>Daksh (daksh) - Webmaster</li>
</ul>
<!--#include file="footer" -->
<!--#include file="footer" -->
</body>
</html>

View File

@ -1,169 +0,0 @@
#!/bin/bash
# Author: (c) Colas Nahaboo http://colas.nahaboo.net with a MIT License.
# See https://github.com/ColasNahaboo/cgibashopts
# Uses the CGI env variables REQUEST_METHOD CONTENT_TYPE QUERY_STRING
export CGIBASHOPTS_RELEASE=4.1.0
export CGIBASHOPTS_VERSION="${CGIBASHOPTS_RELEASE%%.*}"
cr=$'\r'
nl=$'\n'
export FORMS=
export FORMFILES=
export FORMQUERY=
# parse options
uploads=true
tmpfs=/tmp
OPTIONS='nd:'
OPTIND=1
while getopts "${OPTIONS}" _o;do
case "$_o" in
n) uploads=false;;
d) tmpfs="$OPTARG";;
*) echo "unknown option: $_o"; exit 1;;
esac
done
shift $((OPTIND-1))
if "$uploads"; then
export CGIBASHOPTS_DIR="$tmpfs/cgibashopts-files.$$"
CGIBASHOPTS_TMP="$CGIBASHOPTS_DIR.tmp"
cgibashopts_clean() {
[ -n "$CGIBASHOPTS_DIR" ] && [ -d "$CGIBASHOPTS_DIR" ] && rm -rf "$CGIBASHOPTS_DIR"
}
trap cgibashopts_clean 0
else
CGIBASHOPTS_TMP=/dev/null
fi
# emulates bashlib param function. -f operate on uploaded file paths
param () {
if [ "$1" = -f ]; then
shift
if [ $# -eq 0 ]; then echo "$FORMFILES"
elif [ $# -eq 1 ]; then eval echo "\$FORMFILE_$1"
else declare -x "FORMFILE_$1=$*"
fi
else
if [ $# -eq 0 ]; then echo "$FORMS"
elif [ $# -eq 1 ]; then eval echo "\$FORM_$1"
else declare -x "FORM_$1=$*"
fi
fi
}
# decodes the %XX url encoding in $1, same as urlencode -d but faster
# removes carriage returns to force unix newlines, converts + into space
urldecode() {
local v="${1//+/ }" d r=''
while [ -n "$v" ]; do
if [[ $v =~ ^([^%]*)%([0-9a-fA-F][0-9a-fA-F])(.*)$ ]]; then
eval d="\$'\x${BASH_REMATCH[2]}'"
[ "$d" = "$cr" ] && d=
r="$r${BASH_REMATCH[1]}$d"
v="${BASH_REMATCH[3]}"
else
r="$r$v"
break
fi
done
echo "$r"
}
# the reverse of urldecode above
urlencode() {
local length="${#1}" i c
for (( i = 0; i < length; i++ )); do
c="${1:i:1}"
case $c in
[a-zA-Z0-9.~_-]) echo -n "$c" ;;
*) printf '%%%02X' "'$c" ;;
esac
done
}
if [ "${REQUEST_METHOD:-}" = POST ]; then
if [[ ${CONTENT_TYPE:-} =~ ^multipart/form-data\;[[:space:]]*boundary=([^\;]+) ]]; then
sep="--${BASH_REMATCH[1]}"
OIFS="$IFS"; IFS=$'\r'
while read -r line; do
if [[ $line =~ ^Content-Disposition:\ *form-data\;\ *name=\"([^\"]+)\"(\;\ *filename=\"([^\"]+)\")? ]]; then
var="${BASH_REMATCH[1]}"
val="${BASH_REMATCH[3]}"
[[ $val =~ [%+] ]] && val=$(urldecode "$val")
type=
read -r line
while [ -n "$line" ]; do
if [[ $line =~ ^Content-Type:\ *text/plain ]]; then
type=txt
elif [[ $line =~ ^Content-Type: ]]; then # any other type
type=bin
fi
read -r line
done
if [ "$type" = bin ]; then # binary file upload
# binary-read stdin till next step
sed -n -e "{:loop p; n;/^$sep/q; b loop}" >$CGIBASHOPTS_TMP
[ $CGIBASHOPTS_TMP != /dev/null ] && \
truncate -s -2 $CGIBASHOPTS_TMP # remove last \r\n
elif [ "$type" = txt ]; then # text file upload
lp=
while read -r line; do
[[ $line =~ ^"$sep" ]] && break
echo -n "$lp$line"
lp="$nl"
done >$CGIBASHOPTS_TMP
else # string, possibly multi-line
val=
while read -r line; do
[[ $line =~ ^"$sep" ]] && break
val="$val${val:+$nl}${line}"
done
fi
if [ -n "$type" ]; then
if [ $CGIBASHOPTS_TMP != /dev/null ]; then
if [ -n "$val" ]; then
# a file was uploaded, even empty
[ -n "$FORMFILES" ] || mkdir -p "$CGIBASHOPTS_DIR"
FORMFILES="$FORMFILES${FORMFILES:+ }$var"
declare -x "FORMFILE_$var=$CGIBASHOPTS_DIR/${var}"
mv $CGIBASHOPTS_TMP "$CGIBASHOPTS_DIR/${var}"
else
rm -f $CGIBASHOPTS_TMP
fi
fi
fi
FORMS="$FORMS${FORMS:+ }$var"
declare -x "FORM_$var=$val"
fi
done
s="${QUERY_STRING:-}"
IFS="$OIFS"
unset OIFS
else
stdin=$(cat) # indirection to avoid issues with terminating newlines
s="${stdin}&${QUERY_STRING:-}"
unset stdin
fi
else
s="${QUERY_STRING:-}"
fi
# regular (no file uploads) arguments processing
if [[ $s =~ = ]]; then # modern & (or ;) separated list of key=value
while [[ $s =~ ^([^=]*)=([^\&\;]*)[\;\&]*(.*)$ ]]; do
var="${BASH_REMATCH[1]//[^a-zA-Z_0-9]/}"
val="${BASH_REMATCH[2]}"
s="${BASH_REMATCH[3]}"
if [[ $var =~ ^[_[:alpha:]] ]]; then # ignore invalid vars
[[ $val =~ [%+] ]] && val=$(urldecode "$val")
FORMS="$FORMS${FORMS:+ }$var"
declare -x "FORM_$var=$val"
fi
done
else # legacy indexed search
FORMQUERY=$(urldecode "$s")
fi
# clean up our local variables
unset sep line var val type s lp

View File

@ -1,50 +0,0 @@
#!/usr/bin/env bash
source ./cgibashopts
echo "Content-type:text/html; charset=UTF-8\n\n"
echo ""
adminmails='aryak@vern.cc cobra@vern.cc neopenk@vern.cc'
echo '<link rel="stylesheet" href="/style.css">'
echo '<title>~vern admins</title>'
if [[ $FORM_username =~ ^([a-z_][a-z0-9_]{0,30})$ ]] && ! id $FORM_username &> /dev/null; then
echo "<br>Valid Username <b> $FORM_username </b><br>"
VALID_USERNAME=1
else
id $FORM_username &> /dev/null &&
echo "<br>Username already taken, try another one and resubmit the form<br>" ||
echo "<br>Invalid Username, please go back and resubmit the form<br>"
VALID_USERNAME=0
fi
if [[ "$FORM_email" =~ ^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,4}$ ]]; then
VALID_EMAIL=1
echo "<br>Valid email address <b> $FORM_email</b><br>"
else
VALID_EMAIL=0
echo "<br>Invalid email address, please go back and resubmit the form<br>"
fi
if ! <<< "$FORM_ssh" ssh-keygen -l -f - &> /dev/null; then
echo "<br>Invalid SSH Key(s), please go back and resubmit the form<br>"
VALID_SSH=0
else
echo "<br>Valid SSH Key(s)<br>"
VALID_SSH=1
fi
echo "<br> Services requested: Tilde Email $FORM_git $FORM_fedi $FORM_matrix<br>"
set | grep ^FORM > /home/ak/test
sshurl=$(echo $FORM_ssh | curl -s -F'file=@-;' https://envs.sh)
if [[ $VALID_EMAIL == 1 ]] && [[ $VALID_USERNAME == 1 ]] && [[ $VALID_SSH == 1 ]]; then
echo "<br>Signup Request has been submitted. More information will be sent to $FORM_email after it is approved.<br>"
echo '<a href=/index.html>🔙 Go home</a>'
MAILNUM=$RANDOM
echo "Subject: New membership request from $FORM_username <$FORM_email>" > /tmp/membershipemail$MAILNUM
echo "Hello Administrators," >> /tmp/membershipemail$MAILNUM
echo "There has been a new membership request. Please look at the details below and decide if this is worth approving" >> /tmp/membershipemail$MAILNUM
echo "SSH Keys: $sshurl" >> /tmp/membershipemail$MAILNUM
echo "Services requested: $FORM_git $FORM_fedi $FORM_matrix" >> /tmp/membershipemail$MAILNUM
printf "\nReason for join request: \n $FORM_reason\n" >> /tmp/membershipemail$MAILNUM
cat /tmp/membershipemail$MAILNUM | s-nail -v -r "mememail@vern.cc" -s "$(head -n1 /tmp/membershipemail$MAILNUM | cut -c9-)" $adminmails &> /dev/null
else
echo '<h1> <a href=/signup>some details were wrong/missing. please check and redo the form</a> </h1>'
fi

16
errors/404.html Normal file
View File

@ -0,0 +1,16 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="/style.css">
<title>404 Not Found</title>
</head>
<body>
<!--#include file="/nav" -->
<h1>404 Not Found</h1>
The page you are trying to reach either does not exist or you do not have permission to view it.<br>
Contact an <a href=/admins>admin</a> if this is a mistake.<br><br>
<a href=/>Go Home</a><br>
<!--#include file="/footer" -->
</body>
</html>

16
errors/503.html Normal file
View File

@ -0,0 +1,16 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="/style.css">
<title>503 Service Unavailable</title>
</head>
<body>
<!--#include file="/nav" -->
<h1>503 Service Unavailable</h1>
This service is unavailable.<br>
Contact an <a href=/admins>admin</a> if this is a mistake.<br><br>
<a href=/>Go Home</a><br>
<!--#include file="/footer" -->
</body>
</html>

View File

@ -1,5 +1,5 @@
<footer>
<hr>
<p>Made with ❤️ by ~vern team</p>
<p>Content on vern.cc is licensed under CC-BY-SA-4.0 unless specified</p>
<hr>
<p>Made with ❤️ by ~vern team</p>
<p>Content on vern.cc is licensed under CC-BY-SA-4.0 unless specified</p>
</footer>

View File

@ -2,37 +2,36 @@
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="style.css">
<link rel="stylesheet" href="/style.css">
<title>~vern</title>
</head>
<body>
<!--#include file="nav" -->
<!--#include file="nav" -->
<h1>Welcome to ~vern!</h1>
<p>~vern is a non-commercial shared GNU/Linux system. All our servers run Debian GNU/Linux with the non-free repos disabled. We are also aiming to become a member of the <a href=//tildeverse.org>Tildeverse</a> after we meet the requirements</p>
<p>~vern is a non-commercial shared GNU/Linux system. All our servers run Debian GNU/Linux with the non-free repos disabled. We are also aiming to become a member of the <a href=//tildeverse.org>Tildeverse</a> after we meet the requirements</p>
<h2>Services</h2>
<p>We host many services, most are available for the public.</p>
<p>Some are private to prevent people from abusing the services.</p>
<p>You can get access to these services by asking any of the <a href=/admins>admins</a>.</p>
<b> Public Services </b>
<p>We host many services, most are available for the public.</p>
<p>Some are private to prevent people from abusing the services.</p>
<p>You can get access to these services by <a href=/register.php>signing up</a>.</p>
<ul>
<li><a href=//pb.vern.cc>Privatebin</a></li>
<li><a href=//git.vern.cc>Gitea</a></li>
<li><a href=//lbry.vern.cc>Librarian</a></li>
<li><a href=//inv.vern.cc>Invidious</a></li>
<li><a href=//lr.vern.cc>Libreddit</a></li>
<li><a href=//tl.vern.cc>Simplytranslate</a></li>
</ul>
<b> Private Services </b>
<ul>
<li><a href=//nc.vern.cc>Nextcloud</a></li>
<li><a href=//mail.vern.cc>Email</a></li>
<li><a href=//mtrx.vern.cc>Matrix</a></li>
<li><a href=//pb.vern.cc>Privatebin</a></li>
<li><a href=//git.vern.cc>Gitea</a></li>
<li><a href=//lbry.vern.cc>Librarian</a></li>
<li><a href=//inv.vern.cc>Invidious</a></li>
<li><a href=//lr.vern.cc>Libreddit</a></li>
<li><a href=//tl.vern.cc>Simplytranslate</a></li>
<li><a href=//rimgo.vern.cc>Rimgo</a></li>
<li><a href=//quora.vern.cc>Quetre</a></li>
<li><a href=//lt.vern.cc>LibreTranslate</a></li>
<li><a href=//nc.vern.cc>Nextcloud</a></li>
<li><a href=//mail.vern.cc>Email</a></li>
<li><a href=//mtrx.vern.cc>Matrix</a></li>
</ul>
<h2>Community</h2>
<ul>
<li><a href="//matrix.to/#/#vern:vern.cc" target="_blank">Matrix</a></li>
</ul>
<!--#include file="footer" -->
<!--#include file="footer" -->
</body>
</html>

13
legal-privacy.html Normal file
View File

@ -0,0 +1,13 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="/style.css">
<title>~vern admins</title>
</head>
<body>
<!--#include file="nav" -->
<p>Coming soon :P</p>
<!--#include file="footer" -->
</body>
</html>

View File

@ -1,11 +1,11 @@
<link rel=stylesheet href="style.css">
<link rel=stylesheet href="/style.css">
<header>
<a href="https://vern.cc"><img src="logo.png" alt="logo" class="navlogo"></a>
<nav>
<a href="signup">SignUp</a>
<a href="wiki">Wiki</a>
<a href="rules">Rules</a>
<a href="privpol">PrivacyPolicy</a>
</nav>
</header>
<hr>
<a href="https://vern.cc"><img src="/logo.png" alt="logo" class="navlogo"></a>
<nav>
<a href="/register.php">SignUp</a>
<a href="/wiki">Wiki</a>
<a href="/rules">Rules</a>
<a href="/privpol">PrivacyPolicy</a>
</nav>
</header>
<hr>

14
privpol.html Normal file
View File

@ -0,0 +1,14 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="/style.css">
<title>~vern admins</title>
</head>
<body>
<!--#include file="nav" -->
<h1>Privacy Statement</h1>
<p>The only circumstances in which we collect and store data from our users is when such information is directly provided to us, i.e. when one registers to any of our services. Any automatically generated information (log files) that contains personal user information such as IP addresses, locations, or full names is to be deleted from our servers in at most 48 hours. If you decide that you want any of your accounts with us to be closed, send an e-mail to: <code>deletion (AT SMYBOL) vern (PERIOD) cc</code>. Any associated personaly information will be deleted from our servers in up to 96 hours. A full legalese privacy policy can be found <a href="/legal-privacy">here</a>.</p>
<!--#include file="footer" -->
</body>
</html>

201
register.php Normal file
View File

@ -0,0 +1,201 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="/style.css">
<title>~vern registration</title>
</head>
<body>
<!--#include file="nav" -->
<?php
function sanitize($str) {
$str = trim($str);
$str = stripslashes($str);
$str = htmlspecialchars($str);
return $str;
}
$success = false;
$username = $passowrd0 = $password1 = $email = $ssh = $reason =
$username_err = $password0_err = $password1_err = $email_err = $ssh_err = $reason_err =
$request_ip = '';
$username_re = '/^[a-z_][a-z0-9_]{0,30}$/';
if ($_SERVER['REQUEST_METHOD'] == "POST") {
$request_ip = $_SERVER['REMOTE_ADDR'];
if (!empty($_POST['username'])) {
if (preg_match($username_re, $_POST['username']) === 1) {
$ret = 0;
exec("bash -c 'id " . $_POST['username'] . " &> /dev/null; printf %d $?'", $blank, $ret);
if ($ret == 0) {
if (!file_exists("/var/tmp/register/" . sanitize($_POST['username'])))
$username = sanitize($_POST['username']);
else $username_err = "A request for the username " . $_POST['username'] . " exists already. Try again later or choose a different username.";
}
else $username_err = "Username is already in use";
unset($ret);
} else {
$username_err = "Invalid username. Username must be a valid GNU/Linux username (match $username_re)";
}
} else {
$username_err = "Username is required";
}
if (!empty($_POST['password0'] || !empty($_POST['password1']))) {
if ($_POST['password1'] === $_POST['password0']) {
$password0 = $_POST['password0'];
$password1 = $_POST['password1'];
} else {
$password0_err = $password1_err = "Passwords do not match";
}
} else {
$password0_err = $password1_err = "Password is required";
}
if (!empty($_POST['email'])) {
if (filter_var(sanitize($_POST['email']), FILTER_VALIDATE_EMAIL)) {
$email = sanitize($_POST['email']);
} else {
$email_err = "Invalid E-mail";
}
} else {
$email_err = "E-mail is required";
}
if (!empty($_POST['ssh'])) {
$ret = shell_exec("bash -c 'ssh-keygen -lf - <<< \"" . escapeshellcmd($_POST['ssh']) . "\" &> /dev/null ; printf %d $?'");
if ($ret == 0) {
$ssh = $_POST['ssh'];
} else {
$ssh_err = "Not a valid SSH public key";
}
unset($ret);
} else {
$ssh_err = "Public key is required";
}
if (!empty($_POST['joinreason'])) {
$reason = $_POST['joinreason'];
} else {
$reason_err = "Join reason is required";
}
if (empty($username_err . $password0_err . $password1_err . $email_err . $ssh_err . $reason_err))
$success = true;
}
if (!$success) {
?>
<h1>Sign Up</h1>
<span class="red">* Required field</span>
<form method="post" action="' . htmlspecialchars($_SERVER["PHP_SELF"]) . '">
Username:
<input type="text" name="username" value="<?php echo $username; ?>">
<span class="red">* <?php echo $username_err; ?></span><br>
Password:
<input type="password" name="password0">
<span class="red">* <?php echo $password0_err; ?></span><br>
Password:
<input type="password" name="password1">
<span class="red">* <?php echo $password1_err; ?></span><br>
E-mail <span class="red">* <?php echo $email_err; ?></span><br>
<input type="text" name="email" value="<?php echo $email; ?>"><br>
SSH public keys (newline separated) <span class="red">* <?php echo $ssh_err; ?></span><br>
<textarea name="ssh" rows="3" cols="50" value="<?php echo $ssh; ?>"></textarea><br>
Why do you want to join? <span class="red">* <?php echo $reason_err; ?></span><br>
<textarea name="joinreason" rows="8" cols="50" value="<?php echo $reason; ?>"></textarea><br>
<br>
What services do you want? (You can always request an account later)<br>
<input type="checkbox" id="pubnix" name="pubnix" value="Pubnix" disabled checked>
<label for="pubnix">Pubnix and E-mail</label><br>
<input type="checkbox" id="matrix" name="matrix" value="Matrix" checked>
<label for="matrix">Matrix</label><br>
<input type="checkbox" id="fedi" name="fedi" value="Mastodon" checked>
<label for="fedi">Fediverse (Mastodon)</label><br>
<input type="checkbox" id="git" name="git" value="Gitea" checked>
<label for="gitea">Gitea</label><br>
<input type="checkbox" id="jitsi" name="jitsi" value="Jitsi" checked>
<label for="jitsi">Jitsi</label><br>
<!-- <input type="checkbox" id="nextcloud" name="nextcloud" value="Nextcloud">
<label for="nextcloud">Nextcloud</label><br> -->
<span><input type="submit" value="Submit" style="width:100px;height:40px;font-size:20px"></span>
</form>
<br><b>By signing up, you agree to the ~vern <a href=/rules>rules</a> and <a href=/privpol>privacy policy</a>. Thanks for using ~vern</b><br>
<?php
} else {
?>
<meta http-equiv="refresh" content="3;url=https://vern.cc/" />
<h1>Thank you for signing up.</h1>
An admin will review your request, and an e-mail will be sent if your registration is successful.
<br>
You will be redirected back home in 3 seconds.
<?php
if (isset($_POST['matrix'])) $use_matrix = true;
if (isset($_POST['fedi'])) $use_fedi = true;
if (isset($_POST['git'])) $use_git = true;
if (isset($_POST['jitsi'])) $use_jitsi = true;
if (isset($_POST['nextcloud'])) $use_nextcloud = true;
$to = "root@vern.cc";
$subject = "New registration request from " . $username;
$message = "Hello Administrators,\nSomeone has requested a membership. Please view the details below and decide if it is worth approving.\n\nSSH keys:\n" . $ssh . "\n\nRequested username: $username\nRequested services: Tilde";
if ($use_matrix) $message .= ", Matrix";
if ($use_fedi) $message .= ", Mastodon";
if ($use_git) $message .= ", Gitea";
if ($use_jitsi) $message .= ", Jitsi";
if ($use_nextcloud) $message .= ", Nextcloud";
$message .= ".\nJoin reason:\n" . $reason . "\n\n\nTo accept this request, run this command as root:\n/root/bin/accept " . $username . "\nTo deny this request, run this command as root:\n/root/bin/deny " . $username . "\n";
$contents = "#!/usr/bin/env -S bash -e\n\n# This is registration script for " . $username . "\n# This script was automatically generated by https://vern.cc" . htmlspecialchars($_SERVER['PHP_SELF']). "\n";
$contents .= "\n~/bin/mktuser \"" . $username . "\" \"" . $password0 . "\" <<< \"" . $_POST['ssh'] . "\"\n";
if ($use_matrix) $contents .= "\n~/bin/mkmuser \"" . $username . "\" \"" . $password0 . "\"\n";
if ($use_fedi) $contents .= "~/bin/mkfuser \"" . $username . "\" \"" . $email . "\"\n";
if ($use_git) $contents .= "~/bin/mkguser \"" . $username . "\" \"" . $password0 . "\" \"" . $email . "\"\n";
if ($use_jitsi) $contents .= "~/bin/mkjuser \"" . $username . "\" \"" . $password0 . "\"\n";
// if ($use_nextcloud) $contents .= "~/bin/mknuser \"" . $username . "\"\n";
$contents .= "rm -f $0\n";
$filename = "/var/tmp/register/" . $username;
$handle = fopen($filename, "w+");
chmod($filename, 0600);
unset($filename);
fwrite($handle, $contents);
fclose($handle);
$from = "mememail@vern.cc";
$headers = "From: " . $from . "\n";
$headers .= "MIME-Version: 1.0\n";
$headers .= "Content-type: text/plain\n";
$headers .= "Cc: Aleksandar <cobra@vern.cc>\n";
$headers .= "Cc: Arya <aryak@vern.cc>\n";
$headers .= "Cc: Neo <neopenk@vern.cc>\n";
mail($to, $subject, $message, $headers);
}
?>
<!--#include file="footer" -->
</body>
</html>

View File

@ -2,27 +2,28 @@
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="style.css">
<link rel="stylesheet" href="/style.css">
<title>~vern rules</title>
</head>
<body>
<!--#include file="nav" -->
<b> Rules </b>
<ul>
<li>Anything illegal under American (Main tilde) or Polish (VPS) Law</li>
<li>Harassing any person, using the services provided by ~vern will result in a ban</li>
<li>Even though many members of ~vern support piracy, piracy is <b>Illegal</b>. Piracy can be discussed but you <b>can not</b> share links to or store pirated content on ~vern</li>
<li>Deliberately trying to disrupt the services of ~vern will result in a permanent ban</li>
<li>Distributing or storing pornography of any genre and medium on ~vern is not allowed and users found to be storing pornography will be permanently banned from the service.</li>
</ul>
<b> Guidelines </b>
<ul>
<li>Do not promote violence, racism and/or discrimination towards other people of other ethnical backgrounds or sexual orientation</li>
</ul>
<!--#include file="nav" -->
<h1> Rules </h1>
<h2> Hard Rules </h2>
<ul>
<li>Anything illegal under American (Main tilde) or Polish (VPS) Law</li>
<li>Harassing any person, using the services provided by ~vern will result in a ban</li>
<li>Even though many members of ~vern support piracy, piracy is <b>Illegal</b>. Piracy can be discussed but you <b>can not</b> share links to or store pirated content on ~vern</li>
<li>Deliberately trying to disrupt the services of ~vern will result in a permanent ban</li>
<li>Distributing or storing pornography of any genre and medium on ~vern is not allowed and users found to be storing pornography will be permanently banned from the service.</li>
</ul>
<h2> Guidelines </h2>
<ul>
<li>Do not promote violence, racism and/or discrimination towards other people of other ethnical backgrounds or sexual orientation</li>
</ul>
If you find any users violating these guidelines, please send us a screenshot on #abuse:vern.cc.
If you find any users violating these guidelines, please send us a screenshot on #abuse:vern.cc.
Thanks for being part of ~vern!
<!--#include file="footer" -->
Thanks for being part of ~vern!
<!--#include file="footer" -->
</body>
</html>

View File

@ -1,36 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="style.css">
<title>~vern signup</title>
</head>
<body>
<!--#include file="nav" -->
<h1>Sign Up to ~vern</h1>
<form action="cgi-bin/form.cgi" method=POST enctype='multipart/form-data'>
<ul>
<li><b>desired username: <input type=text size=64 name=username></b></li>
<li><b>email address: <input type=text size=64 name=email></b></li>
<li><b>SSH Keys: <br><textarea name=ssh rows="3" cols="50"></textarea></b></li>
<li><b>Why do you want to join ~vern: <br><textarea name=reason rows="8" cols="50"></textarea></b></li>
<h3>What services do you want? (You can always request an account on others later)</h3>
<li><input type="checkbox" id="pubnix" name="pubnix" value="Pubnix" disabled checked>
<b><label for="pubnix">Pubnix and E-mail</label><br></b></li>
<li><input type="checkbox" id="matrix" name="matrix" value="Matrix" checked>
<b><label for="matrix">Matrix</label><br></b></li>
<li><input type="checkbox" id="fedi" name="fedi" value="Mastodon" checked>
<b><label for="fedi">Mastodon</label><br></b></li>
<li><input type="checkbox" id="git" name="git" value="Gitea" checked>
<b><label for="gitea">Gitea</label><br></b></li>
</ul>
<input type="submit" value="Submit">
</form>
<br><b>By signing up, you agree to the ~vern <a href=/rules>rules</a> and <a href=/privpol>privacy policy</a>. Thanks for using ~vern</b><br>
<!--#include file="footer" -->
</body>
</html>

View File

@ -62,3 +62,15 @@ pre {
tab-size:4;
}
.red {
color:#ff6c6b;
}
input[type=submit] {
padding:5px 15px;
background:#51afef;
border:0 none;
-webkit-border-radius: 10px;
border-radius: 10px;
}