Token导航 LogoToken导航

Agent Skill · 开发

cryptography(cryptography 开发)

cryptography 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

cryptography 是开发类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为接触敏感数据;许可证信息还不明确,第三方扫描有提醒项,按安装量在开发类的 21,746 个 Skill 里排第 14,815。

总安装 659周安装 28GitHub Stars 6下载 231核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:cryptography(cryptography 开发)
来源仓库:https://github.com/hack23/homepage
仓库路径:skills/cryptography
安装命令:
npx skills add https://github.com/hack23/homepage --skill cryptography
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/hack23/homepage --skill cryptography

这个 Skill 是做什么的

开发类 Skill 面向写代码、改代码和排查问题,一般会读写仓库文件,部分还会执行构建或测试命令。

密码学开发技能处理 GitHub 协作信息,支持仓库状态与代码变更跟踪。适用于围绕 Issue、Pull Request 和分支管理的信息组织与整理任务。通过 npx skills add 命令安装,需查阅原始 README 了解具体功能细节。使用前应确认权限范围,避免对生产环境或私有仓库执行写操作。

建议在实际使用中验证输出,确保不引入安全风险或误判情况。

来源仓库内路径:skills/cryptography

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/hack23/homepage --skill cryptography;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

cryptography 怎么安装?

在终端执行 npx skills add https://github.com/hack23/homepage --skill cryptography。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

cryptography 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

cryptography 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

cryptography 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

cryptography 用的人多吗?

公开数据是累计安装 659 次,近一周安装 28 次,下载 231 次,GitHub 6 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

cryptography 安全吗?

第三方扫描有提醒项,说明存在需要人工确认的行为。安装前请打开源码看清它读了什么、联网到哪里。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理开发类任务、又不想每次都手写提示词的人。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

开发类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
skill-vetter

技能审查员 · OpenClaw

8,779,018986操作浏览器MIT-0通过
ontology

本体论 · OpenClaw

6,636,960576只读MIT-0通过
entra-app-registration

内部应用程序注册 · Codex、Claude

6,631,872764接触敏感数据未明确通过
entra-app-registration

内部应用程序注册 · Codex、Claude

3,757,680201接触敏感数据未明确通过
nano-banana-pro

纳米香蕉专业版 · OpenClaw

3,526,898364接触敏感数据MIT-0有提醒
cryptography

cryptography 开发 · 本页

6596接触敏感数据未明确有提醒

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Cryptography Skill

Purpose

This skill enforces cryptographic requirements as defined in the Hack23 ISMS Cryptographic Controls Policy. It ensures that all cryptographic operations use approved algorithms and follow best practices for key management.

Rules

Approved Algorithms

Symmetric Encryption - MUST USE:

  • AES-256 (Advanced Encryption Standard, 256-bit key)
  • AES-128 (minimum, prefer AES-256)
  • ChaCha20-Poly1305 (for authenticated encryption)

Asymmetric Encryption - MUST USE:

  • RSA-2048 or higher (minimum 2048-bit key, prefer 3072 or 4096)
  • ECDSA with P-256, P-384, or P-521 curves
  • Ed25519 (EdDSA with Curve25519)

Hashing - MUST USE:

  • SHA-256 (minimum)
  • SHA-384
  • SHA-512
  • SHA-3 family
  • BLAKE2 (for high-performance applications)

Password Hashing - MUST USE:

  • bcrypt (cost factor 12 minimum)
  • scrypt
  • Argon2id (preferred)
  • PBKDF2 with SHA-256, minimum 100,000 iterations

Message Authentication - MUST USE:

  • HMAC-SHA256 (minimum)
  • HMAC-SHA512

MUST NOT USE (Deprecated/Broken):

  • DES, 3DES
  • MD5, SHA-1 (except for non-security purposes like checksums)
  • RC4
  • RSA < 2048 bits
  • CBC mode without authenticated encryption
  • ECB mode (ever)

TLS/SSL Requirements

MUST:

  • Use TLS 1.2 as minimum
  • Prefer TLS 1.3
  • Use strong cipher suites only
  • Verify server certificates
  • Use certificate pinning for high-security applications
  • Enforce HSTS (HTTP Strict Transport Security)
  • Use Perfect Forward Secrecy (PFS) cipher suites

TLS 1.2 Approved Cipher Suites (in order of preference):

TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384
TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256
TLS_DHE_RSA_WITH_AES_256_GCM_SHA384
TLS_DHE_RSA_WITH_AES_128_GCM_SHA256

TLS 1.3 Approved Cipher Suites:

TLS_AES_256_GCM_SHA384
TLS_AES_128_GCM_SHA256
TLS_CHACHA20_POLY1305_SHA256

MUST NOT:

  • Use SSL 2.0, SSL 3.0, TLS 1.0, TLS 1.1
  • Use export-grade ciphers
  • Use NULL cipher suites
  • Use anonymous cipher suites
  • Accept self-signed certificates in production (except for explicitly trusted CAs)

Key Management

MUST:

  • Generate keys using cryptographically secure random number generators (CSPRNGs)
  • Store keys securely (use key management systems, HSMs for highly sensitive keys)
  • Never hardcode keys in source code
  • Use environment variables or secret management systems
  • Rotate keys according to schedule:

- TLS certificates: Annually or before expiry - Symmetric keys: Annually for CONFIDENTIAL data, quarterly for RESTRICTED - API keys: Annually or on compromise - Passwords: 90 days for privileged accounts

  • Destroy keys securely when no longer needed
  • Log key lifecycle events (creation, rotation, destruction)
  • Separate key generation from key usage
  • Use different keys for different purposes
  • Implement key escrow for business continuity (with strict controls)

Key Length Requirements:

  • AES: 256 bits (128 minimum)
  • RSA: 2048 bits minimum (prefer 3072 or 4096)
  • ECDSA: P-256 minimum (prefer P-384 or P-521)
  • HMAC: 256 bits minimum

MUST NOT:

  • Store keys in plaintext
  • Commit keys to version control
  • Send keys via email or unencrypted channels
  • Reuse keys across different applications or contexts
  • Use weak key derivation functions
  • Share private keys

Random Number Generation

MUST:

  • Use cryptographically secure PRNGs (CSPRNGs)
  • For Node.js: crypto.randomBytes(), crypto.randomInt()
  • For Python: secrets module, os.urandom()
  • For Java: SecureRandom
  • For browser: window.crypto.getRandomValues()

MUST NOT:

  • Use Math.random() for security purposes
  • Use predictable seeds
  • Use non-cryptographic PRNGs for security tokens, keys, or IVs

Initialization Vectors (IVs) and Nonces

MUST:

  • Generate unique IV/nonce for each encryption operation
  • Use cryptographically random IVs for CBC mode
  • Use sequential nonces for CTR/GCM modes (ensure uniqueness)
  • Store IV with ciphertext (IVs are not secret)
  • Never reuse IV with same key

MUST NOT:

  • Use predictable or sequential IVs with CBC mode
  • Reuse nonces with same key in CTR/GCM modes
  • Treat IVs as secrets (they should be random but can be public)

Certificate Management

MUST:

  • Use certificates from trusted Certificate Authorities (CAs)
  • Validate certificate chains
  • Check certificate revocation status (CRL/OCSP)
  • Use Subject Alternative Names (SANs) for multiple domains
  • Implement certificate expiry monitoring and alerting
  • Renew certificates before expiry (30-day minimum buffer)
  • Use automated certificate management (e.g., Let's Encrypt with auto-renewal)
  • Store private keys securely (encrypted, access-controlled)
  • Use separate certificates for different services/environments

Certificate Validity:

  • Production: Maximum 1 year
  • Development/Testing: Maximum 90 days
  • Internal CA: Maximum 2 years

MUST NOT:

  • Use self-signed certificates in production (except for internal CA)
  • Share private keys between certificates
  • Use wildcard certificates without proper access controls
  • Ignore certificate warnings or errors

Encryption at Rest

MUST:

  • Encrypt CONFIDENTIAL and RESTRICTED data at rest
  • Use full disk encryption for laptops and mobile devices
  • Use database encryption (TDE) for sensitive databases
  • Encrypt sensitive files before storage in cloud services
  • Use envelope encryption (encrypt data key with master key)
  • Store encryption keys separately from encrypted data

MUST NOT:

  • Store unencrypted CONFIDENTIAL or RESTRICTED data
  • Use same key for encryption and authentication
  • Use deterministic encryption for high-sensitivity data

Encryption in Transit

MUST:

  • Use TLS 1.2+ for all network communications
  • Encrypt email containing CONFIDENTIAL or RESTRICTED data (S/MIME or PGP)
  • Use VPN for remote access to internal systems
  • Use SSH (not Telnet) for remote administration
  • Use HTTPS for all web applications
  • Use secure protocols (SFTP, FTPS, not FTP)

MUST NOT:

  • Transmit RESTRICTED data over unencrypted channels
  • Use unencrypted protocols (HTTP, FTP, Telnet, SMTP without TLS)
  • Disable certificate verification

Examples

Example 1: Symmetric Encryption (Node.js)

const crypto = require('crypto');

// GOOD: AES-256-GCM encryption
function encrypt(plaintext, key) {
  // Generate random IV (12 bytes for GCM)
  const iv = crypto.randomBytes(12);

  // Create cipher
  const cipher = crypto.createCipheriv('aes-256-gcm', key, iv);

  // Encrypt
  let ciphertext = cipher.update(plaintext, 'utf8', 'hex');
  ciphertext += cipher.final('hex');

  // Get authentication tag
  const authTag = cipher.getAuthTag();

  // Return IV + authTag + ciphertext
  return {
    iv: iv.toString('hex'),
    authTag: authTag.toString('hex'),
    ciphertext: ciphertext
  };
}

function decrypt(encrypted, key) {
  // Create decipher
  const decipher = crypto.createDecipheriv(
    'aes-256-gcm',
    key,
    Buffer.from(encrypted.iv, 'hex')
  );

  // Set authentication tag
  decipher.setAuthTag(Buffer.from(encrypted.authTag, 'hex'));

  // Decrypt
  let plaintext = decipher.update(encrypted.ciphertext, 'hex', 'utf8');
  plaintext += decipher.final('utf8');

  return plaintext;
}

// Generate secure key (store securely, don't hardcode!)
const key = crypto.randomBytes(32); // 256 bits

// Usage
const encrypted = encrypt('Sensitive data', key);
console.log('Encrypted:', encrypted);

const decrypted = decrypt(encrypted, key);
console.log('Decrypted:', decrypted);

// BAD: Using deprecated algorithm
function encryptBad(plaintext, key) {
  // NEVER use DES!
  const cipher = crypto.createCipheriv('des-ede3-cbc', key, iv);
  return cipher.update(plaintext, 'utf8', 'hex') + cipher.final('hex');
}

Example 2: Password Hashing (Node.js with bcrypt)

const bcrypt = require('bcrypt');

// GOOD: bcrypt with appropriate cost factor
async function hashPassword(password) {
  // Cost factor 12 = 2^12 iterations (minimum)
  const saltRounds = 12;
  const hash = await bcrypt.hash(password, saltRounds);
  return hash;
}

async function verifyPassword(password, hash) {
  return await bcrypt.compare(password, hash);
}

// Usage
const password = 'MySecurePassword123!';
const hash = await hashPassword(password);
console.log('Hash:', hash);

const isValid = await verifyPassword(password, hash);
console.log('Valid:', isValid);

// BAD: Using weak hashing
function hashPasswordBad(password) {
  // NEVER use MD5 or SHA-1 for passwords!
  return crypto.createHash('md5').update(password).digest('hex');
}

// BAD: Insufficient iterations
async function hashPasswordWeak(password) {
  // Cost factor 4 is too weak!
  return await bcrypt.hash(password, 4);
}

Example 3: Secure Random Generation

const crypto = require('crypto');

// GOOD: Cryptographically secure random
function generateToken(length = 32) {
  return crypto.randomBytes(length).toString('hex');
}

function generateApiKey() {
  return crypto.randomBytes(32).toString('base64');
}

function generateSecurePin(digits = 6) {
  const max = Math.pow(10, digits);
  return crypto.randomInt(0, max).toString().padStart(digits, '0');
}

// Usage
const sessionToken = generateToken();
const apiKey = generateApiKey();
const pin = generateSecurePin(6);

// BAD: Using Math.random() for security
function generateTokenBad() {
  // NEVER use Math.random() for security!
  return Math.random().toString(36).substring(2);
}

Example 4: TLS Configuration (Node.js HTTPS Server)

const https = require('https');
const fs = require('fs');

// GOOD: Secure TLS configuration
const options = {
  key: fs.readFileSync('/path/to/private-key.pem'),
  cert: fs.readFileSync('/path/to/certificate.pem'),
  ca: fs.readFileSync('/path/to/ca-bundle.pem'),

  // TLS 1.2 minimum
  minVersion: 'TLSv1.2',

  // Prefer TLS 1.3
  maxVersion: 'TLSv1.3',

  // Strong cipher suites only
  ciphers: [
    'TLS_AES_256_GCM_SHA384',
    'TLS_AES_128_GCM_SHA256',
    'TLS_CHACHA20_POLY1305_SHA256',
    'ECDHE-RSA-AES256-GCM-SHA384',
    'ECDHE-RSA-AES128-GCM-SHA256',
    'ECDHE-ECDSA-AES256-GCM-SHA384',
    'ECDHE-ECDSA-AES128-GCM-SHA256'
  ].join(':'),

  // Prefer server cipher order
  honorCipherOrder: true,

  // Enable Perfect Forward Secrecy
  ecdhCurve: 'prime256v1:secp384r1:secp521r1',

  // Require client certificate (if needed)
  requestCert: false,
  rejectUnauthorized: true
};

const server = https.createServer(options, (req, res) => {
  // Set security headers
  res.setHeader('Strict-Transport-Security', 'max-age=31536000; includeSubDomains; preload');
  res.setHeader('X-Content-Type-Options', 'nosniff');
  res.setHeader('X-Frame-Options', 'DENY');

  res.writeHead(200);
  res.end('Secure connection');
});

server.listen(443);

// BAD: Weak TLS configuration
const optionsBad = {
  key: fs.readFileSync('/path/to/private-key.pem'),
  cert: fs.readFileSync('/path/to/certificate.pem'),

  // NEVER allow TLS 1.0/1.1
  minVersion: 'TLSv1.0', // TOO WEAK!

  // Allowing weak ciphers
  ciphers: 'ALL', // INSECURE!

  // Not rejecting unauthorized
  rejectUnauthorized: false // DANGEROUS!
};

Example 5: Key Derivation (PBKDF2)

const crypto = require('crypto');

// Derive encryption key from password
function deriveKey(password, salt, keyLength = 32) {
  // Use PBKDF2 with SHA-256, 100,000 iterations minimum
  return crypto.pbkdf2Sync(
    password,
    salt,
    100000, // iterations (minimum)
    keyLength,
    'sha256'
  );
}

// Usage
const password = 'UserPassword123!';
const salt = crypto.randomBytes(16); // Store salt with encrypted data
const key = deriveKey(password, salt, 32); // 256-bit key

console.log('Derived key:', key.toString('hex'));

// BAD: Weak key derivation
function deriveKeyWeak(password) {
  // NEVER use simple hashing for key derivation!
  return crypto.createHash('sha256').update(password).digest();
}

Example 6: Secure File Encryption

const crypto = require('crypto');
const fs = require('fs').promises;

async function encryptFile(inputPath, outputPath, key) {
  // Read file
  const plaintext = await fs.readFile(inputPath);

  // Generate IV
  const iv = crypto.randomBytes(12);

  // Encrypt
  const cipher = crypto.createCipheriv('aes-256-gcm', key, iv);
  const ciphertext = Buffer.concat([
    cipher.update(plaintext),
    cipher.final()
  ]);

  // Get auth tag
  const authTag = cipher.getAuthTag();

  // Write IV + authTag + ciphertext
  const encrypted = Buffer.concat([iv, authTag, ciphertext]);
  await fs.writeFile(outputPath, encrypted);
}

async function decryptFile(inputPath, outputPath, key) {
  // Read encrypted file
  const encrypted = await fs.readFile(inputPath);

  // Extract IV, auth tag, and ciphertext
  const iv = encrypted.slice(0, 12);
  const authTag = encrypted.slice(12, 28);
  const ciphertext = encrypted.slice(28);

  // Decrypt
  const decipher = crypto.createDecipheriv('aes-256-gcm', key, iv);
  decipher.setAuthTag(authTag);

  const plaintext = Buffer.concat([
    decipher.update(ciphertext),
    decipher.final()
  ]);

  // Write decrypted file
  await fs.writeFile(outputPath, plaintext);
}

// Usage
const key = crypto.randomBytes(32);
await encryptFile('sensitive.pdf', 'sensitive.pdf.enc', key);
await decryptFile('sensitive.pdf.enc', 'sensitive-decrypted.pdf', key);

Example 7: Certificate Validation

const https = require('https');
const tls = require('tls');

// GOOD: Verify certificate
function makeSecureRequest(url) {
  return new Promise((resolve, reject) => {
    https.get(url, {
      // Verify certificate chain
      rejectUnauthorized: true,

      // Check hostname
      checkServerIdentity: (hostname, cert) => {
        const err = tls.checkServerIdentity(hostname, cert);
        if (err) {
          return err;
        }

        // Additional checks
        const now = new Date();
        const notBefore = new Date(cert.valid_from);
        const notAfter = new Date(cert.valid_to);

        if (now < notBefore || now > notAfter) {
          return new Error('Certificate not valid for current date');
        }

        return undefined;
      }
    }, (res) => {
      let data = '';
      res.on('data', chunk => data += chunk);
      res.on('end', () => resolve(data));
    }).on('error', reject);
  });
}

// BAD: Skipping certificate verification
function makeInsecureRequest(url) {
  return new Promise((resolve, reject) => {
    https.get(url, {
      // NEVER disable certificate verification!
      rejectUnauthorized: false // DANGEROUS!
    }, (res) => {
      let data = '';
      res.on('data', chunk => data += chunk);
      res.on('end', () => resolve(data));
    }).on('error', reject);
  });
}

Related ISMS Policies

Related Documentation

Compliance Mapping

ISO 27001:2022

  • A.8.24 Use of cryptography

NIST Cybersecurity Framework

  • PR.DS-1: Data-at-rest is protected
  • PR.DS-2: Data-in-transit is protected

CIS Controls

  • Control 3: Data Protection

- 3.10 Encrypt Sensitive Data in Transit - 3.11 Encrypt Sensitive Data at Rest

Key Rotation Schedule

Key TypeRotation FrequencyTrigger for Immediate Rotation
TLS CertificatesAnnuallyCompromise, algorithm weakness
Symmetric Keys (RESTRICTED)QuarterlyCompromise, employee departure
Symmetric Keys (CONFIDENTIAL)AnnuallyCompromise
API KeysAnnuallyCompromise, employee departure
SSH Keys2 yearsCompromise
Root CA Keys10 yearsCompromise
Database Encryption Keys2 yearsCompromise

Enforcement

Violations of cryptographic requirements:

  • Critical (use of banned algorithms, hardcoded keys): Block deployment
  • High (weak configurations, missing encryption): Require immediate remediation
  • Medium (suboptimal configurations): Remediate within sprint

平台分布

Codex

34.62%
按下载量换算80

Claude

29.51%
按下载量换算68

Cursor

18.8%
按下载量换算43

Gemini CLI

10.15%
按下载量换算23

安全审计

Gen Agent Trust Hub

通过

Socket

可疑

Snyk

通过

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills