Decrypted { envVar: key } map for building this user's engine.
(userId: string)
| 38 | |
| 39 | /** Decrypted { envVar: key } map for building this user's engine. */ |
| 40 | envMap(userId: string): Record<string, string> { |
| 41 | const out: Record<string, string> = {}; |
| 42 | for (const row of this.store.userKeys.list(userId)) { |
| 43 | try { |
| 44 | out[row.env] = this.cipher.decrypt(row.ciphertext); |
| 45 | } catch { |
| 46 | /* skip undecryptable rows */ |
| 47 | } |
| 48 | } |
| 49 | return out; |
| 50 | } |
| 51 | } |
no test coverage detected