rpfd

io.github.molchalih由 GitHub 账号 molchalih 发布v0.3.1更新于 Oct 24, 2026

Read and write RAGE Package Format archives

已验证STDIO仅桌面文件与存储开发者工具

概览

AI 生成的概览

读取、编辑并重建 RAGE 包格式(RPF7)归档,例如 GTA V 与 FiveM/RAGE MP 的 dlc.rpf 文件,以 MCP 服务器形式提供。

可以做什么
  • 递归列出归档内容,包括归档内嵌套的归档
  • 读取条目,pso、rbf 和 meta 载荷可转为 XML 视图
  • 就地写回编辑后的条目,或通过完整重建来创建、删除、移动条目和新建目录
  • 把归档解包到文件夹、把文件夹打包成归档,并对照记录的校验和验证结果
  • 从游戏可执行文件中提取并缓存解密密钥材料,并报告密钥缓存位置
适用场景
适合需要查看或修改 GTA V 或 FiveM/RAGE MP 的 RPF7 归档的场景,例如浏览 dlc.rpf、编辑元数据或 XML 条目、解包并重新打包模组归档。不适用于 RPF8、RPF6 及更早格式,这些会被拒绝。
运行要求
作为本地进程在桌面端运行;清单未声明任何环境变量或请求头。提供 macOS、Windows 和 Linux 的预编译二进制,也可用固定版本的 Rust 工具链从源码构建。加密归档需要从用户自己的游戏安装中提取密钥材料(GTA5.exe、Launcher.exe 或运行中游戏的内存镜像)。
安装前请注意
写入操作会修改归档:put、put --create、rm、mv 和 mkdir 会改动数据,重建会替换原文件。密钥材料从游戏可执行文件提取并缓存在平台配置目录中;不附带任何密钥,NG 归档需要运行中游戏的内存镜像。编辑前请备份归档。

安装

在 SourceWeft 中

  1. 打开 控制台中的 rpfd,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

A dependency-light Rust toolchain for reading, editing and rebuilding RPF7 archives — the dlc.rpf files RAGE Multiplayer and FiveM servers hand to their clients, and the archives Grand Theft Auto V ships. One command-line binary with no runtime prerequisite, and the same code behind a JSON-RPC daemon and a VS Code extension.

The editor extension installs from the store, so updates arrive by themselves: molchalih.rpfd on the VS Code Marketplace and on Open VSX, or code --install-extension molchalih.rpfd.

Asked to install this? An agent follows the procedure in INSTALL.md: the binary on PATH first, then rpf registered with every client the machine has.

Formats

VersionVariantUsed bySupport
RPF7OPEN, unencryptedRAGE MP and FiveM server packsRead, write
RPF7AES-256, 0x0FFFFFF9GTA V, nested archives such as des_* and script_*Read, write — key from the game executable
RPF7AES-256, 0x0FFFFFF7Rockstar Games LauncherRead, write — key from Launcher.exe
RPF7NG, 0x0FEFFFFFGTA V Legacy and Enhanced, every top-level archiveRead, write — both need a memory image
RPF8—Red Dead Redemption 2Not supported
RPF6—Red Dead Redemption, 2010 and 2023Not supported
RPF4—Max Payne 3Not supported
RPF3—GTA IV audio, Midnight Club: LANot supported
RPF2—GTA IV, main archivesNot supported
RPF0—Table TennisNot supported

Pre-RPF7 attributions are read from other implementations, not measured here, and are recorded with their disagreements in the format notes. Every non-RPF7 version is recognised by its magic word and refused by number.

Encryption is per entry as well as per archive: the tag covers the table of contents and the names blob, and each entry's row says whether its payload is under the transform.

Installing

INSTALL.md is the page for this, and it answers three separate questions: how to install the editor extension — from the VS Code Marketplace or Open VSX, with a .vsix as the fallback — how to register the MCP server with an editor or an agent, and where to put the binary if that is all you want. It ends with the procedure an agent follows to do all three on one machine. Prebuilt binaries for macOS, Windows and Linux are attached to each release.

To build from source instead — the toolchain is pinned in rust-toolchain.toml. Clone the repository, then build from the root of the clone, wherever you put it:

git clone https://github.com/molchalih/rpfd.gitcargo build --release          # target/release/rpf

Encrypted archives need key material, extracted from your own installation:

rpf keys extract GTA5.exe         # the AES key and the hash lookup tablerpf keys extract Launcher.exe     # the second AES key, carried by no game executablerpf keys extract <memory image>   # the NG expanded keys and decrypt tables

No key material is bundled here, and none ever will be. Each source is cached under the hash of its own bytes, under keys inside an rpf directory of the platform's own configuration directory — $XDG_CONFIG_HOME or ~/.config on Linux, ~/Library/Application Support on macOS, %APPDATA% on Windows. Every command consults it without a flag, and rpf keys cache is what says where it landed and how much is in it:

$ rpf keys cachecache   /Users/you/Library/Application Support/rpf/keysentries 2

--cache-dir selects another cache, the one way to keep several installations apart, and rpf keys invalidate empties one. No command prints a key — only offsets, lengths, counts and paths. NG material stands in the clear only in a memory image of a running game, so that is the sole route to an NG archive; obtaining one is out of scope here. An archive whose material is absent fails rather than guessing.

Usage

List an archive, descending into the archives inside it:

