summaryrefslogtreecommitdiff
path: root/nocompile/libexec
diff options
context:
space:
mode:
authorEpoch Qwert <epoch@53flpnlls43fcguy.onion>2015-01-11 03:01:37 -0600
committerEpoch Qwert <epoch@53flpnlls43fcguy.onion>2015-01-11 03:01:37 -0600
commit42d9771ba0c2e3491025e24956c995a7db56372c (patch)
tree58bdbd0473d0789a59864063410b9ef5a9a1bcb6 /nocompile/libexec
parent3f6b64304a8a11f0505e91681384327696983928 (diff)
downloadmisc-42d9771ba0c2e3491025e24956c995a7db56372c.tar.gz
misc-42d9771ba0c2e3491025e24956c995a7db56372c.zip
fuck if I know. I was just going to add the gateway. >_>
Diffstat (limited to 'nocompile/libexec')
-rwxr-xr-xnocompile/libexec/gopherd.sh5
-rwxr-xr-xnocompile/libexec/telnet-gateway.sh17
2 files changed, 20 insertions, 2 deletions
diff --git a/nocompile/libexec/gopherd.sh b/nocompile/libexec/gopherd.sh
index d710f80..78509dc 100755
--- a/nocompile/libexec/gopherd.sh
+++ b/nocompile/libexec/gopherd.sh
@@ -10,6 +10,7 @@
# "export hostname" down there.
export PATH=$PATH:/usr/local/bin
read -t 10 req
+logger -t gopher "$(/usr/local/libexec/peerip|head -n1): ${req}"
base="$1"
arg=$(echo "$req" | tr -d '\r' | cut -f2)
#req=$(echo "$req" | unescape | tr -d '\r' | cut -f1)
@@ -33,14 +34,14 @@ else
printf ""
# echo "fucked off #1"
# echo "$myIP != $(gethostbyname $hostname 6)"
-# logger "hostname (${hostname}) and IP (${myIP}) aren't matching up.";
+# logger -t gopher "hostname (${hostname}) and IP (${myIP}) aren't matching up.";
# exit 2
#jimmy cracked corn but nobody gives a shit.
fi
else
if [ $(gethostbyname $hostname) != ${myIP} ];then
echo "fucked off #2"
- logger "hostname (${hostname}) and IP (${myIP}) aren't matching up.";
+ logger -t gopher "hostname (${hostname}) and IP (${myIP}) aren't matching up.";
exit 2
fi
fi
diff --git a/nocompile/libexec/telnet-gateway.sh b/nocompile/libexec/telnet-gateway.sh
new file mode 100755
index 0000000..ca2b90d
--- /dev/null
+++ b/nocompile/libexec/telnet-gateway.sh
@@ -0,0 +1,17 @@
+#!/bin/bash
+grep "^telnet:" /var/www/sites/hacking/links.txt \
+ | cat -n
+printf "Which do you want to connect to?\nnumber: "
+read N
+export N=$(printf "%s" "$N" | sed "s/[^0-9]//g")
+serverURL=$(grep "^telnet:" /var/www/sites/hacking/links.txt \
+ | cut '-d ' -f1 \
+ | head -n${N} \
+ | tail -n1)
+echo "You've selected: $serverURL (#$N)"
+printf "connecting in...\n"
+for i in `seq 5 1`;do
+ printf "\r%d..." $i
+ sleep 1
+done
+nc $(printf "%s" "$serverURL" | cuturl | grep ^domain | cut '-d ' -f2) 23