DNS over Tor example script overwrites /etc/hosts

Thanks Cloudflare for the amazing hidden DNS resolver!

I was trying the instructions at https://developers.cloudflare.com/ and executed step 3:

cat << EOF > /etc/hosts dns4torpnlfs2ifuz2s2yf3fc7rdmsbhm6rw75euj35pac6ap25zgqad.onion

I was expecting this command to append to /etc/hosts instead of overwriting it. My feedback is to change the example script to cat << EOF >> /etc/hosts. This could prevent others from accidentally losing their hosts file (as I did).



This topic was automatically closed after 14 days. New replies are no longer allowed.