Skip to content

MahdiKamer/LFSR

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

A 64-bit Binary Stream Cipher (LFSR)

Overview of the Code

  1. The code begins by loading a 64-bit random number as a session key into three mutually clock-controlled shift registers.
  2. The shift registers are then clocked based on the control bits.
  3. The three shift registers merge to form a 64-bit register that maintains the internal state of the cipher.
  4. Finally, a quick sort is performed on all produced internal states, which are then compressed and stored in a file.

Important Notes

  • This code is useful for cryptography training but may not be suitable for real-world attacks.
  • Do not run this code on any machine, as it may cause crashes due to the type of memory allocation used. However, you can modify the code to prevent memory failures. Keep in mind that the "KeyLSB_Low" and "KeyLSB_High" values should be adjusted based on the available memory space and your storage system.
  • Please note that Linear Feedback Shift Registers (LFSR) are pseudorandom generators, meaning they can produce a sequence of numbers with a long period. However, in the case of a 64-bit LFSR, it cannot generate a sequence with a period of $(2^{64})$ due to clock control limitations.
  • If you're looking for an encryption method that is computationally difficult to break, LFSR is a good option for digital systems. However, in analog environments or in novel computing architectures based on entropy or quantum principles, LFSR-based encryption can be relatively easy to intercept.

References

This code is based on publicly available scientific reports, such as:
Cryptanalysis of Three Mutually Clock-Controlled Stop/Go Shift Registers

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages