Skip to content

Python implementation of LFSR and Berlekamp-Massey algorithm.

License

Notifications You must be signed in to change notification settings

thewhiteninja/lfsr-berlekamp-massey

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LFSR & Berlekamp-Massey algorithm


Python implementation of LFSR and Berlekamp-Massey algorithm.

Example

TEST - LFSR & Berlekamp-Massey

################################## Encryption ##################################

Cleartext       : the secret is: there is no spoon
LFSR init       : x^6 + x^5 + x^1 + 1 (000101)
LFSR stream     : 1745d1745d1745d1745d1745d1745d1745d1745d1745d1745d1745d1745d1745
Ciphertext      : 632db4542e7226a31129372ca24e7d632db40638372ca254337865a20432782b

################################## Decryption ##################################

Known cleartext : the
Stream start    : 1745d1
Recovered LFSR  : x^6 + x^5 + x^1 + 1
LFSR stream     : 1745d1745d1745d1745d1745d1745d1745d1745d1745d1745d1745d1745d1745

Decrypted       : the secret is: there is no spoon

##################################### Test #####################################

Test OK         : True

Releases

No releases published

Packages

No packages published

Languages