An open API service indexing awesome lists of open source software.

https://github.com/n1ghtf1re/stream-ciphers

The implementation of the stream ciphers: LFSR, GEFFE, RC4
https://github.com/n1ghtf1re/stream-ciphers

algorithm cipher cipher-algorithms crypto-algorithm crytography geffe-generator lfsr rc4 rc4-algorithm stream-cipher stream-ciphers

Last synced: 7 months ago
JSON representation

The implementation of the stream ciphers: LFSR, GEFFE, RC4

Awesome Lists containing this project

README

          

Stream ciphers



Stars
Total Downloads
Latest Stable Version
License

## About the library
The library contains three stream ciphers: LFSR, Geffe, RC4

## Class LFSR:
### Constructors:
- LFSR(long initRegister, int[] polinom)
- LFSR(String initRegister) - default poinom (x^24 + x^4 + x^3 + x + 1)

### Methods:
- encrypt(byte[]) - return encoded bytes array.
- decrypt(byte[]) - return decoded bytes array.
- generateKey() - return bytes array of key

## Class GEFFE:
### Constructors:
- Geffe(String initRegister1, String initRegister2, String initRegister3, int[] polinom1, int polinom2[], int polinom3[])
- Geffe(String initRegister1, String initRegister2, String initRegister3) - default poinoms (x^24 + x^4 + x^3 + x + 1, x^32 + x^28 + x^27 + x + 1, x^40 + x^21 + x^19 + x^2 + 1)

### Methods:
- encrypt(byte[]) - return encoded bytes array.
- decrypt(byte[]) - return decoded bytes array.
- generateKey() - return bytes array of key

## Class RC4:
### Constructors:
- RC4(String strKey)

### Methods:
- encrypt(byte[]) - return encoded bytes array.
- decrypt(byte[]) - return decoded bytes array.
- generateKey() - return bytes array of key