re-rtos

re-rtos is a skill for Claude Code from dslsdzc/rev-skills. It costs 99 tokens per session (5,336 once invoked), scanned A, original, Apache-2.0.

A guide to analysing firmware that runs a real-time operating system (RTOS), software designed to schedule tasks predictably on embedded devices. It covers FreeRTOS, ThreadX, Zephyr, QNX, and similar systems.

In plain words
What is it for?
Use it to find task tables and task-control blocks, identify scheduler and task entry points, reconstruct kernel objects, and organise a decompiler's analysis by task or thread.
Why use it?
Firmware without symbols or a file system can make it difficult to tell where tasks, queues, locks, timers, and other operating-system objects are used. This guide helps reconstruct that structure from the compiled image.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

Good fit Use it to find task tables and task-control blocks, identify scheduler and task entry points, reconstruct kernel objects, and organise a decompiler's analysis by task or thread.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/dslsdzc/rev-skills/re-rtos
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add dslsdzc/rev-skills --skill re-rtos
Clone the repo
git clone --depth 1 https://github.com/dslsdzc/rev-skills

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for re-rtos

README.md
[![agentmods](https://agentmods.dev/badge/skills/dslsdzc/rev-skills/re-rtos/github.svg)](https://agentmods.dev/skills/dslsdzc/rev-skills/re-rtos)
Your own site
<a href="https://agentmods.dev/skills/dslsdzc/rev-skills/re-rtos"><img src="https://agentmods.dev/badge/skills/dslsdzc/rev-skills/re-rtos/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for re-rtos

Your own site · 80×15
<a href="https://agentmods.dev/skills/dslsdzc/rev-skills/re-rtos"><img src="https://agentmods.dev/badge/skills/dslsdzc/rev-skills/re-rtos.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 99 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 5,336 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00099 $0.05336
Opus 5 $0.00049 $0.02668
Sonnet 5 $0.00020 $0.01067
Haiku 4.5 $0.00010 $0.00534

Measured 9d ago against content hash b516ec0e0ee7, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

re-rtos scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/re-rtos/SKILL.md · 111 lines

How it starts

The opening of the file, as written. The whole thing — 111 lines — stays where its author put it; the contents beside it link to each section on GitHub.

RTOS 结构分析(FreeRTOS / ThreadX / Zephyr / RT-Thread / VxWorks / QNX / INTEGRITY)

何时使用 / 何时不用

  • 用:MCU/IoT 固件跑 RTOS——定位任务表/TCB、按任务拆分反编译、还原队列/信号量/互斥/定时器等内核对象
  • 用:拿到的是裸镜像(无文件系统、无符号),需要从启动代码链找出调度器与全部任务入口
  • 用:商业 RTOS 固件(VxWorks/QNX/INTEGRITY)——车机中控、航电、工控场景,同样从任务/线程控制块定位出发,按进程/分区/任务拆分分析
  • 不用:裸机固件(无任务表/调度器,按普通 MCU 镜像分析,[[re-fw-extract]] → [[re-binary-core]])
  • 不用:Linux/Windows 内核(走 [[re-kernel]])
  • 不用:只需动态跑起来观察行为(走 [[re-fw-emulate]])

工具准备

本技能以纯静态分析为主(免沙箱,[[platform-tips]] 最高原则);需要动态验证时转 [[re-fw-emulate]]。工具可替换,方法为核心。

Ghidra(反编译与结构体定义主力)

  • 下载: GitHub NationalSecurityAgency/ghidra releases,解压即用(无需安装)
  • JDK 21(Ghidra 11.3+ 要求):
    • Linux: apt install openjdk-21-jdk / dnf install java-21-openjdk / pacman -S jdk21-openjdk
    • macOS: brew install openjdk@21brew install --cask temurin
    • Windows: choco install temurin21
  • 启动: ./ghidraRun(GUI)/ ./support/analyzeHeadless(无头)
  • 验证: java -version(须 21+);./support/analyzeHeadless -help 正常输出
  • 用法核心:Data Type Manager 定义 TCB/内核对象结构体后,类型传播会显著改善反编译质量

binwalk(镜像提取先行)

  • Linux: apt install binwalk(Debian/Ubuntu)/ dnf install binwalk / pacman -S binwalk
  • pip(跨平台、版本新): pip install binwalk
  • macOS: brew install binwalk
  • Windows/WSL: Windows 本机无官方包,用 WSL 内 Linux/pip 版
  • 验证: binwalk --version

python3(脚本化解析与批量标注)

  • Linux: apt install python3 / dnf install python3 / pacman -S python
  • macOS: 自带;Windows: 官方安装器或 choco install python
  • 验证: python3 --version
  • 用途: 批量搜特征串/魔数、按字段偏移解析任务表、生成 Ghidra 脚本自动标注任务名/入口

操作步骤

按顺序执行,每步结果存档(任务清单、内核对象表、Ghidra 工程)。

  1. 前置:镜像提取与格式识别(衔接 [[re-fw-extract]] 流程)

    • 先按 [[re-fw-extract]] 完成:binwalk 解包 / dd 按偏移切分 / file + readelf -h 确认架构与字节序(大端 ARM/MIPS 固件常见)
    • 产物通常是裸镜像(raw binary)或单个 ELF;记录 reset handler 入口与 RAM 基址(从链接脚本/启动代码推断)——任务表与 TCB 都在 RAM 区,按链接地址解读
    • 确认字节序与架构后再导入 Ghidra,避免整个分析白做
  2. RTOS 识别:启动代码链 + 特征串/符号搜索

    • 启动链形态:reset handler → 时钟/外设/内存初始化 → 创建任务(xTaskCreate / osThreadNew / tx_thread_create / k_thread_create / rt_thread_create / VxWorks taskSpawn(6.x 及更早常用;7 中仍存在,内部实现为 taskCreate+taskActivate)或 taskCreate(7 起,创建挂起任务需显式 taskActivate)/ QNX ThreadCreate / INTEGRITY ARINC 653 APEX CREATE_PROCESS)→ 调度器启动(vTaskStartScheduler / osKernelStart / tx_kernel_enter / rt_system_scheduler_start / VxWorks kernelInit / QNX 启动脚本拉起系统进程 / INTEGRITY START 进入运行态)。调度器启动调用点之前的代码全是初始化,不属于任何任务
    • 特征串:strings 搜内核名("FreeRTOS")、任务名("Idle" 等)、版本/断言串;ELF 未 strip 时直接搜符号(nm / Ghidra Symbol Table:pxCurrentTCB_tx_thread_created_list_kernelrt_thread_ready_priority_group
    • 商业 RTOS 特征串:VxWorks 任务名("tIdle" 空闲任务(VxWorks 6.x+)、"tRootTask" 根任务)与版本串;QNX 内核/镜像名("procnto"、"imagefs")与系统进程名(资源管理器惯用命名 io-*/devb-*/devc-*);INTEGRITY 分区名/进程名与 ARINC 653 APEX 服务名
    • ThreadX 无版本串可搜,靠调度入口 tx_kernel_enter + TX_THREAD 魔数 ID(步骤 3)确认
    • 不确定内核时:找 3-4 个任务创建调用点与调度入口的调用形态,对照各内核公开结构逐个排除

Read the full file on GitHub · 111 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 111 lines · 99 tokens per session scan A b516ec0e0ee7

Subscribe to this mod's changes

re-rtos is a skill published in the GitHub repository dslsdzc/rev-skills (54 stars, last pushed 14d ago), licensed Apache-2.0. It adds 99 tokens to every session and 5,336 once invoked, about $0.0005 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

analyzing-golang-malware-with-ghidra

Reverse engineer Go-compiled malware in Ghidra by parsing Go buildinfo and pclntab structures, recovering stripped/obfuscated function names (e.g. via GoResolver), and extracting embedded module/dependency strings and types from Go binaries. Use when analyzing a Go-language malware sample, deobfuscating a…

Youngmaidainon/Agent-Level-Up · 95 tokens

reverse-engineering-arm-binaries

Reverse engineers ARM/AArch64 malware by identifying the architecture and instruction set state (ARM/Thumb), parsing ELF/Mach-O ARM headers, and orienting analysis around the ARM calling convention. Activates for requests to reverse ARM binaries, analyze AArch64 malware, or handle ARM/Thumb instruction-set decoding.

meltedinhex/analyst-ai-pack · 69 tokens

analyzing-golang-malware-with-ghidra

Reverse engineer Go-compiled malware in Ghidra by parsing Go buildinfo and pclntab structures, recovering stripped/obfuscated function names (e.g. via GoResolver), and extracting embedded module/dependency strings and types from Go binaries. Use when analyzing a Go-language malware sample, deobfuscating a…

tradecatlabs/vibe-coding-cn · 95 tokens

analyzing-golang-malware-with-ghidra

Reverse engineer Go-compiled malware in Ghidra by parsing Go buildinfo and pclntab structures, recovering stripped/obfuscated function names (e.g. via GoResolver), and extracting embedded module/dependency strings and types from Go binaries. Use when analyzing a Go-language malware sample, deobfuscating a…

mukul975/Anthropic-Cybersecurity-Skills · 95 tokens

Reverse Engineering & Binary Analysis

Binary analysis, assembly interpretation, disassembly, decompilation, firmware RE, and protocol reverse engineering.

Masriyan/Claude-Code-CyberSecurity-Skill · 26 tokens

ot-ics-attack

A guide to assessing operational technology and industrial control systems such as SCADA, DCS, and PLC environments. These systems monitor and control physical processes and often use specialized network protocols.

wgpsec/AboutSecurity · 81 tokens