Contents

decryptAttributes()

Validates decryption keys, collects archive attributes, and updates the context with decrypted archive attributes.

Declaration

func decryptAttributes() -> Bool

Return Value

true on success; otherwise, false if the credentials and archive prologue don’t match.

Discussion

You must have created the current context from an encrypted stream.

Apple Archive performs the same validation and updates when it opens a decryption input stream. Therefore, you don’t need to call this function before calling either decryptionStream(readingFrom:encryptionContext:flags:threadCount:) or randomAccessDecryptionStream(readingFrom:encryptionContext:allocationLimit:flags:threadCount:).

See Also

Getting and setting encryption context properties