diff options
| author | Cassio de Campos <cassiopc@gmail.com> | 2017-08-10 10:35:53 +0000 |
|---|---|---|
| committer | Cassio de Campos <cassiopc@gmail.com> | 2017-08-10 10:35:53 +0000 |
| commit | 02b4aacc81613792b0fa618692145dc1e2989e42 (patch) | |
| tree | da7e9da7a587e8ffa9032ebf02a1022a315e9305 /tools/boca-auth-runs | |
| parent | e1b61094597488dcb3ef166013186b07bf379d76 (diff) | |
| download | boca-02b4aacc81613792b0fa618692145dc1e2989e42.tar.gz boca-02b4aacc81613792b0fa618692145dc1e2989e42.zip | |
removal of old files, preparation for https
Diffstat (limited to 'tools/boca-auth-runs')
| -rwxr-xr-x | tools/boca-auth-runs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/boca-auth-runs b/tools/boca-auth-runs index c03fc4f..565bbd1 100755 --- a/tools/boca-auth-runs +++ b/tools/boca-auth-runs @@ -26,13 +26,13 @@ for i in wget sha256sum cut; do done temp=/tmp/.temp.`date +%s%N`.txt -md=`wget -t 2 -T 5 -S http://$BOCASERVER/boca/getcode.php -O /dev/null --save-cookies ${temp}.cookie.txt --keep-session-cookies 2>&1 | grep PHPSESS | tail -n1` +md=`wget -t 2 -T 5 -S https://$BOCASERVER/boca/getcode.php -O /dev/null --save-cookies ${temp}.cookie.txt --keep-session-cookies 2>&1 | grep PHPSESS | tail -n1` echo "$md" | grep -q PHPSESS if [ "$?" == "0" ]; then md=`echo $md | cut -f2 -d'=' | cut -f1 -d';'` ress=`echo -n $pass | sha256sum - | cut -f1 -d' '` res=`echo -n "${ress}${md}" | sha256sum - | cut -f1 -d' '` - wget -t 2 -T 5 "http://$BOCASERVER/boca/getcode.php?name=${user}&password=${res}" --load-cookies ${temp}.cookie.txt --keep-session-cookies --save-cookies ${temp}.cookie.txt -O $temp 2>/dev/null >/dev/null + wget -t 2 -T 5 "https://$BOCASERVER/boca/getcode.php?name=${user}&password=${res}" --load-cookies ${temp}.cookie.txt --keep-session-cookies --save-cookies ${temp}.cookie.txt -O $temp 2>/dev/null >/dev/null grep -qi incorrect $temp if [ $? == 0 ]; then echo "" |