diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2024-01-28 20:29:08 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2024-01-28 20:29:08 +0700 |
commit | 4e0fd4ba3ebf435c537fc8bf486019c7342d6ac5 (patch) | |
tree | 1e73e4b49342f16aa71de23d23d60b0a4966200f | |
parent | Add noParams entries for Ed25519, Ed448 (diff) | |
download | BouncyCastle.NET-ed25519-4e0fd4ba3ebf435c537fc8bf486019c7342d6ac5.tar.xz |
Refactoring
-rw-r--r-- | crypto/src/crypto/engines/Salsa20Engine.cs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/crypto/src/crypto/engines/Salsa20Engine.cs b/crypto/src/crypto/engines/Salsa20Engine.cs index 3d33a2186..e700fc197 100644 --- a/crypto/src/crypto/engines/Salsa20Engine.cs +++ b/crypto/src/crypto/engines/Salsa20Engine.cs @@ -269,10 +269,10 @@ namespace Org.BouncyCastle.Crypto.Engines Vector128<uint> b0, b1, b2, b3; { var I = MemoryMarshal.AsBytes(input[..16]); - var t0 = MemoryMarshal.Read<Vector128<short>>(I[0x00..0x10]); - var t1 = MemoryMarshal.Read<Vector128<short>>(I[0x10..0x20]); - var t2 = MemoryMarshal.Read<Vector128<short>>(I[0x20..0x30]); - var t3 = MemoryMarshal.Read<Vector128<short>>(I[0x30..0x40]); + var t0 = MemoryMarshal.Read<Vector128<ushort>>(I[0x00..0x10]); + var t1 = MemoryMarshal.Read<Vector128<ushort>>(I[0x10..0x20]); + var t2 = MemoryMarshal.Read<Vector128<ushort>>(I[0x20..0x30]); + var t3 = MemoryMarshal.Read<Vector128<ushort>>(I[0x30..0x40]); var u0 = Sse41.Blend(t0, t2, 0xF0); var u1 = Sse41.Blend(t1, t3, 0xC3); |