secure_key_manager 1.1.0
secure_key_manager: ^1.1.0 copied to clipboard
Fetch secret keys by name from Firebase Cloud Functions backed by Google Secret Manager. No secrets ever ship in your app binary, repo, or .env.
Changelog #
All notable changes to this project are documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
1.1.0 #
Added #
SecureKeyManager.initializenow accepts an optionalfirebaseOptionsargument. When provided, the manager callsFirebase.initializeAppfor you — no FlutterFire CLI,firebase_options.dart,google-services.json, orGoogleService-Info.plistrequired. Pass the config from the Firebase Console inline instead.- Re-exported
FirebaseOptionsfromfirebase_core, so apps only need to importpackage:secure_key_manager/secure_key_manager.dart.
1.0.0 #
Initial release.
Added #
SecureKeyManager.initialize({region, cacheTtl})— one-time setup with anonymous Firebase Auth sign-in and configurable Cloud Functions region.SecureKeyManager.get(keyName)— cache-first fetch of a secret value from thegetSecretKeyCloud Function.SecureKeyManager.clearCache()— drop all cached keys (e.g. on logout).SecureKeyManager.evict(keyName)— drop a single key to force a re-fetch.- In-memory TTL cache (default 30 minutes); no values are persisted to disk.
getSecretKeyCloud Function with auth enforcement and a server-sideALLOWED_KEYSwhitelist.- Runnable example app and full Firebase setup guide.