MCPcopy Create free account
hub / github.com/Kilo-Org/cloud / encryptPromoCode

Function encryptPromoCode

apps/web/src/lib/promoCreditEncryption.ts:19–21  ·  view source on GitHub ↗
(plaintext: string)

Source from the content-addressed store, hash-verified

17 * @returns Encrypted string in format iv:authTag:encrypted
18 */
19export function encryptPromoCode(plaintext: string): string {
20 return encryptWithSymmetricKey(plaintext, getEncryptionKey());
21}
22
23/**
24 * Decrypts an encrypted promo code.

Callers

nothing calls this directly

Calls 2

encryptWithSymmetricKeyFunction · 0.90
getEncryptionKeyFunction · 0.85

Tested by

no test coverage detected