Skip to content

大连海事大学校园网认证脚本 Dalian Maritime University Campus Network Authentication Script

License

Notifications You must be signed in to change notification settings

Li7777777/DLMU_Network

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

DLMU_Network.py - README

简介 / Introduction

中文

该脚本用于自动化登录大连海事大学(DLMU)校园网络认证系统。

通过解析认证页面中的密钥,并使用 AES-128-ECB 加密方式对密码进行加密,实现自动模拟浏览器的认证过程。

更新于2025/9/11,2025/7之前的加密算法为des,现更改为aes。

English

This script automates the login process to the Dalian Maritime University (DLMU) campus network authentication system.

It extracts the encryption key from the authentication page, uses AES-128-ECB encryption on the password, and simulates the browser-based login process.

Updated on 2025/9/11, the encryption algorithm before 2025/7 was des, now changed to aes.


功能 / Features

  • 自动访问校园网络认证页面

  • 从 HTML 中提取加密密钥(Base64 格式)

  • 使用 AES-128-ECB 对密码加密

  • 自动提交登录表单

  • 支持模拟常规浏览器请求头和 Cookie 管理


依赖环境 / Dependencies

中文

请确保安装以下 Python 包:

pip install requests pycryptodome pyDes

English

Make sure the following Python packages are installed:

pip install requests pycryptodome pyDes


使用方法 / Usage

中文

  1. 克隆或下载该脚本

  2. 安装依赖

  3. 修改 __main__ 部分,将 usernamepassword 替换为你的学号和密码

  4. 运行脚本进行登录:

python DLMU_Network.py

English

  1. Clone or download this script

  2. Install the dependencies

  3. Edit the __main__ section, replacing username and password with your student ID and password

  4. Run the script to log in:

python DLMU_Network.py


核心函数 / Core Functions

aes_encrypt(plaintext, base64_key)

  • 中文:使用 AES-128-ECB 模式加密明文,并返回 Base64 编码密文。

  • English: Encrypt plaintext using AES-128-ECB mode and return the Base64-encoded ciphertext.

login(username, password)

  • 中文:模拟整个认证过程,包括获取密钥、加密密码、提交表单和处理重定向。

About

大连海事大学校园网认证脚本 Dalian Maritime University Campus Network Authentication Script

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages