Skip to content

enjin/wallet-daemon

Repository files navigation

Enjin Wallet Daemon

A lightweight outbound-only signer for Enjin Platform Cloud transactions.

License: LGPL 3.0

The daemon polls Enjin Platform Cloud for pending transactions, signs them with the configured wallet, and returns signed payloads to the platform for broadcast. It does not accept inbound transaction requests, so the host running the daemon should not expose public ports for daemon traffic.

For the full user guide, including binary downloads, Docker, AWS CloudFormation, import, export, and migration workflows, see Using the Wallet Daemon.

Security Notes

The daemon is security-sensitive.

  • It stores an encrypted wallet.seed file on disk.
  • KEY_PASS encrypts and decrypts wallet.seed.
  • PLATFORM_KEY authenticates the daemon with Enjin Platform Cloud.

Back up wallet.seed and KEY_PASS separately. Losing either value can make the wallet unrecoverable. Do not rotate KEY_PASS for an existing wallet.seed; changing KEY_PASS is not currently supported.

Run exactly one daemon per Platform account. Multiple wallets can be derived and used for signing from the master key.

Configuration

The daemon reads configuration from environment variables or a local .env file.

Variable Required Description
KEY_PASS Yes Password used to encrypt and decrypt wallet.seed. Use a unique, high-entropy value.
PLATFORM_KEY Yes Enjin Platform Cloud API token used by the daemon.
SEED_PATH No Optional path to a seed file or seed directory.

Minimal .env:

KEY_PASS=your-unique-key-password
PLATFORM_KEY=your-platform-api-token

Windows / PowerShell

The .env file must be UTF-8. Windows PowerShell 5.1 writes UTF-16 by default (>, Out-File, Set-Content without -Encoding), which can corrupt .env. The daemon auto-detects and reads UTF-16 .env files, but to be safe either save explicitly as UTF-8:

Set-Content -Path .env -Encoding utf8 -Value "KEY_PASS=...`nPLATFORM_KEY=..."

or set the variables in the session instead of using a file:

$env:KEY_PASS="your-unique-key-password"
$env:PLATFORM_KEY="your-platform-api-token"

Also make sure the file is named exactly .env, not .env.txt (Notepad can add a hidden .txt extension).

Running Locally

Build and run from source:

cargo build --release
./target/release/wallet-daemon

Import an existing 12-word mnemonic:

./target/release/wallet-daemon import

Print the decrypted seed for migration:

./target/release/wallet-daemon print-seed

Only print the seed from a trusted shell.

Docker

The published image is available on Docker Hub.

Tests

cargo test

License

The LGPL 3.0 License. See LICENSE.

About

Enjin Wallet Daemon is responsible for automatically signing transactions that were created using Enjin Platform Cloud.

Topics

Resources

License

Security policy

Stars

19 stars

Watchers

4 watching

Forks

Contributors