authorgravatar for 124872+jedisct1@users.noreply.github.comFrank Denis <124872+jedisct1@users.noreply.github.com> 2020-08-17 00:10:49+02:00
committergravatar for kubkon@jakubkonka.comJakub Konka <kubkon@jakubkonka.com> 2020-08-17 07:16:06+02:00
logf46e375bbe0ac0893717bd477eab78f51863e277
treedfb564e96fdfa846bd514311731302fda8a38870
parent8d8d568854d33be7bcc2bc9874029d1082914af7

std/crypto: gimli.Aead.decrypt()'s ad should be const


1 files changed, 1 insertions(+), 1 deletions(-)

lib/std/crypto/gimli.zig+1-1
...@@ -269,7 +269,7 @@ pub const Aead = struct {...@@ -269,7 +269,7 @@ pub const Aead = struct {
269 /// npub: public nonce269 /// npub: public nonce
270 /// k: private key270 /// k: private key
271 /// NOTE: the check of the authentication tag is currently not done in constant time271 /// NOTE: the check of the authentication tag is currently not done in constant time
272 pub fn decrypt(m: []u8, c: []const u8, at: [State.RATE]u8, ad: []u8, npub: [16]u8, k: [32]u8) !void {272 pub fn decrypt(m: []u8, c: []const u8, at: [State.RATE]u8, ad: []const u8, npub: [16]u8, k: [32]u8) !void {
273 assert(c.len == m.len);273 assert(c.len == m.len);
274274
275 var state = Aead.init(ad, npub, k);275 var state = Aead.init(ad, npub, k);