본문으로 건너뛰기
Skillpedia
보안35k · #8051

implementing-hardware-security-key-authentication

하는 일

이 도구는 실제 보안 키(예: YubiKey)나 기기의 기능(예: 지문)을 사용해 안전한 로그인 시스템을 만들도록 돕습니다. 비밀번호를 대체하거나 보완하여 해커가 접근하기 어렵게 만듭니다.

사용하는 경우

  • ✓중요한 계정을 추가 보안 방식으로 보호하고 싶을 때.
  • ✓더 안전한 로그인이 필요한 웹사이트나 앱을 만들 때.
  • ✓보안 키만으로 비밀번호 없이 로그인할 수 있도록 하려는 경우.

스킬 링크

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/implementing-hardware-security-key-authentication/SKILL.md

복사해서 AI(Claude, ChatGPT, Cursor)에 붙여넣고 지침을 따르도록 요청하세요.

사용 방법

가장 쉬운 방법입니다. 메시지를 복사해 AI에 붙여넣으세요. AI가 스킬을 읽고 지침을 따릅니다.

바로 붙여넣을 수 있는 메시지

Use this skill to help me: https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/implementing-hardware-security-key-authentication/SKILL.md Read the SKILL.md file at that link and follow its instructions for my task.
AI가 이런 스킬을 알아서 찾아 쓰길 원하시나요?무료 Skillpedia MCP를 설치하세요. 한 줄이면 작업마다 스킬 15,000+개 중에서 검색합니다.1분 만에 설치 →

AI에게 요청하는 예시

“보안 키를 사용해 제 웹사이트에 안전한 로그인을 설정해 주세요.”

매주 새 스킬 5개. 읽는 데 1분.

작동 방식

이 도구는 보안 키와 통신하도록 서버를 설정합니다. 새 키의 등록과 로그인 시의 검증을 관리해, 키의 소유자만 접근할 수 있도록 합니다.

기술 내용 (원본 SKILL.md)

작성자의 영어 원문을 GitHub에서 그대로 가져왔습니다.

Implementing Hardware Security Key Authentication

When to Use

  • Deploying phishing-resistant multi-factor authentication (MFA) using FIDO2 hardware security keys for high-value accounts (administrators, developers, privileged users)
  • Building a WebAuthn relying party server that supports both roaming authenticators (USB/NFC security keys) and platform authenticators (Windows Hello, Touch ID, Android biometrics)
  • Migrating an existing password-based authentication system to support passkeys (discoverable credentials) as a primary or secondary authentication factor
  • Enrolling YubiKey devices for an organization's workforce, including PIN setup, credential registration, and backup key provisioning
  • Implementing passwordless authentication flows that comply with NIST SP 800-63B AAL3 (authenticator assurance level 3) requirements

Do not use without HTTPS in production (WebAuthn requires a secure origin), for systems where users cannot physically access a USB/NFC port, or as the sole authentication factor without a recovery mechanism for lost keys.

Prerequisites

  • Python 3.10+ with fido2 (python-fido2 >= 2.0.0), flask, and cryptography libraries installed
  • HTTPS-enabled web server (WebAuthn API requires secure context; localhost is exempt for development)
  • FIDO2-compatible hardware security key (YubiKey 5 Series, SoloKeys, Titan Security Key) or platform authenticator
  • Modern web browser supporting the WebAuthn API (Chrome 67+, Firefox 60+, Safari 14+, Edge 79+)
  • Understanding of public key cryptography, challenge-response protocols, and HTTP session management

Workflow

Step 1: Relying Party Server Configuration

Configure the WebAuthn relying party (RP) identity and server:

  • Define RP identity: Create a PublicKeyCredentialRpEntity with the relying party name (display name shown to users) and RP ID (the effective domain of the application). The RP ID must be a registrable domain suffix of the origin -- for example, example.com is valid for https://auth.example.com but other.com is not.
  • Initialize Fido2Server: Instantiate the Fido2Server class from the python-fido2 library with the RP entity. The server handles challenge generation, attestation verification, and assertion validation.
  • Configure attestation preference: Set the attestation conveyance preference to control whether the server requests proof of the authenticator's identity:
    • none: No attestation requested (simplest, recommended for most deployments)
    • indirect: Attestation may be provided but CA may anonymize it
    • direct: Full attestation chain from the authenticator's manufacturer
    • enterprise: Device-identifying attestation for managed environments
  • Session management: Configure server-side sessions to store WebAuthn state between the begin and complete phases of registration/authentication ceremonies. Use secure, httponly cookies with SameSite=Strict.
  • Credential storage: Design the database schema to store credential records: credential_id (binary), public_key (COSE key), sign_count (uint32 for clone detection), user_id, created_at, last_used, display_name, and transports (USB, NFC, BLE, internal).

Step 2: Registration Ceremony (Credential Creation)

Implement the WebAuthn registration flow to create new credentials:

  • Begin registration: Call server.register_begin() with the user entity (PublicKeyCredentialUserEntity containing user ID, username, and display name), the list of existing credentials for the user (to prevent duplicate registration), and options for user_verification and authenticator_attachment.
  • Authenticator selection criteria:
    • authenticator_attachment: cross-platform restricts to roaming authenticators (USB/NFC keys)
    • authenticator_attachment: platform restricts to built-in authenticators (Touch ID, Windows Hello)
    • Omitting this field allows both types
    • resident_key: required forces creation of a discoverable credential (passkey) stored on the authenticator
    • user_verification: required enforces PIN or biometric verification on the authenticator
  • Client-side ceremony: The browser calls navigator.credentials.create() with the options from the server. The authenticator generates a new key pair, stores the private key in its secure element, and returns the public key, credential ID, attestation object, and client data JSON.

…

자주 묻는 질문

실제 보안 키가 꼭 필요한가요?

꼭 그렇지는 않습니다. YubiKey 같은 실제 키를 사용하거나, Windows Hello나 Touch ID 같은 컴퓨터나 휴대폰의 기능을 사용할 수 있습니다.

‘피싱 저항성’이란 무엇을 의미하나요?

해커가 가지고 있지 않은 실제 기기나 생체 인식에 의존하므로, 가짜 이메일이나 웹사이트로 속이기가 훨씬 어렵다는 뜻입니다.

어떤 웹사이트에서나 사용할 수 있나요?

직접 만들거나 관리하는 웹사이트와 앱에 가장 적합합니다. 단순히 이용하는 웹사이트는 해당 웹사이트가 이 옵션을 제공하면 켤 수 있습니다.

상세 정보

작성자의 원본 설명

Builds a FIDO2/WebAuthn relying party server with the python-fido2 library, covering registration and authentication ceremonies, YubiKey enrollment, resident key (discoverable credential/passkey) workflows, and user verification policies. Use when implementing phishing-resistant MFA with hardware security keys, building a WebAuthn relying party, enrolling YubiKeys for a workforce, or migrating pas

repo: mukul975/Anthropic-Cybersecurity-Skills

인기도

GitHub 스타
35k
순위
#8051
라이선스
Apache-2.0
업데이트
2026. 8. 31.

이 스킬이 유용한가요?

0

로그인 투표하려면 로그인하세요.

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