Token导航 LogoToken导航TokenDH.com
研究检索敏感数据github未标认证来源可访问许可证需确认审计通过

authentication-setup身份验证设置

Agent Skill

用于辅助安全审计、权限检查、凭据风险、认证流程和常见漏洞排查。它适合让 Agent 梳理敏感配置、检查依赖风险、分析鉴权逻辑或生成安全复核清单。使用时不能把工具输出直接当最终结论,涉及密钥、令牌、用户数据或生产系统时,应先确认最小权限、脱敏方式和操作边界。

总安装

220

周安装

9

GitHub Stars

2

下载量

71
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

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

skills.shnpx skills
npx skills add https://github.com/akillness/oh-my-gods --skill authentication-setup

简介

用于辅助身份验证流程设计和安全审计,适合梳理登录、令牌管理和权限边界。

  • 适用于新增登录流、选择 JWT/OAuth 模型或添加 MFA 验证的场景。
  • 使用时需明确最小权限原则,区分生产与测试环境,避免直接操作敏感凭据。
  • 安装命令:npx skills add https://github.com/akillness/oh-my-gods --skill authentication-setup。
  • 涉及密钥或用户数据时,应先确认脱敏策略和操作范围,不可直接落地生产配置。

SKILL.md

Authentication Setup

Authentication work is mostly boundary design: identity proof, session or token issuance, permission checks, and the operational controls that keep secrets and privileged actions safe. Keep this entrypoint compact, then pull the support files only when framework boilerplate or security detail is needed.

When to use this skill

  • Add login, signup, logout, refresh-token, or current-user flows
  • Choose between session auth, JWT auth, OAuth, SSO, or mixed auth models
  • Add RBAC, permission checks, or admin-only boundaries
  • Add MFA or step-up verification to an existing auth system
  • Migrate an existing service from one auth model to another
  • Review an auth implementation for obvious security and lifecycle gaps

Do not use this skill as the only source of truth for highly regulated identity requirements or custom cryptography design. In those cases, pair it with the project's security requirements and official vendor guidance.

Instructions

Step 1: Triage the auth shape before choosing an implementation

Capture the minimum facts first:

  • app type: API, SPA plus API, server-rendered app, mobile backend, internal tool
  • auth surface: email or password, magic link, session, JWT, OAuth, SSO, MFA
  • storage and runtime: framework, database, cache, reverse proxy, deployment model
  • trust boundary: user roles, privileged actions, tenant model, internal vs external users
  • operational needs: token revocation, account recovery, audit trail, device/session management

If the user has not chosen an auth model yet, stop and classify the product shape before writing code.

Step 2: Choose the auth model deliberately

Pick the smallest model that matches the product:

ModelPrefer whenWatch for
Session cookiesServer-rendered apps, admin tools, same-origin web appsCSRF, cookie flags, shared session storage
JWT access plus refreshAPIs, SPAs, mobile clients, distributed servicestoken rotation, revocation, refresh storage, secret rotation
OAuth or SSOThird-party identity, enterprise login, social sign-inredirect validation, account linking, provider outage handling
HybridExisting password login plus social or enterprise loginduplicate identities, upgrade path, privilege consistency

State the tradeoff briefly before implementing. If a stateless token model is not clearly required, do not default to JWT just because it is familiar.

Step 3: Design identity, secret, and persistence boundaries

Lock these decisions before endpoint work:

  • canonical user identity and unique identifiers
  • password hashing or external identity-only mode
  • refresh token or session persistence and revocation strategy
  • secret storage via environment or secret manager, never in source
  • audit fields such as verification state, last login, or MFA enrollment only when they matter

Minimum expectations:

  • passwords use bcrypt or argon2
  • access tokens are short-lived
  • refresh tokens or sessions can be revoked
  • privileged roles are stored and checked explicitly
  • secrets and provider credentials stay outside the repo

Detailed implementation recipes live in references/framework-recipes.md.

Step 4: Implement the core auth flows

Build only the flows the product actually needs:

  1. registration or account bootstrap
  2. login or provider callback
  3. logout or revocation
  4. refresh or session renewal
  5. current-user or claims lookup
  6. password reset or account recovery when requested

For every flow, make the boundary observable:

  • validate inputs
  • return consistent auth errors
  • avoid leaking whether an account exists unless the product explicitly requires it
  • persist or revoke refresh tokens or sessions deliberately
  • keep token payloads minimal

Step 5: Enforce authorization and operational defenses

Authentication proves identity. Authorization proves the caller can perform the action.

Always cover:

  • route or handler-level permission checks
  • default-deny behavior for privileged actions
  • rate limits on login, reset, and MFA verification
  • secure cookie settings or token transport rules
  • CORS or redirect allowlists where cross-origin flows exist
  • logging and monitoring that avoid passwords, tokens, or secrets

Use references/security-checklist.md for the hardening and common-failure checklist.

Step 6: Verify the risky paths, not just the happy path

Minimum auth verification should include:

  • successful login
  • invalid credentials
  • unauthorized access
  • forbidden access for the wrong role
  • expired or revoked refresh token or session
  • logout or revocation behavior
  • one recovery path if password reset or OAuth linking is in scope

When the user wants implementation, write or update the tests instead of stopping at advice. If the repository already has an auth system, review the current code before rewriting the model.

Step 7: Pull support files only when needed

Use the support files instead of bloating this entrypoint:

  • references/framework-recipes.md for schema, endpoint, Node/Python, and environment examples
  • references/security-checklist.md for hardening rules, rollout checks, and common auth failures

Output format

Expected response shape:

  • Auth surface: selected model and why
  • Plan: identity, storage, token or session, and permission decisions
  • Implementation: files or modules to create or modify
  • Verification: tests, manual checks, or review points
  • Gaps: deferred risks, compliance items, or rollout concerns

Examples

Example 1: Add JWT auth to a Node API

Input:

Add login, refresh-token, and admin-role protection to this Express API with PostgreSQL.

Output shape:

  • chooses JWT access plus refresh only if the client shape justifies it
  • includes password hashing and revocable refresh-token storage
  • adds permission checks for admin routes
  • verifies login, refresh, forbidden, and logout behavior

Example 2: Prefer sessions for a server-rendered app

Input:

Build secure auth for an internal admin dashboard with server-rendered pages and Redis available.

Output shape:

  • prefers session cookies over JWTs
  • includes secure cookie flags, CSRF protection, and Redis-backed session storage
  • keeps auth scoped to admin access and auditability

Example 3: Add social login to an existing product

Input:

Add Google sign-in to this app without breaking the existing email/password accounts.

Output shape:

  • covers provider callback validation and account-linking rules
  • avoids duplicate identities or accidental privilege escalation
  • explains what data to store from the provider and what to keep local

Best practices

  1. Choose the auth model from product shape, not from habit.
  2. Keep access tokens short-lived and revocable state explicit.
  3. Separate authentication from authorization in both code and reasoning.
  4. Never log secrets, passwords, raw tokens, or reset links.
  5. Add eval coverage before considering any skill-autoresearch loop on this skill.
  6. Push framework boilerplate and security detail into references so the main skill stays reviewable.

References

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

35.59%
按下载量换算25

Claude

33.18%
按下载量换算24

Cursor

18.11%
按下载量换算13

Gemini CLI

9.82%
按下载量换算7

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

敏感数据

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

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills