Summery Summery

Seal a file (rather than a string). Uses less memory than ParagonIE_Sodium_Compat::crypto_secretbox_open(), but produces the same result.

Syntax Syntax

ParagonIE_Sodium_File::secretbox_open( string $inputFile, string $outputFile, string $nonce, string $key )

Description Description

Warning: Does not protect against TOCTOU attacks. You should just load the file into memory and use crypto_secretbox_open() if you are worried about those.

Parameters Parameters


(string) (Required)


(string) (Required)


(string) (Required)


(string) (Required)

Return Return


Source Source

File: wp-includes/sodium_compat/src/File.php




Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.