aboutsummaryrefslogtreecommitdiffstats
path: root/java/SHA3.java
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--java/SHA3.java100
1 files changed, 50 insertions, 50 deletions
diff --git a/java/SHA3.java b/java/SHA3.java
index 8ab9a51..fa70915 100644
--- a/java/SHA3.java
+++ b/java/SHA3.java
@@ -477,31 +477,31 @@ public class SHA3
else
for (int i = 0; i < len; i += rr)
{
- SHA3.S[ 0] ^= SHA3.toLane(n, ww, i + 0 );
- SHA3.S[ 5] ^= SHA3.toLane(n, ww, i + w);
- SHA3.S[10] ^= SHA3.toLane(n, ww, i + 2 * w);
- SHA3.S[15] ^= SHA3.toLane(n, ww, i + 3 * w);
- SHA3.S[20] ^= SHA3.toLane(n, ww, i + 4 * w);
- SHA3.S[ 1] ^= SHA3.toLane(n, ww, i + 5 * w);
- SHA3.S[ 6] ^= SHA3.toLane(n, ww, i + 6 * w);
- SHA3.S[11] ^= SHA3.toLane(n, ww, i + 7 * w);
- SHA3.S[16] ^= SHA3.toLane(n, ww, i + 8 * w);
- SHA3.S[21] ^= SHA3.toLane(n, ww, i + 9 * w);
- SHA3.S[ 2] ^= SHA3.toLane(n, ww, i + 10 * w);
- SHA3.S[ 7] ^= SHA3.toLane(n, ww, i + 11 * w);
- SHA3.S[12] ^= SHA3.toLane(n, ww, i + 12 * w);
- SHA3.S[17] ^= SHA3.toLane(n, ww, i + 13 * w);
- SHA3.S[22] ^= SHA3.toLane(n, ww, i + 14 * w);
- SHA3.S[ 3] ^= SHA3.toLane(n, ww, i + 15 * w);
- SHA3.S[ 8] ^= SHA3.toLane(n, ww, i + 16 * w);
- SHA3.S[13] ^= SHA3.toLane(n, ww, i + 17 * w);
- SHA3.S[18] ^= SHA3.toLane(n, ww, i + 18 * w);
- SHA3.S[23] ^= SHA3.toLane(n, ww, i + 19 * w);
- SHA3.S[ 4] ^= SHA3.toLane(n, ww, i + 20 * w);
- SHA3.S[ 9] ^= SHA3.toLane(n, ww, i + 21 * w);
- SHA3.S[14] ^= SHA3.toLane(n, ww, i + 22 * w);
- SHA3.S[19] ^= SHA3.toLane(n, ww, i + 23 * w);
- SHA3.S[24] ^= SHA3.toLane(n, ww, i + 24 * w);
+ SHA3.S[ 0] ^= SHA3.toLane(n, ww, i + 0 );
+ SHA3.S[ 5] ^= SHA3.toLane(n, ww, i + ww);
+ SHA3.S[10] ^= SHA3.toLane(n, ww, i + 2 * ww);
+ SHA3.S[15] ^= SHA3.toLane(n, ww, i + 3 * ww);
+ SHA3.S[20] ^= SHA3.toLane(n, ww, i + 4 * ww);
+ SHA3.S[ 1] ^= SHA3.toLane(n, ww, i + 5 * ww);
+ SHA3.S[ 6] ^= SHA3.toLane(n, ww, i + 6 * ww);
+ SHA3.S[11] ^= SHA3.toLane(n, ww, i + 7 * ww);
+ SHA3.S[16] ^= SHA3.toLane(n, ww, i + 8 * ww);
+ SHA3.S[21] ^= SHA3.toLane(n, ww, i + 9 * ww);
+ SHA3.S[ 2] ^= SHA3.toLane(n, ww, i + 10 * ww);
+ SHA3.S[ 7] ^= SHA3.toLane(n, ww, i + 11 * ww);
+ SHA3.S[12] ^= SHA3.toLane(n, ww, i + 12 * ww);
+ SHA3.S[17] ^= SHA3.toLane(n, ww, i + 13 * ww);
+ SHA3.S[22] ^= SHA3.toLane(n, ww, i + 14 * ww);
+ SHA3.S[ 3] ^= SHA3.toLane(n, ww, i + 15 * ww);
+ SHA3.S[ 8] ^= SHA3.toLane(n, ww, i + 16 * ww);
+ SHA3.S[13] ^= SHA3.toLane(n, ww, i + 17 * ww);
+ SHA3.S[18] ^= SHA3.toLane(n, ww, i + 18 * ww);
+ SHA3.S[23] ^= SHA3.toLane(n, ww, i + 19 * ww);
+ SHA3.S[ 4] ^= SHA3.toLane(n, ww, i + 20 * ww);
+ SHA3.S[ 9] ^= SHA3.toLane(n, ww, i + 21 * ww);
+ SHA3.S[14] ^= SHA3.toLane(n, ww, i + 22 * ww);
+ SHA3.S[19] ^= SHA3.toLane(n, ww, i + 23 * ww);
+ SHA3.S[24] ^= SHA3.toLane(n, ww, i + 24 * ww);
SHA3.keccakF(SHA3.S);
n += rr;
}
@@ -801,31 +801,31 @@ public class SHA3
else
for (int i = 0; i < len; i += rr)
{
- SHA3.S[ 0] ^= SHA3.toLane(n, ww, i + 0 );
- SHA3.S[ 5] ^= SHA3.toLane(n, ww, i + w);
- SHA3.S[10] ^= SHA3.toLane(n, ww, i + 2 * w);
- SHA3.S[15] ^= SHA3.toLane(n, ww, i + 3 * w);
- SHA3.S[20] ^= SHA3.toLane(n, ww, i + 4 * w);
- SHA3.S[ 1] ^= SHA3.toLane(n, ww, i + 5 * w);
- SHA3.S[ 6] ^= SHA3.toLane(n, ww, i + 6 * w);
- SHA3.S[11] ^= SHA3.toLane(n, ww, i + 7 * w);
- SHA3.S[16] ^= SHA3.toLane(n, ww, i + 8 * w);
- SHA3.S[21] ^= SHA3.toLane(n, ww, i + 9 * w);
- SHA3.S[ 2] ^= SHA3.toLane(n, ww, i + 10 * w);
- SHA3.S[ 7] ^= SHA3.toLane(n, ww, i + 11 * w);
- SHA3.S[12] ^= SHA3.toLane(n, ww, i + 12 * w);
- SHA3.S[17] ^= SHA3.toLane(n, ww, i + 13 * w);
- SHA3.S[22] ^= SHA3.toLane(n, ww, i + 14 * w);
- SHA3.S[ 3] ^= SHA3.toLane(n, ww, i + 15 * w);
- SHA3.S[ 8] ^= SHA3.toLane(n, ww, i + 16 * w);
- SHA3.S[13] ^= SHA3.toLane(n, ww, i + 17 * w);
- SHA3.S[18] ^= SHA3.toLane(n, ww, i + 18 * w);
- SHA3.S[23] ^= SHA3.toLane(n, ww, i + 19 * w);
- SHA3.S[ 4] ^= SHA3.toLane(n, ww, i + 20 * w);
- SHA3.S[ 9] ^= SHA3.toLane(n, ww, i + 21 * w);
- SHA3.S[14] ^= SHA3.toLane(n, ww, i + 22 * w);
- SHA3.S[19] ^= SHA3.toLane(n, ww, i + 23 * w);
- SHA3.S[24] ^= SHA3.toLane(n, ww, i + 24 * w);
+ SHA3.S[ 0] ^= SHA3.toLane(n, ww, i + 0 );
+ SHA3.S[ 5] ^= SHA3.toLane(n, ww, i + ww);
+ SHA3.S[10] ^= SHA3.toLane(n, ww, i + 2 * ww);
+ SHA3.S[15] ^= SHA3.toLane(n, ww, i + 3 * ww);
+ SHA3.S[20] ^= SHA3.toLane(n, ww, i + 4 * ww);
+ SHA3.S[ 1] ^= SHA3.toLane(n, ww, i + 5 * ww);
+ SHA3.S[ 6] ^= SHA3.toLane(n, ww, i + 6 * ww);
+ SHA3.S[11] ^= SHA3.toLane(n, ww, i + 7 * ww);
+ SHA3.S[16] ^= SHA3.toLane(n, ww, i + 8 * ww);
+ SHA3.S[21] ^= SHA3.toLane(n, ww, i + 9 * ww);
+ SHA3.S[ 2] ^= SHA3.toLane(n, ww, i + 10 * ww);
+ SHA3.S[ 7] ^= SHA3.toLane(n, ww, i + 11 * ww);
+ SHA3.S[12] ^= SHA3.toLane(n, ww, i + 12 * ww);
+ SHA3.S[17] ^= SHA3.toLane(n, ww, i + 13 * ww);
+ SHA3.S[22] ^= SHA3.toLane(n, ww, i + 14 * ww);
+ SHA3.S[ 3] ^= SHA3.toLane(n, ww, i + 15 * ww);
+ SHA3.S[ 8] ^= SHA3.toLane(n, ww, i + 16 * ww);
+ SHA3.S[13] ^= SHA3.toLane(n, ww, i + 17 * ww);
+ SHA3.S[18] ^= SHA3.toLane(n, ww, i + 18 * ww);
+ SHA3.S[23] ^= SHA3.toLane(n, ww, i + 19 * ww);
+ SHA3.S[ 4] ^= SHA3.toLane(n, ww, i + 20 * ww);
+ SHA3.S[ 9] ^= SHA3.toLane(n, ww, i + 21 * ww);
+ SHA3.S[14] ^= SHA3.toLane(n, ww, i + 22 * ww);
+ SHA3.S[19] ^= SHA3.toLane(n, ww, i + 23 * ww);
+ SHA3.S[24] ^= SHA3.toLane(n, ww, i + 24 * ww);
SHA3.keccakF(SHA3.S);
n += rr;
}