With or without root access?
Without root access / root privilege escalation exploit I wouldn’t know.
Assuming Tails booted with manually enabling root access boot options (if it still exists, I guess so).
Untested. I lack motivation to actually test this. But perhaps below works. That’s my conclusion from reading their code related to that since I was interested in it for other reasons earlier. (These reasons were: Tor Browser over clearnet, separate Tor/i2p browser profiles)
Prerequisite: find out the IP address of
check.torproject.org. This has to be done on some system with functional system DNS such as a clearnet host or Whonix-Workstation or some online service. (Since my instructions below do not include how to make DNS working.)
The IP address remained unchanged for at least over a year now or so, I think.
I don’t know if
curl is installed by default in Tails. May or may not be required.
sudo apt-get update
sudo apt-get install curl
From now, assuming curl is installed and root access is available.
The following command can fetch https://check.torproject.org even while DNS is unconfigured.
sudo -u clearnet curl --tlsv1.2 --proto =https -H 'Host: check.torproject.org' -k https://22.214.171.124
If that worked… To see your external IP more easily.
sudo -u clearnet curl --tlsv1.2 --proto =https -H 'Host: check.torproject.org' -k https://126.96.36.199 | grep IP
To make clearnet DNS access (for user
clearnet) functional the following may or may not work.
sudo cp /etc/resolv-over-clearnet.conf /etc/resolv.conf
Prevent sudo from complaining about failing to resolve the ‘amnesia’ host.
echo "127.0.0.1 localhost amnesia" | sudo tee -a /etc/hosts
In case DNS is functional, even the following should work.
sudo -u clearnet curl --tlsv1.2 --proto =https https://check.torproject.org
Perhaps also nslookup would work.
sudo -u clearnet nslookup check.torproject.org