Files
MemRelay/projects/f5708b07-f0ea-42a4-b4ed-0e5443990ff9/Checkpoint 2026-11-14 17-40-00 UTC [495e31f4ff].md
T
memrelay 46144ef249 create: Checkpoint 2026-11-14 17:40:00 UTC [495e31f4ff]
MemRelay-Operation: checkpoint-save:euniv-encrypt-live-checkpoint-20261115
MemRelay-Resource: 06cfe85c-d83e-4b9d-a631-2c8a12c0e8d1
2026-11-15 01:40:03 +08:00

40 lines
1.8 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
---
title: Checkpoint 2026-11-14 17:40:00 UTC [495e31f4ff]
type: checkpoint
permalink: main/projects/f5708b07-f0ea-42a4-b4ed-0e5443990ff9/checkpoint-2026-11-14-17-40-00-utc-495e31f4ff
stable_id: 06cfe85c-d83e-4b9d-a631-2c8a12c0e8d1
scope: project
memory_type: checkpoint
project_id: f5708b07-f0ea-42a4-b4ed-0e5443990ff9
usage_profile_id: 0c9feb46-d06e-43cd-9ef0-c5813c84a998
status: active
revision: 1
request_id: euniv-encrypt-live-checkpoint-20261115
created_at: '2026-11-14T17:40:00.313155+00:00'
updated_at: '2026-11-14T17:40:00.313155+00:00'
tags:
- autostudy
- encrypt
---
## 完成
心跳摘要不再写死 MD5 密钥,一律向本站 GetEncryptRequest 在线换取。视频/文档/Scorm(含 end:true)同一条路径。播放脚本 URL 从播放页解析,接口路径从当前 kng_studytrack_rw.js 提取并缓存 6 小时。
## 关键实现
- 新增 euniv/encrypt.py:payload 为 {"body":"<进度 JSON 字符串>"},Content-Type text/json,带 Origin/Referer。
- 嵌套对象会 HTTP 400;WCF 成功响应是单引号 JSON 字符串。
- 删除 STUDY_MD5_KEY / study_encryption / _scorm_md5。
- StudySession Cookie 拷贝与 EunivClient 共用 _load_cookies,空 domain 不传。
## 验证
52 项 pytest 通过。用库中 6650000146 会话实测:同步/异步 GetEncryptRequest 均返回 32 位十六进制且一致;Scorm end:true 正文也可换摘要。
## 下一步
提交并推送本改动;确认 127.0.0.1:8000 已加载新代码。每用户并发课程数仍默认 1。
## 给下个会话
- 不要再把 60db8c0a-72d8-4b8f-bb45-c4c3f29a2696 写回代码。
- GetEncryptRequest 必须发字符串 body,不能发嵌套对象。
- 服务 127.0.0.1:8000,EUNIV_DB_PATH=data/euniv.db,EUNIV_SECRET_KEY=dev-local-key。
- 密码库条目「euniv 工号 6650000146」;管理后台 admin。
- 产品文案不要写聊天记录或开发说明。