Coder Social home page Coder Social logo

kfchinanet's Introduction

简介

kfchinanet是由python3编写的电信校园网认证工具。接口来自掌上大学app,你可以使用这个工具简化上网步骤。

使用方法:

1、可执行文件

release页面下载对应平台的可执行文件,按提示使用即可。

2、源码

安装开发环境和包管理器(以ubuntu为例)

sudo apt-get install python3 python3-pip

安装第三方模块

pip3 install psutil requests pyDes protobuf

运行

git clone https://github.com/sytaxwgl/kfchinanet.git
cd kfchinanet
python3 kfchinanet.py

3、路由器

通用版

路由器的使用有点麻烦,每次使用都需要在config.json中手动填入wan口的参数

netmask:网络掩码
gateway:网关
routerip:路由ip,与gateway相同
bssid:网关mac(以"-"相连,如"ff:ff:ff:ff:ff:ff"应改为"ff-ff-ff-ff-ff-ff")

这些参数可以在路由器的web管理界面查看,或者ssh到路由器分别通过ifconfigarp -a命令查看。 配置好之后电脑连上wifi,运行kfchinanet即可。

这里提供一个偷懒的方法,先把网线插电脑上,上线再下线,然后把网线插到路由器,电脑连wifi,上线。 每次使用请务必确保config.json中的相关参数与路由器wan口一致。

openwrt专用版

推荐openwrt或其他支持ssh的路由器使用这个版本openwrt专用版

示例

  • 上线

上线

  • 查询在线设备

在线设备

  • 下线

下线

kfchinanet's People

Contributors

sytaxwgl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

kfchinanet's Issues

貌似电信改协议了,qrcode获取失败

看了一下get_qrcode()中,do_request()获取到的res_text是{"status":"995","time":1540367162079}
Traceback (most recent call last):
File "kfchinanet.py", line 290, in
qrcode = get_qrcode()
File "kfchinanet.py", line 228, in get_qrcode
res_json = do_request(qr_url, 0)
File "kfchinanet.py", line 221, in do_request
print('status: %s, response: %s' % (res_json['status'], res_json['response']))
KeyError: 'response'

电信疑似更新了接口

坐标南京,line 222 异常KeyError:'response',输出解密出来的res_json只有status和time的信息。

登陆设备的mac问题

感谢开发简化登陆的软件,我是使用中发现账号是登陆在一个Nexus6p的手机上,这导致我自己的小米6不能同时登陆账号,能不能告诉修改配置文件的哪些信息可以使软件登陆的手机信息与小米6相同,或者至少能使mac与小米6的相同?谢谢

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.