Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,15 @@ import {
} from '@aws-crypto/serialize'
import { compare } from './portable_compare'

// 512 bits of 0 for padding between hashes in decryption materials cache ID generation.
const BIT_PAD_512 = Buffer.alloc(64)

export function buildCryptographicMaterialsCacheKeyHelpers<
S extends SupportedAlgorithmSuites
>(
fromUtf8: (input: string) => Uint8Array,
toUtf8: (input: Uint8Array) => string,
sha512: (...data: (Uint8Array | string)[]) => Promise<Uint8Array>
): CryptographicMaterialsCacheKeyHelpersInterface<S> {
// 512 bits of 0 for padding between hashes in decryption materials cache ID generation.
const BIT_PAD_512 = Buffer.alloc(64)
const sorting: SerializeOptions = { utf8Sorting: true }
const { serializeEncryptionContext, serializeEncryptedDataKey } =
serializeFactory(fromUtf8, sorting)
Expand Down
1 change: 1 addition & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.