z4yx / GoAuthing

Authentication utility for srun4000 (auth.tsinghua.edu.cn / net.tsinghua.edu.cn / Tsinghua-IPv4)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support net.tsinghua.edu.cn

ritou11 opened this issue · comments

Currently we are still using it for "Tsinghua" & "Tsinghua-5G".

https://github.com/syimyuzya/tunet-cli is dedicated for that purpose and works fine.

https://github.com/syimyuzya/tunet-cli is dedicated for that purpose and works fine.

Yep. In fact, I have a repo https://github.com/ritou11/thunet-reg based on Node.js. It could satisfy my daily routine.
However, "thunet-reg" is written in JS, and "tunet-cli" is written in Python. Both of them require extra environments currently such as Node or Python. Since Golang is easy to compile and release, I'm taking it as the best language in this situation.

If JS and Python are too heavy, why not use curl to do this job.

curl -sL net.tsinghua.edu.cn/do_login.php --data "action=login&username=yourID&password={MD5_HEX}yourPasswdMD5&ac_id=1"

Since net.tsinghua will soon be replaced by auth, I'm not motivated to add this feature. But PR is always welcomed.

I did use curl for this years ago by writing a bash script. Similar to #3 , it's kind of a fancy function but counts in my personal daily use indeed.