Langsung ke konten
Skillpedia
API & server (backend)42k · #6445

competition-race-condition-state-drift

Fungsinya

Alat ini membantu membuat ulang masalah yang terjadi ketika beberapa aksi berlangsung bersamaan. Alat ini berfokus pada bagaimana urutan dan waktu aksi-aksi tersebut dapat menyebabkan error tak terduga, seperti data yang salah atau aksi yang terduplikasi.

Kapan dipakai

  • ✓Saat Anda menduga urutan aksi menyebabkan error.
  • ✓Untuk menguji apa yang terjadi jika dua hal mencoba mengubah data yang sama secara bersamaan.
  • ✓Untuk memahami bagaimana kegagalan sementara dapat menghasilkan hasil yang berbeda.

Link skill

https://github.com/zhaoxuya520/reverse-skill/blob/main/CTF-Sandbox-Orchestrator/competition-race-condition-state-drift/SKILL.md

Salin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.

Cara pakai

Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.

Pesan siap tempel

Gunakan skill ini untuk membantu saya: https://github.com/zhaoxuya520/reverse-skill/blob/main/CTF-Sandbox-Orchestrator/competition-race-condition-state-drift/SKILL.md Baca file SKILL.md di link tersebut dan ikuti instruksinya untuk tugas saya.
Mau AI Anda menemukan skill seperti ini sendiri?Pasang MCP Skillpedia gratis: cukup satu baris, dan AI mencari di antara 15.000+ skill sebelum tiap tugas.Pasang dalam 1 menit →

Contoh permintaan ke AI

“Saya ingin menguji apa yang terjadi jika dua orang mencoba menarik uang dari rekening yang sama secara bersamaan.”

5 skill baru setiap minggu. 1 menit baca.

Cara kerjanya

Alat ini mengidentifikasi bagian sistem yang dapat berubah (seperti data di database atau cache). Lalu alat ini mensimulasikan aksi bersamaan, hanya mengubah urutan atau waktunya, untuk melihat apakah hal itu menghasilkan hasil yang berbeda dari yang diharapkan.

Konten teknis (SKILL.md asli)

Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.

Competition Race Condition State Drift

Use this skill only as a downstream specialization after $ctf-sandbox-orchestrator is already active and has established sandbox assumptions, node ownership, and evidence priorities. If that has not happened yet, return to $ctf-sandbox-orchestrator first.

Use this skill when the decisive behavior depends on request timing, async ordering, lock gaps, or stale state.

Reply in Simplified Chinese unless the user explicitly requests English.

Quick Start

  1. Identify mutable state first: rows, cache keys, queue payloads, session fields, counters, or files.
  2. Reproduce with smallest concurrent sequence and fixed timing assumptions.
  3. Capture one baseline run and one racing run with only one variable changed.
  4. Track read, check, write, enqueue, and commit boundaries separately.
  5. Prove final state drift from a clean reset.

Workflow

1. Map Mutable Boundaries

  • Record transaction scope, lock behavior, retry logic, idempotency keys, cache invalidation, and queue handoff.
  • Note where read-check-write is split across requests, workers, or services.
  • Keep each boundary tied to exact timestamps or sequence numbers.

2. Reproduce Timing Window

  • Build deterministic concurrent inputs with controlled delay, duplicate requests, or reordered worker execution.
  • Compare accepted and rejected paths under identical payloads.
  • Record which condition flips when ordering changes.

3. Reduce To Decisive Race Chain

  • Compress to: request A and B ordering -> stale check or lock gap -> conflicting writes -> resulting capability or artifact.
  • State whether root cause is missing lock, weak idempotency, stale cache read, delayed async commit, or retry side effect.
  • If the path becomes queue-dominant, hand off to queue worker drift skill.

Read This Reference

  • Load references/race-condition-state-drift.md for race harness ideas, evidence blocks, and parity checks.

What To Preserve

  • Mutable keys, transaction boundaries, lock behavior, and idempotency markers
  • Timestamped or sequenced traces for baseline and race runs
  • One minimal replayable concurrent sequence proving drift
Pertanyaan umum

Apa itu 'state'?

State adalah informasi yang dimiliki sistem pada momen tertentu, seperti saldo rekening bank atau status pesanan.

Apa itu 'race condition'?

Itu adalah masalah yang terjadi ketika hasil sebuah operasi bergantung pada urutan pasti dari beberapa aksi yang berjalan bersamaan.

Mengapa 'urutan' itu penting?

Dalam sistem dengan banyak aksi yang terjadi bersamaan, urutan pemrosesan dapat mengubah hasil akhir. Jika urutannya tidak dikendalikan, error bisa terjadi.

Detail

Deskripsi asli dari pembuat

Internal downstream skill for ctf-sandbox-orchestrator. CTF-sandbox workflow for race windows, ordering bugs, idempotency failures, lock gaps, concurrent worker drift, and state inconsistencies that produce decisive effects. Use when the user asks to reproduce timing-sensitive bugs, concurrent state corruption, duplicate actions, stale reads, or privilege or balance drift caused by request orderin

repo: zhaoxuya520/reverse-skill

Popularitas

Bintang GitHub
42k
Peringkat
#6445
Lisensi
MIT
Diperbarui
22/9/2026

Apakah skill ini berguna?

0

Masuk untuk memberi suara.

Komentar

  • …

Skill lain dari repositori ini

Skill serupa