Update README.md

This commit is contained in:
skyper
2024-09-01 10:36:48 +01:00
committed by GitHub
parent ec8c296db2
commit fb0b718ca9
+5 -2
View File
@@ -1211,7 +1211,7 @@ sys.stdout.buffer.write(urllib.request.urlopen(\"$url\", timeout=10, context=ctx
```
Example: Installing gsocket with purl:
```
```sh
source <(purl https://raw.githubusercontent.com/hackerschoice/hackshell/main/hackshell.sh) \
&& bin curl \
&& bash -c "$(curl -fsSL https://gsocket.io/y)" \
@@ -1222,9 +1222,12 @@ Using OpenSSL, download only:
```sh
surl() {
local r="${1#*://}"
local opts=("-quiet" "-ign_eof")
IFS=/ read -r host query <<<"${r}"
openssl s_client --help 2>&1| grep -qFm1 -- -ignore_unexpected_eof && opts+=("-ignore_unexpected_eof")
openssl s_client --help 2>&1| grep -qFm1 -- -verify_quiet && opts+=("-verify_quiet")
echo -en "GET /${query} HTTP/1.0\r\nHost: ${host%%:*}\r\n\r\n" \
| openssl s_client -ignore_unexpected_eof -verify_quiet -quiet -ign_eof -connect "${host%%:*}:443" \
| openssl s_client "${opts[@]}" -connect "${host%%:*}:443" \
| sed '1,/^\r\{0,1\}$/d'
}
# surl ipinfo.io