PiCRYPT.org

What is Picrypt?

Picrypt was created by Ted Kubaitis in April, 2016. Picrypt is a very chaotic cipher. It is a new kind of Vigenere cipher. The main difference is the encrypted values don't represent the data, but rather the address of where the data can be found in the digits of Pi. The hypothesis is that the stronger the password the stronger the encryption. In a nutshell this encryption algorithm searches for your data in the infinite series of Pi (to make it fast we are just using the first million) but the offsets are messed up by rotating the bytes of your password and factoring in the password checksum so the only way to decrypt the data is to brute force the password. At least that is my proposed hypothesis.

How does Picrypt work?

  1. get the length of the password
  2. get the sum of the bytes in the password
  3. set the initial offset in Pi to password length * sum of password bytes
  4. for each byte of content
    1. rotate each byte of password for each byte of content to increase the initial offset
    2. get the current byte and the next byte ('.' if no next byte)
    3. create zero padded 3 digit ASCII values for both bytes
    4. from our current offset search pi for consecutive digits matching the two bytes
    5. return the number of bytes scanned to find the matching bytes as the encrypted value for current byte
  5. return a comma delimited list of integer offsets as the encrypted data

How Strong is Picrypt?

Honestly, I don't know. I need help figuring this out. I would assume it is weak until industry experts prove it is otherwise.

Why does Picrypt use Pi?

It doesn't have to... you could use a million random digits for the public key, but Pi is already everywhere so it seemed cool to use it for the public part of the cipher.

Why use Picrypt when there are proven alternatives?

Boring! If you like math and encryption why not explore new ideas? But don't use it for anything important until it gets approved by better experts than me. :-)

Download Source Code

jquery-picrypt-locker.js source
pycrypt.js source
pi1m.js source (warning: 1MB)

Encrypting Content



How This Example Works:

pycrypt.js source
pi1m.js source (warning: 1MB)
        jQuery( "#encryptButton" ).on( "click", function() {
            var pw1 = jQuery("#pw1").val();
            var text1 = jQuery("#text1").val();
            jQuery("#output1").html(picrypt.encrypt(text1,pw1));
        });
            

Decrypting Content



How This Example Works:

pycrypt.js source
pi1m.js source (warning: 1MB)
        jQuery( "#decryptButton" ).on( "click", function() {
            var pw2 = jQuery("#pw2").val();
            var text2 = jQuery("#text2").val();
            jQuery("#output2").html(picrypt.decrypt(text2,pw2).join(""));
        });
            

A Picrypt Content Locker

hint: the password is wunwunkickdoor!

67828,145193,71442,11093,68608,60069,170928,48,108858,135811,22429,50922,310298,66866,197455,89147,48557,35151,194475,58007,71443,225163,61114,155293,8995,81772,310298,47423,67205,129402,31506,126792,118537,135208,89149,48564,67402,58019,547042,28598,89166,81761,42,38259,42872,47303,310572,310299,310290,66863,71442,29882,210320,241821,1821,118547,238756,18553,294895,26369,23529,50916,11891,204093,6538,11412,8995,84269,89167,145203,71452,11101,68614,60065,171002,34,28588,89156,14462,210603,2193,79358,10361,9003,209845,14481,47423,209841,110994,27899,67380,122357,11891,204093,26285,23538,50926,547036,8706,96364,89166,48563,45940,14971,225237,60376,41200,8992,12176,299794,149706,45017,96366,294910,26295,23548,67388,122363,310295,66947,10423,320441

How This Example Works:

The encrypted content needs to contain <unlocked/> so the library knows when the password is correctly entered.
jquery-picrypt-locker.js source
pycrypt.js source
pi1m.js source (warning: 1MB)
    <div class="picrypt">67828,145193,71442,11093, ... ,320441</div>
            
    jQuery( document ).ready(function() {
        picryptContentLocker.activateContentLockers();
    });
            

Code Breaker's Challenge


It's just a picrypt content locker. See if you can crack the code!

NOTE: Please do not send web requests to my server. This is all done with client-side javascript. No web requests are needed to brute force this.

204492,4146,91447,96330,10660,25003,26182,249310,65269,29707,76152,77742,217755,30606,84999,240808,58597,5400,1753,152745,19449,48755,32431,98191,37132,48725,5480,204563,16326,30638,152698,249321,32344,16246,16624,20925,72727,68962,51670,188372,105184,271605,96331,58658,44662,97584,19368,249243,442033,51196,121412,54798,154045,271608,72706,136808,83741,249313,79701,102957,137022,34949,60362,58654,20277,23904,181507,16310,30568,152736,37939,9764,20938,23895,55625,217836,30624,146913

<div class="picrypt">204492, 4146, 91447, 96330, 10660, 25003, 26182, 249310, 65269, 29707, 76152, 77742, 217755, 30606, 84999, 240808, 58597, 5400, 1753, 152745, 19449, 48755, 32431, 98191, 37132, 48725, 5480, 204563, 16326, 30638, 152698, 249321, 32344, 16246, 16624, 20925, 72727, 68962, 51670, 188372, 105184, 271605, 96331, 58658, 44662, 97584, 19368, 249243, 442033, 51196, 121412, 54798, 154045, 271608, 72706, 136808, 83741, 249313, 79701, 102957, 137022, 34949, 60362, 58654, 20277, 23904, 181507, 16310, 30568, 152736, 37939, 9764, 20938, 23895, 55625, 217836, 30624, 146913</div>

Share the code or content if you crack it!

Picrypt Anywhere Plugin

#picrypt#192597,91586,79571,84370,147085,13046,14284,237371,53373,17763,73093,228852,46717,43664,20469,163747,140783,79569,92899,144911,58901,10490,21856,188548,140781,48293,86216,60813,71841,7860,25170,65216,361904,7619#/picrypt#