Mark Dain I would have released my One Time Pad program but it looks like last minute a nasty bug appeared which I'm having a real hard time tracking down. Unfortunately I didn't use Git locally so I can't use bisect. Lesson learned; always use version control, even if you're keeping the code locally.
Eric What's it written in?
9y, 12w 3 replies
Mark Dain Go. What's really starting to make me angry is all my unit tests are passing. I literally cannot figure out why the function is failing. I'm going to leave this till tomorrow, else my stress levels are going to get too high.
9y, 12w 2 replies
Login or register your account to reply
Martijn Unit tests on an OTP? Isn't an OTP just a bitwise XOR? What are you testing for?
9y, 12w 1 reply
Mark Dain The encryption code is easy to test; m = D(k, E(k, m)), among others but there's a lot more stuff that comes with the program including pad generation and management. It'll increment the spent counter and zero out the bytes to stop you from double spending. What's broken is I'm getting an out of bounds error when the program asks for len(m) unspent bytes. I need to sleep on this, I can't see what's probably an obvious error.
9y, 12w reply