| Modifier and Type | Field and Description |
|---|---|
| protected static final int | |
| protected boolean | |
| protected int | |
| pack-priv static final int | |
| pack-priv static final int | |
| protected int[] |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| protected abstract void | |
| protected abstract void | |
| public String | getAlgorithmName()
Implements org. Return the name of the algorithm the cipher implements. |
| public int | getBlockSize()
Implements org. Return the block size for this cipher (in bytes). |
| private CryptoServicePurpose | |
| protected final void | ib0(int[] X, int a, int b, int c, int d)
InvSO - {13, 3,11, 0,10, 6, 5,12, 1,14, 4, 7,15, 9, 8, 2 } - 15 terms. |
| protected final void | ib1(int[] X, int a, int b, int c, int d)
InvS1 - { 5, 8, 2,14,15, 6,12, 3,11, 4, 7, 9, 1,13,10, 0 } - 14 steps. |
| protected final void | ib2(int[] X, int a, int b, int c, int d)
InvS2 - {12, 9,15, 4,11,14, 1, 2, 0, 3, 6,13, 5, 8,10, 7 } - 16 steps. |
| protected final void | ib3(int[] X, int a, int b, int c, int d)
InvS3 - { 0, 9,10, 7,11,14, 6,13, 3, 5,12, 2, 4, 8,15, 1 } - 15 terms |
| protected final void | ib4(int[] X, int a, int b, int c, int d)
InvS4 - { 5, 0, 8, 3,10, 9, 7,14, 2,12,11, 6, 4,15,13, 1 } - 15 terms. |
| protected final void | ib5(int[] X, int a, int b, int c, int d)
InvS5 - { 8,15, 2, 9, 4, 1,13,14,11, 6, 5, 3, 7,12,10, 0 } - 16 terms. |
| protected final void | ib6(int[] X, int a, int b, int c, int d)
InvS6 - {15,10, 1,13, 5, 3, 6, 0, 4, 9,14, 7, 2,12, 8,11 } - 15 terms. |
| protected final void | ib7(int[] X, int a, int b, int c, int d)
InvS7 - { 3, 0, 6,13, 9,14,15, 8, 5,12,11, 7,10, 1, 4, 2 } - 17 terms. |
| public void | init(boolean
whether or not we are for encryption. encrypting, CipherParameters the parameters required to set up the cipher. params)Implements org. initialise a Serpent cipher. |
| protected final void | |
| protected final void | |
| protected abstract int[] | |
| public final int | Returns: the number of bytes processed and produced.the array containing the input data. in, int offset into the in array the data starts at. inOff, byte[] the array the output data will be copied into. out, int the offset into the out array the output will start at. outOff)Implements org. Process one block of input from the array in and write it to the out array. |
| public void | |
| protected static int | |
| protected static int | |
| protected final void | sb0(int[] X, int a, int b, int c, int d)
S0 - { 3, 8,15, 1,10, 6, 5,11,14,13, 4, 2, 7, 0, 9,12 } - 15 terms. |
| protected final void | sb1(int[] X, int a, int b, int c, int d)
S1 - {15,12, 2, 7, 9, 0, 5,10, 1,11,14, 8, 6,13, 3, 4 } - 14 terms. |
| protected final void | sb2(int[] X, int a, int b, int c, int d)
S2 - { 8, 6, 7, 9, 3,12,10,15,13, 1,14, 4, 0,11, 5, 2 } - 16 terms. |
| protected final void | sb3(int[] X, int a, int b, int c, int d)
S3 - { 0,15,11, 8,12, 9, 6, 3,13, 1, 2, 4,10, 7, 5,14 } - 16 terms. |
| protected final void | sb4(int[] X, int a, int b, int c, int d)
S4 - { 1,15, 8, 3,12, 0,11, 6, 2, 5, 4,10, 9,14, 7,13 } - 15 terms. |
| protected final void | sb5(int[] X, int a, int b, int c, int d)
S5 - {15, 5, 2,11, 4,10, 9,12, 0, 3,14, 8,13, 6, 7, 1 } - 16 terms. |
| protected final void | sb6(int[] X, int a, int b, int c, int d)
S6 - { 7, 2,12, 5, 8, 4, 6,11,14, 9, 1,15,13, 3,10, 0 } - 15 terms. |
| protected final void | sb7(int[] X, int a, int b, int c, int d)
S7 - { 1,13,15, 0,14, 8, 2,11, 7, 4,12,10, 9, 3, 5, 6 } - 16 terms. |
| BLOCK_SIZE | back to summary |
|---|---|
| protected static final int BLOCK_SIZE | |
| encrypting | back to summary |
|---|---|
| protected boolean encrypting | |
| keyBits | back to summary |
|---|---|
| protected int keyBits | |
| PHI | back to summary |
|---|---|
| pack-priv static final int PHI | |
| ROUNDS | back to summary |
|---|---|
| pack-priv static final int ROUNDS | |
| wKey | back to summary |
|---|---|
| protected int[] wKey | |
| SerpentEngineBase | back to summary |
|---|---|
| pack-priv SerpentEngineBase() | |
| decryptBlock | back to summary |
|---|---|
| protected abstract void decryptBlock(byte[] input, int inOff, byte[] output, int outOff) | |
| encryptBlock | back to summary |
|---|---|
| protected abstract void encryptBlock(byte[] input, int inOff, byte[] output, int outOff) | |
| getAlgorithmName | back to summary |
|---|---|
| public String getAlgorithmName() Implements org. Doc from org. Return the name of the algorithm the cipher implements.
| |
| getBlockSize | back to summary |
|---|---|
| public int getBlockSize() Implements org. Doc from org. Return the block size for this cipher (in bytes).
| |
| getPurpose | back to summary |
|---|---|
| private CryptoServicePurpose getPurpose() | |
| ib0 | back to summary |
|---|---|
| protected final void ib0(int[] X, int a, int b, int c, int d) InvSO - {13, 3,11, 0,10, 6, 5,12, 1,14, 4, 7,15, 9, 8, 2 } - 15 terms. | |
| ib1 | back to summary |
|---|---|
| protected final void ib1(int[] X, int a, int b, int c, int d) InvS1 - { 5, 8, 2,14,15, 6,12, 3,11, 4, 7, 9, 1,13,10, 0 } - 14 steps. | |
| ib2 | back to summary |
|---|---|
| protected final void ib2(int[] X, int a, int b, int c, int d) InvS2 - {12, 9,15, 4,11,14, 1, 2, 0, 3, 6,13, 5, 8,10, 7 } - 16 steps. | |
| ib3 | back to summary |
|---|---|
| protected final void ib3(int[] X, int a, int b, int c, int d) InvS3 - { 0, 9,10, 7,11,14, 6,13, 3, 5,12, 2, 4, 8,15, 1 } - 15 terms | |
| ib4 | back to summary |
|---|---|
| protected final void ib4(int[] X, int a, int b, int c, int d) InvS4 - { 5, 0, 8, 3,10, 9, 7,14, 2,12,11, 6, 4,15,13, 1 } - 15 terms. | |
| ib5 | back to summary |
|---|---|
| protected final void ib5(int[] X, int a, int b, int c, int d) InvS5 - { 8,15, 2, 9, 4, 1,13,14,11, 6, 5, 3, 7,12,10, 0 } - 16 terms. | |
| ib6 | back to summary |
|---|---|
| protected final void ib6(int[] X, int a, int b, int c, int d) InvS6 - {15,10, 1,13, 5, 3, 6, 0, 4, 9,14, 7, 2,12, 8,11 } - 15 terms. | |
| ib7 | back to summary |
|---|---|
| protected final void ib7(int[] X, int a, int b, int c, int d) InvS7 - { 3, 0, 6,13, 9,14,15, 8, 5,12,11, 7,10, 1, 4, 2 } - 17 terms. | |
| init | back to summary |
|---|---|
| public void init(boolean encrypting, CipherParameters params) Implements org. initialise a Serpent cipher.
| |
| inverseLT | back to summary |
|---|---|
| protected final void inverseLT(int[] X) Apply the inverse of the linear transformation to the register set. | |
| LT | back to summary |
|---|---|
| protected final void LT(int[] X) Apply the linear transformation to the register set. | |
| makeWorkingKey | back to summary |
|---|---|
| protected abstract int[] makeWorkingKey(byte[] key) | |
| processBlock | back to summary |
|---|---|
| public final int processBlock(byte[] in, int inOff, byte[] out, int outOff) Implements org. Process one block of input from the array in and write it to the out array.
| |
| reset | back to summary |
|---|---|
| public void reset() Implements org. Doc from org. Reset the cipher. After resetting the cipher is in the same state as it was after the last init (if there was one). | |
| rotateLeft | back to summary |
|---|---|
| protected static int rotateLeft(int x, int bits) | |
| rotateRight | back to summary |
|---|---|
| protected static int rotateRight(int x, int bits) | |
| sb0 | back to summary |
|---|---|
| protected final void sb0(int[] X, int a, int b, int c, int d) S0 - { 3, 8,15, 1,10, 6, 5,11,14,13, 4, 2, 7, 0, 9,12 } - 15 terms. | |
| sb1 | back to summary |
|---|---|
| protected final void sb1(int[] X, int a, int b, int c, int d) S1 - {15,12, 2, 7, 9, 0, 5,10, 1,11,14, 8, 6,13, 3, 4 } - 14 terms. | |
| sb2 | back to summary |
|---|---|
| protected final void sb2(int[] X, int a, int b, int c, int d) S2 - { 8, 6, 7, 9, 3,12,10,15,13, 1,14, 4, 0,11, 5, 2 } - 16 terms. | |
| sb3 | back to summary |
|---|---|
| protected final void sb3(int[] X, int a, int b, int c, int d) S3 - { 0,15,11, 8,12, 9, 6, 3,13, 1, 2, 4,10, 7, 5,14 } - 16 terms. | |
| sb4 | back to summary |
|---|---|
| protected final void sb4(int[] X, int a, int b, int c, int d) S4 - { 1,15, 8, 3,12, 0,11, 6, 2, 5, 4,10, 9,14, 7,13 } - 15 terms. | |
| sb5 | back to summary |
|---|---|
| protected final void sb5(int[] X, int a, int b, int c, int d) S5 - {15, 5, 2,11, 4,10, 9,12, 0, 3,14, 8,13, 6, 7, 1 } - 16 terms. | |
| sb6 | back to summary |
|---|---|
| protected final void sb6(int[] X, int a, int b, int c, int d) S6 - { 7, 2,12, 5, 8, 4, 6,11,14, 9, 1,15,13, 3,10, 0 } - 15 terms. | |
| sb7 | back to summary |
|---|---|
| protected final void sb7(int[] X, int a, int b, int c, int d) S7 - { 1,13,15, 0,14, 8, 2,11, 7, 4,12,10, 9, 3, 5, 6 } - 16 terms. | |