Wednesday, March 8, 2017

Encryption fun, win an Arduino!

Here's a challenge for you all. I'm posting a picture, and a coded phrase. Figure it out, email me, and the first 5 winners get an Arduino Nano clone, and their names (or hacker names) listed as really smart (and geeky) folks!

59221 91430 8117 94007 21268 100714 58135 73658 29992 52388 103243 47570 29961 38689 74327 56189 45120 64972 81138 106187 18809 11348 10965 32969 70849 96470 6350 56264 69516

After the contest is over, I'll post the code, and some really interesting tips on passing virtually unbreakable messages.

Clue: it's a variation on a book cipher!

Next Clue: the numbers above are the positions of the characters in the "book".

Solution:

The image is base64 encoded. That creates the book. Then go to position 59221 and write down the letter found, then position 91430 , and so on.

In the files below, I've built a php based set of utilities for choosing an image, saving it in an uploads folder, and creating the encoded ascii file. You then can input the string to be encoded, and it returns character positions from the "book".  I used a date/time seeded random function to choose one of the available results for each character submitted to reduce the possibility of repeat distribution hacking.

The decode file takes those position codes, and spits out the original phrase. No one has posted the phrase, but the contest is over. Hope you had fun!

https://drive.google.com/open?id=0ByRIq5k2wjcSbGVBaWc4bmFGN00

9 comments:

  1. Replies
    1. Blogger changed the picture when it uploaded, so I had to fix the coded message above. Sorry about that. That's your clue, the picture has something to do with the message.

      Delete
  2. Dang. I must be getting too old....I'm into cryptography and this one is tough.

    ReplyDelete
    Replies
    1. I so want to give a hint, but that will give it away. You will slap yourself when you see it. It's not complicated.

      Delete
  3. Maybe I am over thinking it? You mentioned that the image was important and that it was a variation on a book cipher. If I save the image file as a .PNG or a .Jpg, would that make a difference in breaking your code?

    ReplyDelete
  4. So you posted the answer on FB, but you said all you have to do is convert the binary data to a base64String and use the resulting string as the book to look up the given values in. The thing is, I did this and the base64String it produces is only ~29100 characters long. Are you sure you don't have an error in your code to produce your base64String??

    ReplyDelete
    Replies
    1. The string I get is over 100000 characters. I have encoded, and decoded, and put the string into a web page, and the picture shows. I get my secret phrase output each time. No, there's no error.

      Delete
    2. did you use https://2.bp.blogspot.com/-H0TFeyCKbYI/WMB2ZoWcBWI/AAAAAAAAGS0/WdWhMPVwsuUz8HHl-Brg-B9-BUnsvi8RwCLcB/s1600/grumpycat.jpg as your image?

      Delete