← 返回
未分类

数据加密

Backend Agent Data Encryption. High-security MK->KEK->DEK hierarchy for backend environments.
Backend Agent Data Encryption. High-security MK->KEK->DEK hierarchy for backend environments.
user_3faf7a6b
未分类 community v2.2.1 2 版本 100000 Key: 无需
★ 1
Stars
📥 121
下载
💾 1
安装
2
版本
#latest

概述

backendenc: Backend Security Toolkit

This skill provides mandatory encryption for OpenClaw agents running in Node.js/Backend environments. It operates in Local Manual Mode, using the Node.js built-in crypto module.

Context

Unlike the frontend version which uses Web Crypto, this version is designed for server-side execution, CLI tools, or background agents. It stores metadata in a persistent local file (or compatible storage provider).

Key Hierarchy

  1. Master Key (MK): Derived from your passphrase using crypto.pbkdf2.
    • Persistence: A unique "Salt" is stored in your configuration. As long as you remember your passphrase, the same Master Key will be generated across reboots.
  2. Key Encryption Key (KEK): Generated randomly and encrypted by your MK.
  3. Data Encryption Keys (DEKs): Scoped keys (e.g., memory, assets) encrypted by the KEK.

Security Disclosure

  • Zero Network: This skill does NOT perform any external network requests. All operations happen via the Node.js crypto module.
  • No Cleartext Keys: Keys are never stored in cleartext. They are always "wrapped" (encrypted) by a higher-level key using AES-256-GCM.
  • Passphrase Obligation: You must provide your passphrase to "unlock" the vault after هر server reboot.

Multi-User & Channel Isolation

Designed for high-concurrency backend environments:

  • Key Partitioning: All storage keys follow the ${userId}:${channelId}:key format.
  • Security: Ensures that even if the underlying storage file is compromised, keys for different users remain cryptographically separated.

Usage (Backend)

import { EncryptionService } from './encryption-service.js';

// Access context IDs
const { userId, channelId } = agent.context;

// Unlock for context
await EncryptionService.unlock(userId, channelId, 'passphrase');

// Scoped encryption
const encrypted = await EncryptionService.encrypt(userId, channelId, 'history', 'data');

版本历史

共 2 个版本

  • v2.2.1 Initial release 当前
    2026-04-18 23:21 安全 安全
  • v2.2.0 Initial release
    2026-04-18 23:08 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

dev-programming

YouTube

byungkyu
使用托管OAuth集成YouTube Data API,支持搜索视频、管理播放列表、获取频道数据及评论互动,适用于用户需要时使用此技能。
★ 142 📥 41,938
dev-programming

Mcporter

steipete
使用 mcporter CLI 直接列出、配置、认证及调用 MCP 服务器/工具(支持 HTTP 或 stdio),涵盖临时服务器、配置编辑及 CLI/类型生成功能。
★ 197 📥 68,021
dev-programming

Github

steipete
使用 `gh` CLI 与 GitHub 交互,通过 `gh issue`、`gh pr`、`gh run` 和 `gh api` 管理议题、PR、CI 运行及高级查询。
★ 681 📥 329,853