| Modifier and Type | Class and Description |
|---|---|
| public static class | IndexGenerator.BitString
Represents a string of bits and supports appending, reading the head, and reading the tail. |
| Modifier and Type | Field and Description |
|---|---|
| private IndexGenerator. | |
| private int | |
| private int | |
| private Digest | |
| private int | |
| private boolean | |
| private int | |
| private int | |
| private int | |
| private byte[] | |
| private int |
| Access | Constructor and Description |
|---|---|
| pack-priv | IndexGenerator(byte[]
a seed of arbitrary length to initialize the index generator with seed, NTRUEncryptionParameters NtruEncrypt parameters params)Constructs a new index generator. |
| Modifier and Type | Method and Description |
|---|---|
| private void | |
| private static byte[] | |
| pack-priv int | |
| private void |
| buf | back to summary |
|---|---|
| private IndexGenerator. | |
| c | back to summary |
|---|---|
| private int c | |
| counter | back to summary |
|---|---|
| private int counter | |
| hashAlg | back to summary |
|---|---|
| private Digest hashAlg | |
| hLen | back to summary |
|---|---|
| private int hLen | |
| initialized | back to summary |
|---|---|
| private boolean initialized | |
| minCallsR | back to summary |
|---|---|
| private int minCallsR | |
| N | back to summary |
|---|---|
| private int N | |
| remLen | back to summary |
|---|---|
| private int remLen | |
| seed | back to summary |
|---|---|
| private byte[] seed | |
| totLen | back to summary |
|---|---|
| private int totLen | |
| IndexGenerator | back to summary |
|---|---|
| pack-priv IndexGenerator(byte[] seed, NTRUEncryptionParameters params) Constructs a new index generator.
| |
| appendHash | back to summary |
|---|---|
| private void appendHash(IndexGenerator. | |
| copyOf | back to summary |
|---|---|
| private static byte[] copyOf(byte[] src, int len) | |
| nextIndex | back to summary |
|---|---|
| pack-priv int nextIndex() | |
| putInt | back to summary |
|---|---|
| private void putInt(Digest hashAlg, int counter) | |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv byte[] | |
| pack-priv int | |
| pack-priv int |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv void | |
| public void | |
| public byte[] | |
| public int | Returns: anint whose lower numBits bits are the beginning of the bit stringnumber of bits numBits)Returns up to 32 bits from the beginning of the bit string. |
| public IndexGenerator. | Returns: a newBitString of length numBitsnumber of bits numBits)Returns the last |
| bytes | back to summary |
|---|---|
| pack-priv byte[] bytes | |
| lastByteBits | back to summary |
|---|---|
| pack-priv int lastByteBits | |
| numBytes | back to summary |
|---|---|
| pack-priv int numBytes | |
| BitString | back to summary |
|---|---|
| public BitString() | |
| appendBits | back to summary |
|---|---|
| pack-priv void appendBits(byte[] bytes) Appends all bits in a byte array to the end of the bit string.
| |
| appendBits | back to summary |
|---|---|
| public void appendBits(byte b) Appends all bits in a byte to the end of the bit string.
| |
| getBytes | back to summary |
|---|---|
| public byte[] getBytes() | |
| getLeadingAsInt | back to summary |
|---|---|
| public int getLeadingAsInt(int numBits) Returns up to 32 bits from the beginning of the bit string.
| |
| getTrailing | back to summary |
|---|---|
| public IndexGenerator. Returns the last
| |