Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

简化方法 #1

Open
wu2305 opened this issue Dec 18, 2021 · 3 comments
Open

简化方法 #1

wu2305 opened this issue Dec 18, 2021 · 3 comments

Comments

@wu2305
Copy link

wu2305 commented Dec 18, 2021

校园网的认证方式其实相当简单如果你会用firefox抓包的话

  1. 打开firefox的F12监听请求,你会发现其中有一个POST包很有意思
POST http://172.20.13.100:804/include/auth_action.php HTTP/1.1
User-Agent: [本机UA]
Content-Type: application/x-www-form-urlencoded
Body: action=login&username=[学号]&password={B}[urlencoded(base64([yourpasswd]))]&ac_id=18&user_ip=&nas_ip=&user_mac=&ajax=1
  1. 想办法发出这个样子的请求
  2. 返回字符串login.ok={Cookie}
  3. 不用管Cookie
  4. 通过ping百度即可检测是否断开
@arthurJHM
Copy link
Owner

校园网的认证方式其实相当简单如果你会用firefox抓包的话

  1. 打开firefox的F12监听请求,你会发现其中有一个POST包很有意思
POST http://172.20.13.100:804/include/auth_action.php HTTP/1.1
User-Agent: [本机UA]
Content-Type: application/x-www-form-urlencoded
Body: action=login&username=[学号]&password={B}[urlencoded(base64([yourpasswd]))]&ac_id=18&user_ip=&nas_ip=&user_mac=&ajax=1
  1. 想办法发出这个样子的请求
  2. 返回字符串login.ok={Cookie}
  3. 不用管Cookie
  4. 通过ping百度即可检测是否断开

有道理,直接模拟POST请求肯定更简单 当时是怕学校的接口会变 才用的操作浏览器的方法(不过好像接口也没变过)
还有你可以试一下你说的这个方法 直接发这一个请求好像还不大行

@wu2305
Copy link
Author

wu2305 commented Jan 1, 2022 via email

@arthurJHM
Copy link
Owner

我这里似乎是可以的卖给学校这个认证端的公司不是注销了~~-------- 原始邮件 --------发件人: arthurJHM @.>日期: 2012 月 22 日周日 15:261/ECEC:arthurJHMUSTNetWorkAutoConnection @> 抄送: wucheng29 @.>,作者 *********题: Re: [arthurJHM/ECUSTNetWorkAutoReConnection]@监听请求1个简单的抓包方法(Issue )你会发现其中有一个POST包很奇怪 POST http://172.20.13.100:804/include/auth_action.php HTTP/1.1 User-Agent: [本机UA] Content-Type: application/x-www-form-urlencoded 正文: action=login&username=[学号]&password={B}[urlencoded(base64([yourpasswd])) ]&ac_id=肯定18&user_ip=更正&_ip=&user_mac=&ajax=1 发出这个请求的形状=&ajax=1操作简单的时候是怕学校的接口会变才用的浏览器的方法(不过这个接口没有变过)另外你可以试一下你说的方法直接发送此电子邮件,在 GitHub 上查看,或取消订阅。您收到此邮件是因为您创建了该主题。消息 ID:@.**>

是连的ECUST 这个wifi吧? 那之后我试试看

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants