Skip to content

Instantly share code, notes, and snippets.

#! /bin/bash
# Changed line here: This single line performs the check and exits on failure.
[ -f "subs.txt" ] || { echo "Error: subs.txt not found. Exiting." >&2; exit 1; }
# Check alive hosts by httpx ||| Screenshot not working
# httpx -list subs.txt -json -status-code -title -tech-detect -server -content-length -retries 2 -rate-limit 150 -timeout 10 -follow-redirects -match-code 100,101,200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,307,308,400,401,402,403,404,405,406,407,408,409,410,411,412,413,414,415,416,417,418,421,422,423,424,426,428,429,431,451,500,501,502,503,504,505,506,507,508,510,511 -o httpx-output.json && cat httpx-output.json | jq -r '.url' > live-subs.txt
httpx -list subs.txt -retries 2 -rate-limit 150 -timeout 10 -follow-redirects -match-code 100,101,200,201,202,203,204,205,206,207,208,226,300,301,302,303,304,305,307,308,400,401,402,403,404,405,406,407,408,409,410,411,412,413,414,415,416,417,418,421,422,423,424,426,428,429,431,451,500,501,502,503,504,505,506,507,508,510,51