Format:Node.js single executable application
| Developer | Node.js project (OpenJS Foundation) |
|---|---|
| Magic | 20 DA 43 01 (uint32 0x143da20, little-endian, start of the blob) |
| Endianness | little |
| License | MIT |
| Website | https://nodejs.org/api/single-executable-applications.html |
| On this wiki | Facts · Code · Notes · Topics |
A Node.js binary with an application blob injected (with postject) as a resource, note or segment named NODE_SEA_BLOB; the blob starts with the magic 0x143da20 followed by flags and the main script (or a V8 snapshot) and is switched on by flipping the NODE_SEA_FUSE sentinel in the host.
Identification
- The executable is a normal
nodebinary (tens of MB) that contains the stringNODE_SEA_FUSE_fce680ab2cc467b6e072b8b5df1996b2:0. In an unmodified Node.js the fuse ends in:0; postject flips the last character to:1when it injects a blob, so a SEA has...b2:1(Fact:Node.js single executable application/identification/SEA fuse and resource name). - The blob lives in a section called
NODE_SEA_BLOB: a PE resource (RCDATA) on Windows, an ELF note on Linux, a Mach-O sectionNODE_SEA_BLOBin segmentNODE_SEAon macOS. Look at the resource directory, notes or segment list rather than for strings. - A SEA runs the embedded script instead of treating
argv[1]as a script; with the default exec-argv extension settings Node options inNODE_OPTIONSstill work.
Blob layout
The blob is produced by node --experimental-sea-config sea-config.json and is little-endian. Header (10 bytes): uint32 magic = 0x143da20, uint32 flags, uint8 exec_argv_extension (0 none, 1 env, 2 cli), uint8 main_code_format (0 CommonJS, 1 ES module). Then length-prefixed strings: the code path, the main script (or the V8 startup snapshot), optionally the V8 code cache (flag bit 2), then optional assets (flag bit 3: count, then name and content pairs) and exec-argv entries (flag bit 4: count, then strings). The length prefix is a size_t as written by the serializer: Unverified for the exact width, check with a real blob (expected 8 bytes on 64-bit targets) (Fact:Node.js single executable application/struct/SEA blob header).
Flags: bit 0 disable the experimental warning, bit 1 use snapshot, bit 2 use code cache, bit 3 include assets, bit 4 include exec argv, bit 5 enable VFS, bit 6 VFS archive.
Analysis
- The main script is stored as plain source unless
useSnapshotoruseCodeCacheis set; with a code cache the source is still included (V8 needs it), so the JavaScript is recoverable. A snapshot blob holds a serialized V8 heap whose format depends on the exact Node.js/V8 version (identify it fromprocess.versionstrings in the host). - Assets (
sea.getAsset) are stored uncompressed next to the script. - Related bundlers with different layouts: Tool:pkg (Node.js packager), Tool:nexe.
Code & repositories
- https://github.com/nodejs/node @
e2d55227730b77802c142519b7ef04487604cff3· license: MIT (declared by the contributor; GitHub's detector did not recognize LICENSE)
Node.js (MIT): src/node_sea.cc and node_sea.h define and read the SEA blob; doc/api/single-executable-applications.md describes injection.
Tested on: source read, not run: Read node_sea.h/.cc and the SEA doc at this commit; not built or run. · checked 2026-10-18; last activity 2026-10-18
Evidence & references
- nodejs/node commit e2d55227730b77802c142519b7ef04487604cff3:
src/node_sea.hlines 20-60 (kMagic, SeaFlags, SeaExecArgvExtension),src/node_sea.cclines 75-135 (serializer), 160-235 (deserializer),doc/api/single-executable-applications.mdlines 640-780 (NODE_SEA_BLOB, sentinel fuse, postject options).