Skip to content

Commit

Permalink
Record multiple addresses
Browse files Browse the repository at this point in the history
  • Loading branch information
willnode committed Oct 7, 2024
1 parent aba929f commit bed2e7c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
8 changes: 4 additions & 4 deletions src/whitelist/resolve.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ for RECORD_TYPE in A AAAA; do
if [[ -v TERMINFO ]]; then
printf '\r%s Fetching NS %s of %s' "$(tput el)" $RECORD_TYPE $p
fi
FFI=$(dig +short $RECORD_TYPE $(echo "$p" | xargs) | grep -v '\.$' | tail -n1)
FFI=$(dig +short $RECORD_TYPE $(echo "$p" | xargs) | grep -v '\.$')
while read -r q; do
if [[ $q != "" ]]; then
HOST_ADDRESSES+="$q $p"$'\n'
Expand All @@ -26,6 +26,6 @@ for RECORD_TYPE in A AAAA; do
done <"$SCRIPT_DIR/sites.conf"
done

echo "$IPV4_ADDRESSES" > "$SCRIPT_DIR/ipv4_addresses.txt"
echo "$IPV6_ADDRESSES" > "$SCRIPT_DIR/ipv6_addresses.txt"
echo "$HOST_ADDRESSES" > "$SCRIPT_DIR/host_addresses.txt"
echo -n "$IPV4_ADDRESSES" > "$SCRIPT_DIR/ipv4_addresses.txt"
echo -n "$IPV6_ADDRESSES" > "$SCRIPT_DIR/ipv6_addresses.txt"
echo -n "$HOST_ADDRESSES" > "$SCRIPT_DIR/host_addresses.txt"
1 change: 0 additions & 1 deletion src/whitelist/sites.conf
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,6 @@ sandbox.smtp.mailtrap.io
live.smtp.mailtrap.io
# Database Services
data.mongodb-api.com
x.y.aivencloud.com
r2.cloudflarestorage.com
# Media Services
quickchart.io
Expand Down

0 comments on commit bed2e7c

Please sign in to comment.