'\" t .\" Title: crypto_aead_decrypt .\" Author: .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: Programming Interface .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "CRYPTO_AEAD_DECRYPT" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "Programming Interface" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" crypto_aead_decrypt \- decrypt ciphertext .SH "SYNOPSIS" .HP \w'int\ crypto_aead_decrypt('u .BI "int crypto_aead_decrypt(struct\ aead_request\ *\ " "req" ");" .SH "ARGUMENTS" .PP \fIreq\fR .RS 4 reference to the ablkcipher_request handle that holds all information needed to perform the cipher operation .RE .SH "DESCRIPTION" .PP Decrypt ciphertext data using the aead_request handle\&. That data structure and how it is filled with data is discussed with the aead_request_* functions\&. .PP IMPORTANT NOTE The caller must concatenate the ciphertext followed by the authentication data / tag\&. That authentication data / tag must have the size defined by the crypto_aead_setauthsize invocation\&. .SH "RETURN" .PP 0 if the cipher operation was successful; \-EBADMSG: The AEAD cipher operation performs the authentication of the data during the decryption operation\&. Therefore, the function returns this error if the authentication of the ciphertext was unsuccessful (i\&.e\&. the integrity of the ciphertext or the associated data was violated); < 0 if an error occurred\&. .SH "AUTHORS" .PP \fBStephan Mueller\fR <\&smueller@chronox.de\&> .RS 4 Author. .RE .PP \fBMarek Vasut\fR <\&marek@denx.de\&> .RS 4 Author. .RE .SH "COPYRIGHT" .br