[乱写]CUIT抢课脚本使用 | 祭夜の咖啡馆
  • 公告

[乱写]CUIT抢课脚本使用

记录 祭夜 5个月前 (09-17) 378次浏览 已收录 2个评论 扫描二维码
文章目录[隐藏]
不是,连课都能卖?这是我没想到的~
import requests
import re
import time
import os

'''
使用方法:https://www.jysafe.cn/4498.air
'''
class FC(object):
    cookie = ""

    def __init__(self, cookie):
        self.cookie = cookie
        pass
    
    def fuckCourse(self, profiledId, courseId):
        try:
            body = {
                "optype": "true",
                "operator0": courseId + ":true:0",
                "lesson0":courseId,
                "schLessonGroup_" + courseId:"undefined"
            }
            req = requests.post("http://jwgl.cuit.edu.cn/eams/stdElectCourse!batchOperator.action?profileId=" + profiledId,
                headers={
                    "cookie": self.cookie,
                    "X-Requested-With": "XMLHttpRequest",
                    "Referer" : "http://jwgl.cuit.edu.cn/eams/stdElectCourse!batchOperator.action?profileId=" + profiledId,
                    "user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/84.0.4147.0 Safari/537.36 Edg/84.0.521.0"
                }, data=body, timeout=5, allow_redirects=False)
            req.encoding = 'utf-8'
            
            html = req.text
            ret = re.search(r"margin:auto;\">\n\t\t\t\t(.*)<\/br>", html)
            if ret == None:
                print("cookie过期")
                exit(-1)
                pass
            print(ret.group(1))

            if '成功' in ret.group(1):
                print('get')
                return True
        except Exception as err:
            print(err)
            return False
        pass
    pass
if __name__ == "__main__":
    cookie = "semester.id=302; JSESSIONID=91C437F0A9006E9CD821FBCB0141949F; UM_distinctid=1763c6f7b491cd-05963b1e59c36-5a301348-100200-1763c6f7b4a52a; GSESSIONID=91C437F0A9006E9CD821FBCB0141949F"
    profiledId = "2213"
    courseId = "68558"

    if cookie == None:
        cookie = input("请输入cookie:")
    if profiledId == None:
        profiledId = input("请输入profiledId:")
    if courseId == None:
        courseId = input("请输入courseId:")
    print("开始了呀")
    cuit = FC(cookie)
    i= 0
    while True:
        i += 1
        print(i)
        if cuit.fuckCourse(profiledId, courseId):
            break
        time.sleep(0.5)
        if i >= 20:
            i = 0
            os.system("cls")
            pass
        pass
    pass

profiledId可以直接看见

 

[乱写]CUIT抢课脚本使用

 

LessonId获取

[乱写]CUIT抢课脚本使用

cookie获取

[乱写]CUIT抢课脚本使用
[乱写]CUIT抢课脚本使用


祭夜の咖啡馆 , 版权所有丨如未注明 , 均为原创丨本网站采用BY-NC-SA协议进行授权
转载请注明原文链接:[乱写]CUIT抢课脚本使用
喜欢 (0)
[1690127128@qq.com]
分享 (0)
发表我的评论
取消评论
OwO表情
贴图 加粗 删除线 居中 斜体 签到

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址
(2)个小伙伴在吐槽
  1. az,是大佬了。
    L_inkOO2021-01-04 17:00 回复 Linux | Chrome 77.0.3865.120
    • cqcadmin
      #(小嘴滑稽)
      祭夜2021-01-04 17:05 回复 Windows 10 | Chrome 87.0.4280.88