MCPcopy Create free account
hub / github.com/Ice-Hazymoon/MikuTools / encodeCore

Function encodeCore

utils/sot1_encrypt.js:32–43  ·  view source on GitHub ↗
(code, isUsePasswd = true)

Source from the content-addressed store, hash-verified

30 let passwdTable = this.passwdTable(passwd); // 密码表
31 let coreRunCount = 0; // code加密记数器
32 let encodeCore = (code, isUsePasswd = true) => {
33 let encryptCode = code;
34 // 加密
35 if (isUsePasswd && isPasswd) {
36 let idx = coreRunCount % passwdTable.length;
37 encryptCode = code + passwdTable[idx];
38 coreRunCount++;
39 }
40
41 let codeNumber = parseInt(2800, 16) + circleCode(encryptCode);
42 return String.fromCharCode(codeNumber);
43 };
44
45 // 字符处理
46 strArray.forEach((subStr, key) => {

Callers 1

encodeFunction · 0.85

Calls 1

circleCodeFunction · 0.85

Tested by

no test coverage detected