pstsrv: use curl -x
instead of torsocks
This commit is contained in:
parent
699363c409
commit
2e152aa82e
@ -43,18 +43,18 @@ check_runtime()
|
||||
|
||||
pst_catbox_moe()
|
||||
{
|
||||
$torsocks curl -F "reqtype=fileupload" -F "fileToUpload=@$1" \
|
||||
curl $tor_flags -F "reqtype=fileupload" -F "fileToUpload=@$1" \
|
||||
https://catbox.moe/user/api.php
|
||||
}
|
||||
|
||||
pst_ix_io()
|
||||
{
|
||||
$torsocks curl -F "f:1=@$1" http://ix.io/
|
||||
curl $tor_flags -F "f:1=@$1" http://ix.io/
|
||||
}
|
||||
|
||||
pst_pst_moe()
|
||||
{
|
||||
$torsocks curl -F "content=<$1" -F "expire_after=86400" \
|
||||
curl $tor_flags -F "content=<$1" -F "expire_after=86400" \
|
||||
https://pst.moe/paste
|
||||
}
|
||||
|
||||
@ -75,10 +75,10 @@ do_upload()
|
||||
return $rc
|
||||
}
|
||||
|
||||
torsocks=torsocks
|
||||
tor_flags="-x socks5h://localhost:9050"
|
||||
while getopts T flag; do
|
||||
case $flag in
|
||||
T) torsocks= ;;
|
||||
T) tor_flags= ;;
|
||||
*) usage ;;
|
||||
esac
|
||||
done
|
||||
@ -90,7 +90,7 @@ fi
|
||||
srv=$1
|
||||
shift
|
||||
|
||||
check_runtime curl $torsocks
|
||||
check_runtime curl ${tor_flags:+tor}
|
||||
|
||||
url=
|
||||
[ $# -eq 0 ] && set -- -
|
||||
|
Loading…
Reference in New Issue
Block a user