Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Marcus Hoffmann
nettle
Commits
859abcc7
Commit
859abcc7
authored
Jun 08, 2011
by
Niels Möller
Browse files
(SBOX4): Renamed arguments.
Rev: nettle/serpent-encrypt.c:1.6
parent
f504af23
Changes
1
Hide whitespace changes
Inline
Side-by-side
serpent-encrypt.c
View file @
859abcc7
...
...
@@ -164,29 +164,29 @@
} while (0)
/* S4: 1 15 8 3 12 0 11 6 2 5 4 10 9 14 7 13 */
#define SBOX4(type,
a, b, c, d, w, x
, y,
z
) \
#define SBOX4(type,
x0, x1, x2, x3, y0, y1
, y
2
,
y3
) \
do { \
type t02, t03, t04, t05, t06, t08, t09; \
type t10, t11, t12, t13, t14, t15, t16, t01; \
t01 =
a
|
b
; \
t02 =
b
|
c
; \
t03 =
a
^ t02; \
t04 =
b
^
d
; \
t05 =
d
| t03; \
t06 =
d
& t01; \
z
= t03 ^ t06; \
t08 =
z
& t04; \
t01 =
x0
|
x1
; \
t02 =
x1
|
x2
; \
t03 =
x0
^ t02; \
t04 =
x1
^
x3
; \
t05 =
x3
| t03; \
t06 =
x3
& t01; \
y3
= t03 ^ t06; \
t08 =
y3
& t04; \
t09 = t04 & t05; \
t10 =
c
^ t06; \
t11 =
b
&
c
; \
t10 =
x2
^ t06; \
t11 =
x1
&
x2
; \
t12 = t04 ^ t08; \
t13 = t11 | t03; \
t14 = t10 ^ t09; \
t15 =
a
& t05; \
t15 =
x0
& t05; \
t16 = t11 | t12; \
y = t13 ^ t08; \
x
= t15 ^ t16; \
w
= ~ t14; \
y
2
= t13 ^ t08; \
y1
= t15 ^ t16; \
y0
= ~ t14; \
} while (0)
/* S5: 15 5 2 11 4 10 9 12 0 3 14 8 13 6 7 1 */
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment