binary_enclave 0.1.0

embed modifiable configuration or other data within a binary directly

Binary Enclave

Binary Enclave allows storing configuration data in a binary directly. You will probably never find a good reason for doing this. This is primarily an exercise for learning rust and something I found interesting. The idea originates from the Wraith Botpack [].


  • Written payload is only visible upon next execution.

Basic Usage

use binary_enclave::{enclave, Enclave}

pub static CONFIG: Enclave<Config, 512> = Enclave::new();

fn main() {
    let conf = CONFIG.decode()?;
    let res = CONFIG.write(&Config{ some: 43, values: "see" })?;

Outstanding Items

  • PE (Windows) support
  • Payload Checksum
  • Payload Encryption
  • Github Actions