extra port swap + TODO extra filters during Ŋ1 sync
This commit is contained in:
parent
12205fb5cc
commit
c1cd11b630
8
12345.sh
8
12345.sh
|
@ -39,7 +39,7 @@ function urldecode() { : "${*//+/ }"; echo -e "${_//%/\\x}"; }
|
|||
while true; do
|
||||
MOATS=$(date -u +"%Y%m%d%H%M%S%4N")
|
||||
## CHANGE NEXT PORT (HERE YOU CREATE A SOCKET QUEUE)
|
||||
[ $PORT -lt 12345 ] && PORT=$((PORT+${RANDOM:0:2})) || PORT=$((PORT-${RANDOM:0:2}))
|
||||
[ $PORT -lt 12345 ] && PORT=$((PORT+${RANDOM:0:3})) || PORT=$((PORT-${RANDOM:0:3}))
|
||||
## RANDOM PORT SWAPPINESS
|
||||
|
||||
SALT=""; PEPPER=""; TYPE=""
|
||||
|
@ -228,8 +228,8 @@ cat ~/.zen/tmp/123/${MOATS}.messaging.json >> ~/.zen/tmp/123/${MOATS}.index.redi
|
|||
if [[ -s ~/.zen/tmp/123/${MOATS}.astroindex.html ]]; then
|
||||
tiddlywiki --load ~/.zen/tmp/123/${MOATS}.astroindex.html --output ~/.zen/tmp --render '.' 'miz.json' 'text/plain' '$:/core/templates/exporters/JsonFile' 'exportFilter' 'MadeInZion'
|
||||
OLDIP=$(cat ~/.zen/tmp/miz.json | jq -r .[].secret)
|
||||
[[ ! $OLDIP ]] && (echo "ERROR - $OLDIP WRONG TW - CONTINUE " | nc -l -p ${PORT} -q 1 > /dev/null 2>&1 &) && continue
|
||||
# FIRST TIME WHAT TW USING GATEWAY
|
||||
[[ ! $OLDIP ]] && (echo "501 ERROR - SORRY - YOUR TW IS OUT OF SWARM#0 - CONTINUE " | nc -l -p ${PORT} -q 1 > /dev/null 2>&1 &) && continue
|
||||
# LOCKED TW BECOMING NEW GATEWAY
|
||||
if [[ $OLDIP == "_SECRET_" ]]; then
|
||||
echo "_SECRET_ TW PUSHING TW" ## SEND FULL TW
|
||||
sed -i "s~_SECRET_~${myIP}~g" ~/.zen/tmp/123/${MOATS}.astroindex.html
|
||||
|
@ -241,7 +241,7 @@ Content-Type: text/html; charset=UTF-8
|
|||
cat ~/.zen/tmp/123/${MOATS}.index.redirect | nc -l -p ${PORT} -q 1 > /dev/null 2>&1 &
|
||||
continue
|
||||
fi
|
||||
# REDIRECTING TO ACTUAL GATEWAY
|
||||
# REDIRECTING TO TODAY GATEWAY
|
||||
[[ $OLDIP != $myIP ]] && TWIP=$OLDIP
|
||||
echo "*********** OFFICIAL LOGIN GOES TO $TWIP"
|
||||
else
|
||||
|
|
|
@ -87,7 +87,11 @@ do
|
|||
[[ $(cat ~/.zen/tmp/${IPFSNODEID}/${ASTRONAUTENS}/${WISHNAME}/g1wishtiddlers.json) == "[]" ]] && echo "EMPTY ${WISHNAME} - CONTINUE -" && continue
|
||||
|
||||
echo "## WISHES FOUND ;) MIAM "
|
||||
######################################
|
||||
## TODO ADD EXTRA TAG ?
|
||||
# Remove G1${WISHNAME} with WISHNAME Initial TIDDLER
|
||||
# Reduce importation with extra filters days:created[-1]
|
||||
# Apply Extra filters... TODO LEARN https://talk.tiddlywiki.org/t/how-to-filter-and-delete-multiple-tiddlers/4950/2?u=papiche
|
||||
echo ">>> Importing ~/.zen/tmp/${IPFSNODEID}/${ASTRONAUTENS}/${WISHNAME}/g1wishtiddlers.json"
|
||||
|
||||
tiddlywiki --load $INDEX \
|
||||
|
|
|
@ -17,18 +17,18 @@ Content-Type: text/html; charset=UTF-8
|
|||
<body>
|
||||
<center>
|
||||
<h2>Astroport Ŋ1 Swarm#0</h2>
|
||||
<b>--- Devenez Astronaute ---</b><br>
|
||||
<b>--- Astronaute ---</b><br>
|
||||
|
||||
<form action = "http://127.0.0.1:1234" method = "GET">
|
||||
<br>
|
||||
<b>Recevez vos clefs par Email</b></br>
|
||||
<b>Saisir vos clefs pour recevoir votre Visa Libre par email</b></br>
|
||||
Phrase Une ("identifiant") : <input name=salt value=''></br>
|
||||
Phrase Deux ("mot de passe") : <input name=pepper value=''></br>
|
||||
<input type="checkbox" id="g1pub" name="g1pub"> acceptation des G1Conditions</br>
|
||||
<input type="checkbox" id="g1pub" name="g1pub"> accepter leur délégation et synchonisation Ŋ1 à 20h12</br>
|
||||
Email : <input name=email value=''></br></br>
|
||||
<input type='submit' value='OUVRIR UN COMPTE'>
|
||||
<input type='submit' value='OCCUPER CET ESPACE'>
|
||||
</form>
|
||||
<h3><a href="http://127.0.0.1:12345">ALLER AU PROCHAIN PORT</a></h3>
|
||||
<h3>[<a href="http://127.0.0.1:12345">VISITER LE PORT SUIVANT</a>]</h3>
|
||||
<br>
|
||||
<a href="http://127.0.0.1:8080/ipns/_IPFSNODEID_" target="json"><img width=420 height=420 src='http://127.0.0.1:8080/ipfs/QmbY3R4UV43Bz7eQDEYgXZKWnszArGwnJqMmfSZ7CCWFcq' id='API'/></a>
|
||||
</center>
|
||||
|
|
Loading…
Reference in New Issue