Chuyển đến nội dung
Skillpedia
Bảo mật48k · #4898

hunt-session

Skill này làm gì

Công cụ này giúp kiểm tra xem phiên đăng nhập của người dùng trên website và ứng dụng có an toàn hay không. Nó tìm các lỗi có thể cho phép kẻ tấn công truy cập tài khoản của người khác, ngay cả sau khi người dùng đã đăng xuất hoặc đổi mật khẩu.

Khi nào nên dùng

  • ✓Khi bạn kiểm tra bảo mật của một website hoặc ứng dụng.
  • ✓Khi bạn kiểm tra xem đăng xuất có thực sự kết thúc phiên đăng nhập hay không.
  • ✓Khi bạn kiểm tra xem việc đổi mật khẩu có vô hiệu hóa các phiên cũ hay không.

Liên kết skill

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/hunt-session/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/hunt-session/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Kiểm tra bảo mật quản lý phiên cho website example.com”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Công cụ mô phỏng các thao tác như đăng nhập, đăng xuất và đổi mật khẩu, rồi quan sát xem phiên của người dùng có bị vô hiệu hóa đúng cách hay không. Nó tìm các mẫu lỗi quản lý phiên đã biết.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

⚠️ AUTHORIZED USE ONLY This skill is for educational purposes or authorized security assessments only. You must have explicit, written permission from the system owner before using this tool. Misuse of this tool is illegal and strictly prohibited.

Mandatory confirmation gate Before running any command that probes, exploits, changes, persists on, extracts data from, or attempts credential access against a target:

  1. Ask the user to state the exact target URL, IP, account, or resource.
  2. Ask the user to confirm written authorization and the permitted scope.
  3. Show the exact command(s) and explain their expected effect.
  4. Wait for explicit confirmation in the current conversation.

Without that confirmation, remain read-only and provide defensive guidance only. Prefer a sandbox, disposable VM, or controlled lab.

Autonomous Testing Priority

Missing HttpOnly on cookies is auto-detected — focus your active testing on lifecycle invalidation (higher impact).

Pattern 1 — Session survives logout (most common high-value finding):

  1. Login and note the session token/cookie value
  2. Call the logout endpoint (/logout, POST /api/logout, etc.)
  3. Try to use the OLD session token to access a protected resource (/api/me, /dashboard, /account)
  4. If 200 with user data → session not invalidated on logout = ATO persistence

Pattern 2 — Session not regenerated on login (session fixation):

  1. GET any page to receive a pre-authentication session token/cookie
  2. POST valid credentials to the login endpoint
  3. Compare the session token BEFORE and AFTER login
  4. If the token is unchanged → session fixation vulnerability

Pattern 3 — Session survives password change:

  1. Login → record session A value
  2. Change the password via the account settings endpoint
  3. Replay session A on a protected endpoint
  4. If 200 → token not rotated on credential change = persistent ATO (critical chain when combined with XSS/cookie theft)

Content-type: Login and session endpoints vary — use application/json for REST APIs, application/x-www-form-urlencoded for traditional web forms. Try both if the first returns an unexpected response.

Proof: A protected-resource 200 response (with user data) using a session token that should have been invalidated confirms the finding.


HUNT-SESSION — Session Management

Crown Jewel Targets

Session fixation leading to admin hijack = Critical. Session surviving a password change = High-to-Critical (persistent ATO from a stolen cookie that the victim believes they revoked by resetting their password).

Highest-value chains:

  • Session fixation — server accepts a session ID set by the client and does NOT regenerate it on login → attacker pre-plants an ID, victim authenticates, attacker rides the now-authenticated session → persistent ATO.
  • No invalidation on logout — old token still works after /logout → theft window never closes.
  • No invalidation on password / email change — a stolen session survives the victim's "I think I was hacked, let me reset" → persistent ATO. This is the single highest-paid session bug class.
  • Refresh-token reuse without rotation-detection — a leaked refresh token mints fresh access tokens forever; no reuse-detection means the legitimate user's later refresh does NOT revoke the attacker's branch.
  • Predictable / low-entropy session ID — sequential, timestamp- or userId-derived IDs → brute-force or compute other users' sessions.
  • JWT-as-session with no exp / no revocation list — stolen JWT = permanent access; logout is cosmetic.

Grounding — patterns that shaped each phase

No invented CVE/report IDs below. These are the named, publicly-documented patterns this skill encodes:

  • Session fixation, login-CSRF, no-regeneration-on-auth — OWASP WSTG-SESS-03 / WSTG-SESS-01; the classic ACROS / Mitja Kolšek session-fixation paper. Highest-impact variant: fixing the session of an SSO/admin user.
  • SameSite=Lax sibling-subdomain CSRF reaching session state — Argo CD CVE-2024-22424 (Lax cookies sent on top-level cross-site navigations from a sibling subdomain). Use this when a session cookie relies on SameSite=Lax as its only CSRF defence.
  • Refresh-token rotation & automatic reuse-detection — the Auth0/IETF OAuth-Security-BCP model: a rotated refresh token, if replayed, must invalidate the entire token family. Absence = the core bug to prove.

…

Câu hỏi thường gặp

“Phiên” (session) là gì?

Phiên giống như một thẻ tạm thời mà website cấp cho bạn sau khi đăng nhập, để nhận ra bạn trong những lần truy cập sau mà không cần hỏi lại mật khẩu.

“Vô hiệu hóa phiên” là gì?

Đó là quá trình “đăng xuất” hoặc kết thúc phiên của người dùng, đảm bảo thẻ tạm thời đó không còn hoạt động nữa.

Tại sao kiểm tra việc này lại quan trọng?

Nếu phiên không được vô hiệu hóa đúng cách, kẻ tấn công có thể dùng thẻ cũ (ngay cả sau khi đăng xuất) để tiếp tục truy cập tài khoản của nạn nhân.

Chi tiết

Mô tả gốc của tác giả

Hunt Session Management vulnerabilities

repo: sickn33/agentic-awesome-skills

Độ phổ biến

Sao GitHub
48k
Vị trí xếp hạng
#4898
Giấy phép
MIT
Cập nhật
15/10/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự