MCPcopy Create free account
hub / github.com/blockmatic/basilic / getEncryptionKey

Function getEncryptionKey

apps/api/src/lib/crypto.ts:18–20  ·  view source on GitHub ↗

* Gets the encryption key as a Buffer from ENCRYPTION_KEY env var * ENCRYPTION_KEY is a 64-character hex string (32 bytes)

()

Source from the content-addressed store, hash-verified

16 * ENCRYPTION_KEY is a 64-character hex string (32 bytes)
17 */
18function getEncryptionKey(): Buffer {
19 return Buffer.from(env.ENCRYPTION_KEY, 'hex')
20}
21
22const weakEncryptionKey = '0'.repeat(64)
23

Callers 2

encryptFunction · 0.85
decryptFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected