diff --git a/12345.sh b/12345.sh index 05eb6c86..4742797c 100755 --- a/12345.sh +++ b/12345.sh @@ -26,8 +26,10 @@ mkdir -p ~/.zen/tmp/123/ ## CHECK FOR ANY ALREADY RUNNING nc ncrunning=$(ps auxf --sort=+utime | grep -w 'nc -l -p 1234' | grep -v -E 'color=auto|grep' | tail -n 1 | cut -d " " -f 1) [[ $ncrunning ]] && echo "ERROR - API Server Already Running - http://$myIP:1234/?salt=toto&pepper=toto " && exit 1 - -echo "LAUNCHING Astroport API Server - http://$myIP:1234/?salt=toto&pepper=toto&official" +echo "_________________________________________________________" +echo "LAUNCHING Astroport API Server " +echo "TEST http://$myIP:1234/?salt=toto&pepper=toto&official" +echo "_________________________________________________________" # [[ $DISPLAY ]] && xdg-open "file://$HOME/.zen/Astroport.ONE/templates/instascan.html" 2>/dev/null # [[ $DISPLAY ]] && xdg-open "http://$myIP:1234" 2>/dev/null @@ -86,7 +88,8 @@ sed -i "s~_HOSTNAME_~$(hostname)~g" ~/.zen/tmp/123/${MOATS}.index.redirect echo "GET RECEPTION : $URL" arr=(${URL//[=&]/ }) echo "PARAM : ${arr[0]} = ${arr[1]} & ${arr[2]} = ${arr[3]} & ${arr[4]} = ${arr[5]} & ${arr[6]} = ${arr[7]} & ${arr[8]} = ${arr[9]}" - # CHECK TYPE + + # CHECK TYPE TYPE=$(urldecode ${arr[4]}) WHAT=$(urldecode ${arr[5]}) @@ -97,7 +100,7 @@ sed -i "s~_HOSTNAME_~$(hostname)~g" ~/.zen/tmp/123/${MOATS}.index.redirect ################################################################################################### # API ZERO ## Made In Zion & La Bureautique if [[ ${arr[0]} == "salt" ]]; then - echo "Application LaBureautique !!" + echo "!!!!!!!!!! Application LaBureautique !! TYPE = $TYPE" SALT=$(urldecode ${arr[1]} | xargs); [[ ! $SALT ]] && (echo "ERROR - SALT MISSING" | nc -l -p ${PORT} -q 1 &) && continue PEPPER=$(urldecode ${arr[3]} | xargs) @@ -180,10 +183,10 @@ cat ~/.zen/tmp/123/${MOATS}.messaging.json >> ~/.zen/tmp/123/${MOATS}.index.redi ipfs --timeout 12s ping $NODEID & ## COULD BE A RAW FILE, AN HTML, A JSON - echo "CURLING https://ipfs.io/ipfs/$DATAID" + echo "CURLING https://ipfs.io/ipfs/$DATAID ~/.zen/tmp/${IPFSNODEID}/$NODEID/${MOATS}" (curl -m 12 -so ~/.zen/tmp/${IPFSNODEID}/$NODEID/${MOATS}/index.html "https://gateway.ipfs.io/ipfs/$DATAID" && \ - [[ -s ~/.zen/tmp/${IPFSNODEID}/$NODEID/${MOATS}/index.html ]] && \ - [[ ! $(~/.zen/tmp/${IPFSNODEID}/$NODEID/${MOATS}/index.html | jq) ]] && \ + [[ -s ~/.zen/tmp/${IPFSNODEID}/$NODEID/${MOATS}/index.html ]] && echo "index.html" &&\ + [[ ! $(~/.zen/tmp/${IPFSNODEID}/$NODEID/${MOATS}/index.html | jq) ]] && echo "NOT JSON - DECODING " &&\ $MY_PATH/tools/testcraft.DECODE.sh "~/.zen/tmp/${IPFSNODEID}/$NODEID/${MOATS}/index.html") & echo "CAT $NODEID /ipfs/$DATAID" diff --git a/ASTROBOT/G1Voeu.sh b/ASTROBOT/G1Voeu.sh index 25aa8fee..45d6df76 100755 --- a/ASTROBOT/G1Voeu.sh +++ b/ASTROBOT/G1Voeu.sh @@ -77,6 +77,7 @@ echo ########################################################################################## # ipfs key import _MEDIAKEY_ ~/.zen/Astroport.ONE/templates/_MEDIAKEY_.keystore.key ############## + # # ipfs cat /ipfs/bafybeibqdoegifzejykmc3qw3e3drgsa5i7az6xwjlfcx7rbtcoj5unpkq > ~/.zen/Astroport.ONE/templates/twdefault.html # INTRODUCE HIDING CONTROL (read only from https) https $:/tags/Stylesheet # ipfs cat /ipfs/bafybeidkur2tfbmqwscgmkfh76vmbcqay2m4gznxv5emkenxeffmrgywky > ~/.zen/Astroport.ONE/templates/twdefault.html diff --git a/start.sh b/start.sh index 3417942c..b33e7631 100755 --- a/start.sh +++ b/start.sh @@ -40,6 +40,8 @@ YOU=$(ps auxf --sort=+utime | grep -w ipfs | grep -v -E 'color=auto|grep' | tail [[ ! $YOU ]] && echo "Lancez 'ipfs daemon' SVP sudo systemctl start ipfs" && exit 1 IPFSNODEID=$(cat ~/.ipfs/config | jq -r .Identity.PeerID) +echo 'PRESS ENTER... '; read + ## CREATE AND OR CONNECT USER PS3='Créez VISA ou connectez-vous à votre compte Astronaute ___ ' players=("NOUVEAU VISA" "IMPORT GVISA" $(ls ~/.zen/game/players 2>/dev/null)) diff --git a/templates/index.http b/templates/index.http index 1babed1f..4ab309c2 100644 --- a/templates/index.http +++ b/templates/index.http @@ -18,7 +18,7 @@ Content-Type: text/html; charset=UTF-8

ASTROPORT Ŋ1

-Astronaute... ouverture du sas... S'il a du mal à s'ouvrir: insistez !
+Astronaute ! Ouverture de votre sas en cours...