A Python wrapper for Zhejiang University WebVPN
Project description
ZJUWebVPNSession
A Python wrapper for accessing Zhejiang University WebVPN automatically.
Login once, access all ZJU internal sites as if you are on campus.
Features
- Auto login to webvpn.zju.edu.cn
- Transparent URL conversion (no need to manually rewrite URLs)
- Fully compatible with
requestsAPI - Easy to download files, submit forms, crawl internal resources, etc.
Install
pip install ZJUWebVPN
Quick Start
from ZJUWebVPN import ZJUWebVPNSession
# Create a session and login
session = ZJUWebVPNSession('your_zju_username', 'your_zju_password')
# Example: GET request to an internal site
resp = session.get('https://www.cc98.org/')
print(resp.text)
Examples
1. GET a page
resp = session.get('https://www.cc98.org/')
print(resp.text)
2. POST a form
data = {'key1': 'value1', 'key2': 'value2'}
resp = session.post('https://test.zju.edu.cn/submit', data=data)
print(resp.text)
Requirements
requestspycryptodome
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
zjuwebvpn-0.1.4.tar.gz
(4.8 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file zjuwebvpn-0.1.4.tar.gz.
File metadata
- Download URL: zjuwebvpn-0.1.4.tar.gz
- Upload date:
- Size: 4.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
15977b9785d2041e062c23144df8a88669229dce6798f8debd3f1085f081c438
|
|
| MD5 |
8cad236fe912e3faa471e3e008828059
|
|
| BLAKE2b-256 |
1c6f0faeec298a95e48d9afd33774aa44a5148ba1068370e7dc08a94bad8c3c5
|
File details
Details for the file zjuwebvpn-0.1.4-py3-none-any.whl.
File metadata
- Download URL: zjuwebvpn-0.1.4-py3-none-any.whl
- Upload date:
- Size: 5.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3ab499078fee4df85c05758581d86b9ffcaeb8ea9af1cddfabe0c6f1d3a466e9
|
|
| MD5 |
88f58b24c811c056b0232fa7b0025099
|
|
| BLAKE2b-256 |
9829a9bb68fc6b26a4314dc3dc540fb1b098cb98ccd610b38be0214522d8e8ed
|