backUpToClientShareService: false during wallet creation, you are responsible for securely storing the externalServerKeyShares returned by createWalletAccount. These key shares, combined with your Dynamic developer API key, provide signing authority and must be protected with defense-in-depth strategies.
Recommended Storage Approaches
1. Envelope Encryption with Cloud KMS (Recommended)
1. Envelope Encryption with Cloud KMS (Recommended)
Use a cloud Key Management Service to encrypt the key shares before storing them in your database.AWS KMS Example:Benefits:
- Centralized key management with automatic rotation
- Hardware-backed security (FIPS 140-2 Level 3)
- Audit logging of all encryption/decryption operations
- Fine-grained IAM policies
2. Google Cloud KMS & Secret Manager
2. Google Cloud KMS & Secret Manager
Similar to AWS KMS, but integrated with Google Cloud’s ecosystem.
3. Azure Key Vault
3. Azure Key Vault
Microsoft Azure’s managed secrets and key management service.
Security Requirements Checklist
Regardless of your storage method, follow these requirements:- Never log plaintext key shares — redact
externalServerKeySharesfrom all logs, error messages, and monitoring - Encrypt at rest — use AES-256-GCM or equivalent; ensure database/storage has encryption enabled
- Encrypt in transit — all communication must use TLS 1.3
- Implement access controls — restrict which services and roles can decrypt key shares
- Enable audit logging — track all access to encrypted materials with timestamps and actor identity
- Separate encryption keys — don’t reuse keys across environments (dev/staging/prod)
- Use unique encryption per record — generate new IVs for each encryption operation
- Implement key rotation — rotate encryption keys periodically (e.g., every 90 days)
- Plan for key compromise — document incident response for key material exposure
- Secure deletion — overwrite secrets in memory after use; use secure deletion for storage