Skip to content

CircuitPython code for a machine that generates and prints cryptographic one-time pads

Notifications You must be signed in to change notification settings

OHS-awoodbridge/Pad-O-Matic

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pad-O-Matic

Completed Unit

Adapted from the original Pad-O-Matic, modified to:

Geiger Counter click into random numbers

The method used to create random number is to collect the monotonic time of three clicks (time.monotonic_ns()) if the distance between the first two clicks is greater, it's a 1 otherwise it's a 0. I used this method on my previous Radiant Dice project which showed an even distribution over 800,000 clicks.

I have included a datalogging version of the code which uses a Teensy 4.1 because of its SD Card. I have included the integers I've logged for reference/evaluation. I tried a couple different code examples, and I'm not changing the original code, since it seemed to have the least about of bias and used the least amout of bits per digit (5 bit integers). I tried using 8 bit integers as well as as using various mapping functions, and didn't find a better version.

Worksheets for use in my classroom

References

To see the original IEEE Spectrum Hands On article, visit: https://spectrum.ieee.org/diy-one-time-pad-machine Directions adapted from: https://ciphermachinesandcryptology.com/papers/one_time_pad.pdf

About

CircuitPython code for a machine that generates and prints cryptographic one-time pads

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 100.0%