Error: Login token - failure (curl error code: 2)
zaxy opened this issue · 1 comments
Hi - Thanks for a wonderful script which was working for me earlier this year (Feb 2021).
I now get this error every time. It appears to be a curl error so I reinstalled curl, but no joy.
I tried this based on your diagnostic section:
$ curl -%ipv% -A %agent% -m 10 -s https://diagnostic.opendns.com/myip
but get this:
curl: option -%ipv%: is unknown
Please help. This program is doing great things!!
I am on a Ubuntu machine:
Linux 5.4.0-77-generic #86-Ubuntu SMP Thu Jun 17 02:35:03 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Hi,
When you ran freenom.sh -i
there are notes at the bottom:
NOTES:
%ipv% gets replaced by $freenom_update_ipv
%agent% gets replaced with useragent string
So, to test try e.g.:
curl -4 -A "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:89.0) Gecko/20100101 Firefox/89.0" -m 10 -s https://diagnostic.opendns.com/myip
Anyways, when freenom-script runs curl to get ip it probably works (same as the test).
But the next thing the script does fails: login to freenom.
From man curl
:
EXIT CODES
There are a bunch of different error codes and their corresponding error messages that may appear during bad conditions. At the time of this writing, the exit codes are:<...>
2 Failed to initialize.
Could be caused by an issue with curl's options or special chars in password for example.
The latter is known to happen with older curl versions (see #25).
Looks like you're running Ubuntu 20.04 (focal) which should have an updated version. Check curl --version
to be sure.
If it's older curl try setting freenom_oldcurl_force="1"
in freenom.conf.
Also make sure you run latest version of freenom-script ofc.
And lastly running freenom.sh
with -debug 9
will show details about what it does.