Skip to content

Instantly share code, notes, and snippets.

@erolj
Created June 20, 2020 09:14
Show Gist options
  • Save erolj/5bee09f3842155c718b9e540646d54dc to your computer and use it in GitHub Desktop.
Save erolj/5bee09f3842155c718b9e540646d54dc to your computer and use it in GitHub Desktop.
Script sederhana deteksi sebuah domain menggunakan cloudflare ns atau tidak.
#!/bin/bash
read -rp "Masukkan nama domain: " DOMAIN
CHKDOMAIN=$(dig ns "${DOMAIN}" +short | grep -o cloudflare | head -1)
if [ ! "${CHKDOMAIN}" = "cloudflare" ]; then
echo "Tidak menggunakan NS Cloudflare"
else
echo "Menggunakan NS Cloudflare"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment