Home / Function/ decodeKey() — astro Function Reference

decodeKey() — astro Function Reference

Architecture documentation for the decodeKey() function in encryption.ts from the astro codebase.

Entity Profile

Dependency Diagram

graph TD
  4b6575c8_cd95_5f6e_51d9_80ca1c627f56["decodeKey()"]
  94fbb11e_4aa9_9dfd_28d5_cc0eb8749e6c["encryption.ts"]
  4b6575c8_cd95_5f6e_51d9_80ca1c627f56 -->|defined in| 94fbb11e_4aa9_9dfd_28d5_cc0eb8749e6c
  2e78015b_b90e_b5de_eed6_2a54c3b36e62["getEnvironmentKey()"]
  2e78015b_b90e_b5de_eed6_2a54c3b36e62 -->|calls| 4b6575c8_cd95_5f6e_51d9_80ca1c627f56
  style 4b6575c8_cd95_5f6e_51d9_80ca1c627f56 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

packages/astro/src/core/encryption.ts lines 68–74

export async function decodeKey(encoded: string): Promise<CryptoKey> {
	const bytes = decodeBase64(encoded);
	return crypto.subtle.importKey('raw', bytes.buffer as ArrayBuffer, ALGORITHM, true, [
		'encrypt',
		'decrypt',
	]);
}

Domain

Subdomains

Frequently Asked Questions

What does decodeKey() do?
decodeKey() is a function in the astro codebase, defined in packages/astro/src/core/encryption.ts.
Where is decodeKey() defined?
decodeKey() is defined in packages/astro/src/core/encryption.ts at line 68.
What calls decodeKey()?
decodeKey() is called by 1 function(s): getEnvironmentKey.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free