MCPcopy Create free account
hub / github.com/TeleBoxOrg/TeleBox_Plugins / getEncryptionKey

Function getEncryptionKey

speedlink/speedlink.ts:302–308  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

300 if (fs.existsSync(filePath)) fs.unlinkSync(filePath);
301 });
302 console.log("Speedtest CLI downloaded and extracted successfully.");
303}
304
305function getEncryptionKey(): string {
306 if (fs.existsSync(KEY_PATH)) return fs.readFileSync(KEY_PATH, "utf-8");
307 const newKey = crypto.randomBytes(16).toString("hex");
308 fs.writeFileSync(KEY_PATH, newKey, "utf-8");
309 console.log(`SpeedLink Plugin (${PLUGIN_NAME}): New encryption key generated.`);
310 return newKey;
311}

Callers 1

speedlink.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected