본문으로 건너뛰기
Skillpedia
배포 및 클라우드 (DevOps)35k · #8008

implementing-canary-tokens-for-network-intrusion

하는 일

이 도구는 ‘카나리 토큰’이라는 ‘디지털 경보기’를 만듭니다. 누군가 이 경보기에 접근하려고 하면 즉시 알림을 받습니다. 승인되지 않은 사람이 시스템에 침입하려고 하는지 알 수 있는 방법입니다.

사용하는 경우

  • ✓누군가 접근해서는 안 되는 파일이나 시스템에 접근하려는지 알고 싶을 때.
  • ✓승인되지 않은 접근에 대한 조기 경고 시스템을 만들 때.
  • ✓네트워크 안에서 한 시스템에서 다른 시스템으로 이동하는 침입자를 잡을 때.

스킬 링크

https://github.com/mukul975/Anthropic-Cybersecurity-Skills/blob/main/skills/implementing-canary-tokens-for-network-intrusion/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-canary-tokens-for-network-intrusion/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 Canary Tokens for Network Intrusion Detection

When to Use

  • When deploying deception-based tripwires across network infrastructure to detect intrusions
  • When building early warning systems that alert on unauthorized access to sensitive resources
  • When planting fake AWS credentials, DNS beacons, or HTTP tokens to catch attackers during lateral movement
  • When integrating canary token alerts with SOC workflows via Slack, Microsoft Teams, or SIEM webhooks
  • When complementing traditional IDS/IPS with zero-false-positive deception technology

Prerequisites

  • Python 3.8+ with requests library installed
  • Network access to canarytokens.org API (or self-hosted Canarytokens instance)
  • Webhook endpoint for alert delivery (Slack, Teams, email, or generic HTTP)
  • For Thinkst Canary enterprise: valid console domain and API auth token
  • Administrative access to target systems where tokens will be planted
  • Appropriate authorization for all deployment activities

Core Concepts

What Are Canary Tokens?

Canary tokens are digital tripwires -- resources that should never be accessed during normal operations. When an attacker interacts with a canary token, it immediately triggers an alert with near-zero false positives. Unlike signature-based detection, canary tokens detect attackers by their behavior (accessing bait resources) rather than matching known patterns.

Token Types for Network Intrusion Detection

Token Type Trigger Mechanism Best Placement Detection Scenario
DNS Token DNS resolution of FQDN Config files, scripts, internal docs Attacker reads configs during recon
HTTP Token HTTP GET to unique URL Internal wikis, bookmark files, HTML Attacker browses internal resources
AWS API Key AWS API call with fake creds .aws/credentials, env files, repos Attacker tests found credentials
Cloned Site Visit to cloned page Internal portals, admin panels Attacker accesses cloned services
SVN Token SVN checkout Repository configs Attacker clones repositories
SQL Server Database login attempt Connection strings, config files Attacker attempts DB access

Alert Flow Architecture

[Attacker Action] --> [Token Triggered] --> [Canarytokens Server]
                                                    |
                                            [Webhook POST]
                                                    |
                          +-------------------------+-------------------------+
                          |                         |                         |
                    [Slack Alert]           [Email Alert]             [SIEM Ingestion]
                          |                         |                         |
                    [SOC Analyst]           [On-Call Page]           [Correlation Rule]

Instructions

Step 1: Generate DNS Canary Tokens

DNS tokens are the most versatile -- they trigger on any DNS resolution, even from air-gapped networks with only DNS egress. The token is an FQDN that, when resolved, alerts the token owner.

import requests

# Create DNS canary token via Canarytokens.org
response = requests.post("https://canarytokens.org/generate", data={
    "type": "dns",
    "email": "soc@company.com",
    "memo": "Production database server - /etc/app/db.conf",
    "webhook_url": "https://hooks.slack.com/services/T.../B.../xxx"
}, timeout=15)

token_data = response.json()
dns_hostname = token_data["hostname"]
# Example: abc123def456.canarytokens.com

Plant DNS tokens in locations attackers commonly inspect:

  • /etc/hosts entries pointing to the canary FQDN
  • Application configuration files (database_host, backup_server)
  • SSH config files (~/.ssh/config) with canary hostnames
  • Internal DNS zone files as decoy A records
  • CI/CD pipeline environment variables

Step 2: Deploy HTTP Canary Tokens

HTTP tokens generate a unique URL that triggers on any HTTP request. They reveal the source IP, User-Agent, and other HTTP headers of the requester.

# Create HTTP token
response = requests.post("https://canarytokens.org/generate", data={
    "type": "http",
    "email": "soc@company.com",
    "memo": "Internal wiki - IT admin passwords page",
    "webhook_url": "https://hooks.slack.com/services/T.../B.../xxx"
}, timeout=15)

http_url = response.json()["url"]

…
자주 묻는 질문

‘카나리 토큰’이란 무엇인가요?

디지털 철사 덫과 같습니다. 정상적인 작업 중에는 접근되지 않아야 하는 자원이며, 누군가 접근하면 경고 신호가 됩니다.

백신 대신 ‘카나리 토큰’을 사용하는 이유는 무엇인가요?

백신은 알려진 위협을 찾습니다. 카나리 토큰은 행동을 기준으로 삼기 때문에 새롭고 알려지지 않은 것이라도 승인되지 않은 접근을 감지합니다.

어떤 종류의 ‘토큰’이 있나요?

누군가 인터넷 주소(DNS)를 조회하거나, 링크(HTTP)에 접근하거나, 가짜 클라우드 자격 증명(AWS API 키)을 사용하려고 할 때 작동하는 토큰 등이 있습니다.

상세 정보

작성자의 원본 설명

Deploys DNS, HTTP, and AWS API key canary tokens across network infrastructure to detect unauthorized access and lateral movement. Integrates with webhook alerting (Slack, Teams, email, generic HTTP) for real-time intrusion notifications. Provides automated token generation, placement strategies, and monitoring for enterprise network environments. Use when building deception-based network intrusio

repo: mukul975/Anthropic-Cybersecurity-Skills

인기도

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

이 스킬이 유용한가요?

0

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

댓글

  • …

이 저장소의 다른 스킬

비슷한 스킬