$ rpf ls -R dlc.rpfbinary    xml          2199  content.xmldirectory -               3  databinary    xml          1445  data/carvariations.metabinary    xml           191  data/dlctext.metabinary    xml          5100  data/vehicles.metabinary    xml           559  setup2.xmldirectory -               2  x64directory -               1  x64/vehiclemodsbinary    -         2544128  x64/vehiclemods/meringls63amg24_mods.rpfresource  -          262144  x64/vehiclemods/meringls63amg24_mods.rpf/meringls63amg24_brabus_diffuser_1.yft... 20 more rows: the rest of the mods archive, and x64/vehicles.rpf

The second column says what an entry holds; pso, rbf and meta have an XML view:

$ rpf cat --as xml des_hosp_ceil2.rpf des_hosp_ceil2.ytyp<?xml version="1.0" encoding="UTF-8"?><hash_D98BB561 pso:struct="hash_D98BB561">  <hash_F17E7F28 pso:array="atarray"/>  <hash_018A3B1B pso:array="atarray">    <pso:item pso:struct="hash_82D6FC83">      <hash_BF74DFA7 pso:float="100.0"/>      <hash_67D26872 pso:uint="0"/>      <hash_6C1523E4 pso:uint="0"/>      <hash_D9EF8236 pso:float3="-2.80584, -2.95097, 0.0"/>      <hash_E78AA618 pso:float3="2.80584, 2.95097, 3.0961"/>      <hash_D61872FF pso:float3="0.0, 0.0, 1.54805"/>      <hash_82E8C5DE pso:float="4.356308"/>      <hash_AD5D5B4C pso:float="5.0"/>      <hash_E6E17F14 pso:string.counted="DES_Hosp_Ceil2"/>      <hash_75D215A1 pso:string.counted="DES_Hosp_Ceil2_txd"/>      <hash_19471791 pso:null="string.counted"/>      <hash_FC1FB6FB pso:null="string.counted"/>      <hash_D3C717FC pso:hashstring="hash_00000000"/>      <hash_F17E7F28 pso:array="atarray"/>    </pso:item>  </hash_018A3B1B>  <hash_E6E17F14 pso:hashstring="hash_334D5CB2"/>  <hash_3C6F8844 pso:array="atarray"/>  <hash_069ADF93 pso:array="atarray"/>  <hash_65E9D4EB pso:array="atarray"/></hash_D98BB561>

rpf put --as xml writes an edited document back in the entry's own encoding. Ask what a write costs, then make it — the byte count is your edited.meta's, not a constant, and --dry-run is how you learn it before anything is written:

$ rpf put dlc.rpf data/vehicles.meta edited.meta --dry-runwould patch 1632 bytes in place at 2048 (room for 2048)
$ rpf put dlc.rpf data/vehicles.meta edited.metapatched 1632 bytes in place at 2048 (room for 2048)

put --create, rm, mv and mkdir move every offset after the header, so they always rebuild and say so first. A rebuild is atomic: a scratch file beside the archive replaces the original in one step.

Take an archive apart, build it back, check the result:

$ rpf extract dlc.rpf tree/7 files and 3 directories into tree/
$ rpf pack tree/ rebuilt.rpf11 entries, 65160704 bytes
$ rpf verify rebuilt.rpf --against tree/27 entries read back; 7 of 7 recorded checksums checked against tree/20 entries carry no recorded checksum: an entry inside a nested archive is covered by the checksum of the entry that holds it

Every reporting command takes --json; rpf --help lists the rest. clients/agent/README.md is the page for driving the tool from a program: the JSON shapes, the failure object, and cat --out for a payload nobody is going to read.

The daemon

rpf serve --stdio speaks JSON-RPC, one object per line. It answers everything the binary does, holds edits until commit, and reports a long rebuild's progress as cancellable notifications.

$ echo '{"jsonrpc":"2.0","id":1,"method":"open","params":{"path":"/tmp/dlc.rpf"}}' | rpf serve --stdio{"id":1,"jsonrpc":"2.0","result":{"entries":11,"handle":1,"len":144504832,"path":"/private/tmp/dlc.rpf"}}

The editor extension

clients/vscode mounts an archive as a workspace folder: files open, edit and save like any other, and a nested archive is a folder inside a folder. The archive is written by one explicit act, previewed as patch or rebuild. See clients/vscode/README.md.

Exit codes

Stable, so a caller can classify a failure without reading the message: 0 is success, and every non-zero code names one class of failure. The daemon reports the same numbers as a JSON-RPC error.code, with a symbolic error.data.reason.

The table is in clients/agent/README.md, which owns it, along with what each code tells a caller to do next.

Building and testing

cargo build --release

Continuous integration runs these, on macOS, Linux and Windows for the first three; passing them locally is what makes a green run likely:

cargo fmt --all -- --checkcargo clippy --all-targets --all-features -- -D warningscargo test --allcargo test -p rpf-core --test oracle -- --nocaptureRUSTDOCFLAGS='-D warnings' cargo doc --no-deps --workspacecargo deny check./tools/docgate/docgate.sh

It also checks every commit message; git config core.hooksPath .githooks runs the same check locally.

The suite needs no game data: what needs it is skipped. RPF_CORPUS, RPF_GAME_EXE, RPF_GAME_IMAGE and RPF_METADATA point it at archives, game executables, a memory image of the running game, and extracted metadata payloads; the matching RPF_REQUIRE_* turns a skip into a failure.

Licence

MIT OR Apache-2.0, at your option. See LICENSE-MIT and LICENSE-APACHE.

来源:README.md,提交 f6e5673

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

3
  1. v0.3.1最新Oct 11, 2026
  2. v0.3.0Oct 10, 2026
  3. v0.2.2Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分