Skip to content

Implement oracle keypair management (env/secrets) #43

@Otaiki1

Description

@Otaiki1

Context

The oracle signs reveal transactions with a dedicated keypair. This key must be stored securely (env or secrets manager) and loaded at runtime without logging.

Goal

  • Implement KeyService that provides the oracle keypair: load from env (e.g. ORACLE_SECRET_KEY) or from a secrets manager (e.g. AWS Secrets Manager, HSM) for production.
  • Expose getKeypair() or getPublicKey()/sign() for use by VrfService and TxSubmitterService.
  • Never log or expose the secret; validate at startup that key is present and valid.

Contributor guide

  1. Directory: oracle/
  2. Add src/keys/key.service.ts. Parse secret key from env; construct Keypair (Stellar SDK). For production, add an adapter for secrets manager and use that when configured.
  3. Inject KeyService into VrfService and TxSubmitterService.
  4. Document env var and optional production setup in README.

References

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions