K 10 svn:author V 3 jhb K 8 svn:date V 27 2018-02-22T00:53:05.276711Z K 7 svn:log V 515 MFC 323889: Place the AAD before the plaintext/ciphertext for CIOCRYPTAEAD. Software crypto implementations don't care how the buffer is laid out, but hardware implementations may assume that the AAD is always before the plain/cipher text and that the hash/tag is immediately after the end of the plain/cipher text. In particular, this arrangement matches the layout of both IPSec packets and TLS frames. Linux's crypto framework also assumes this layout for AEAD requests. Sponsored by: Chelsio Communications END