@ks-dbdev/template-db-automatic-plugin
Advanced tools
+1
-1
| { | ||
| "name": "@ks-dbdev/template-db-automatic-plugin", | ||
| "version": "1.0.1", | ||
| "version": "1.0.2", | ||
| "type": "module", | ||
@@ -5,0 +5,0 @@ "scripts": { |
@@ -1,1 +0,1 @@ | ||
| const apiBaseUrl = "https://ones-cache.wps.cn/oc/producer/data"; | ||
| // 放置api相关函数/常量 |
+0
-16
@@ -1,17 +0,1 @@ | ||
| const UTILS = { | ||
| createSign: (secret) => { | ||
| const timestamp = String(Math.round(Date.now())); | ||
| // 构造待签名字符串:"{timestamp}\n{secret}" | ||
| const stringToSign = `${timestamp}\n${secret}`; | ||
| // 创建 HMAC 对象,使用 SHA256 算法和密钥(注意密钥传入时为字符串即可) | ||
| const hmac = Crypto.createHmac('sha256', secret); | ||
| hmac.update(stringToSign); | ||
| const hmacCode = hmac.digest(); // 得到 Buffer | ||
| const sign = encodeURIComponent(hmacCode.toString('base64')); | ||
| return { sign, timestamp }; | ||
| }, | ||
| }; | ||
| export default UTILS; |
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
3
-25%37987
-1.52%1350
-1.1%