Author Topic: DENCrypt v1.5 beta  (Read 9683 times)

0 Members and 1 Guest are viewing this topic.

Offline wchill

  • LV2 Member (Next: 40)
  • **
  • Posts: 35
  • Rating: +1/-0
    • View Profile
DENCrypt v1.5 beta
« on: April 01, 2010, 05:57:56 am »
An encryption program I have decided to share with the world. (Loosely?)Based on the one-time pad.
This encryption is theoretically impossible to crack (IRL, it's just really really hard).
You can either use the program to generate your keys (DOES NOT USE RAND), create a program to rand-generate for you, or make your own keys with random.org or by hand (read readme for details).
Accepts up to a 998 dimension input (list or string). Strings can use alphanumeric characters and some symbols.

Yeah. If you really want to encrypt something on your calculator, here's your solution. I recommend 3000+ bytes free and a TI-83+ SE or better. You'll need more RAM if you're encrypting bigger stuff though.

Enjoy.

Offline Galandros

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1140
  • Rating: +42/-10
    • View Profile
Re: DENCrypt v1.5 beta
« Reply #1 on: April 01, 2010, 08:10:02 am »
One time pad is really impossible to crack if you used a real random number and the pad is not compromised.

Well the computer power to brute force all possible random generators is unimaginable.
To achieve true random numbers as far we know, there is hardware than gives a random number by watching strange physics events that from our current knowledge are random.

To anyone willing to understand what one pad is, search in the wikipedia...
Hobbing in calculator projects.

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: DENCrypt v1.5 beta
« Reply #2 on: April 01, 2010, 08:59:20 am »
mhmm Interesting, I should maybe give this a try to mess around

Offline Raylin

  • Godslayer
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1392
  • Rating: +83/-25
  • I am a certifiable squirrel ninja.
    • View Profile
    • Ray M. Perry
Re: DENCrypt v1.5 beta
« Reply #3 on: April 01, 2010, 11:14:13 am »
I can't really see what I would use this program for...
Any uses...?
Bug me about my book.

Sarah: TI-83 Plus Silver Edition [OS 1.19]
Cassie: TI-86 [OS 1.XX]
Elizabeth: TI-81 [OS 1.XX]
Jehuty: TI-83 Plus Silver Edition [OS 1.19]
Tesla: CASIO Prizm







Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: DENCrypt v1.5 beta
« Reply #4 on: April 01, 2010, 04:50:16 pm »
Encryption?

Offline wchill

  • LV2 Member (Next: 40)
  • **
  • Posts: 35
  • Rating: +1/-0
    • View Profile
Re: DENCrypt v1.5 beta
« Reply #5 on: April 01, 2010, 11:52:52 pm »
Hey, encryption is encryption.
I can't think of any good ideas, but maybe you can.
Also, feel free to modify/redistribute/repackage as you wish.

If anyone has any idea on how to make List to String conversion faster, please tell me how! It's currently the slowest part of the encryption/decryption process.
« Last Edit: April 01, 2010, 11:57:34 pm by wchill »

Offline meishe91

  • Super Ninja
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2946
  • Rating: +115/-11
    • View Profile
    • DeviantArt
Re: DENCrypt v1.5 beta
« Reply #6 on: April 02, 2010, 12:25:00 am »
Well this a variation of code from my Map Converter program but it should help some, hopefully.

Code: [Select]
" ?Str1
For(A,1,dim(L1
Str1+sub("_Q",L1(A)+1,1?Str1
End
sub(Str1,2,WH?Str1

I highly doubt you can use this though just because it only deals with a list with 1's and 0's in it and uses that to create what goes into the string. Hopefully this is a good example to base something off of? If you maybe post your list to string code we could possibly help. :)
« Last Edit: April 02, 2010, 12:27:40 am by meishe91 »
Spoiler For Spoiler:



For the 51st time, that is not my card! (Magic Joke)

Offline wchill

  • LV2 Member (Next: 40)
  • **
  • Posts: 35
  • Rating: +1/-0
    • View Profile
Re: DENCrypt v1.5 beta
« Reply #7 on: April 02, 2010, 12:54:24 am »
The conversion code goes something like this:
-Character set stored to Str0.
-Initialize Str1.
-For( loop through list elements.
-Perform modular arithmetic on list element.
-Place character in string using Str1+ sub(Str0, Ans, 1 -> Str1
-End For( loop.
-sub(Str1, 2, length(Str1)-1 -> Str1 (removes initial space stored to Str1)
« Last Edit: April 02, 2010, 12:54:53 am by wchill »

Offline meishe91

  • Super Ninja
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2946
  • Rating: +115/-11
    • View Profile
    • DeviantArt
Re: DENCrypt v1.5 beta
« Reply #8 on: April 02, 2010, 12:57:36 am »
Well I think that is kinda how my code is set up. So without seeing the actual code I can't really help. Others might though.
Spoiler For Spoiler:



For the 51st time, that is not my card! (Magic Joke)

Offline wchill

  • LV2 Member (Next: 40)
  • **
  • Posts: 35
  • Rating: +1/-0
    • View Profile
Re: DENCrypt v1.5 beta
« Reply #9 on: April 02, 2010, 01:51:37 am »
: " →Str1
:  For(I,1,C)
: ∟ENC(I
: While Ans>length(Str0
: Ans-length(Str0
: End
: Str1+sub(Str0,Ans,1→Str1
: Output(3,1,iPart(100I/C
: End
: sub(Str1,2,length(Str1)-1→Str1

Offline meishe91

  • Super Ninja
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2946
  • Rating: +115/-11
    • View Profile
    • DeviantArt
Re: DENCrypt v1.5 beta
« Reply #10 on: April 02, 2010, 02:27:01 am »
Well I don't see any optimizations or ways to make that shorter or faster. Someone else might though. Sorry.
Spoiler For Spoiler:



For the 51st time, that is not my card! (Magic Joke)

Offline Galandros

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1140
  • Rating: +42/-10
    • View Profile
Re: DENCrypt v1.5 beta
« Reply #11 on: April 02, 2010, 07:10:42 am »
I can't really see what I would use this program for...
Any uses...?
In reality few for calculators... But it has a educative component and fun for others. Also it can serve as TI-BASIC coding experience if you don't have a better idea.
Hobbing in calculator projects.

Offline mapar007

  • LV7 Elite (Next: 700)
  • *******
  • Posts: 550
  • Rating: +28/-5
  • The Great Mata Mata
    • View Profile
Re: DENCrypt v1.5 beta
« Reply #12 on: April 02, 2010, 10:46:44 am »
Quote
This encryption is theoretically impossible to crack (IRL, it's just really really hard).

One-time pads are impossible to break if you have a true source of randomness. (in practice: a sufficiently non-deterministic source)

Basically it does this: (Alice & Bob are the participants, Alice transmits to Bob)

[this is what I remember from reading Bruce Schneier's book 'Applied Cryptography']

Alice and Bob are both in possession of the random string R, of length n. (or both have a cryptographically secure RNG with identical seeds)
Alice wants to transmit message M (with length n) to Bob. She XORs every bit of M with the corresponding bit of R, and transmits the resulting ciphertext C to Bob. Bob, having received C, XORs every bit of C with the corresponding bit of R, thus recreating M. Then, both strings are discarded. (it's insecure to continue using them)

Eve, the eavesdropper, stands nowhere nearer to the solution, since R is completely (at least, in theory) random, and no part of R recurs systematically throughout the ciphertext. Impossible to break this scheme, but hard to implement, since the strings R must be distributed in advance to guarantee security.


EDIT: oops, I missed Galandros' post earlier... Sorry.
« Last Edit: April 02, 2010, 10:48:44 am by mapar007 »

Offline ztrumpet

  • The Rarely Active One
  • CoT Emeritus
  • LV13 Extreme Addict (Next: 9001)
  • *
  • Posts: 5712
  • Rating: +364/-4
  • If you see this, send me a PM. Just for fun.
    • View Profile
Re: DENCrypt v1.5 beta
« Reply #13 on: April 02, 2010, 11:28:47 am »
wchill, I think that's the fastest it will go.  Great code, though! ;D

Offline Raylin

  • Godslayer
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1392
  • Rating: +83/-25
  • I am a certifiable squirrel ninja.
    • View Profile
    • Ray M. Perry
Re: DENCrypt v1.5 beta
« Reply #14 on: April 02, 2010, 11:31:47 am »
What would happen if you expand this a little further?
Perhaps a password program?
Bug me about my book.

Sarah: TI-83 Plus Silver Edition [OS 1.19]
Cassie: TI-86 [OS 1.XX]
Elizabeth: TI-81 [OS 1.XX]
Jehuty: TI-83 Plus Silver Edition [OS 1.19]
Tesla: CASIO Prizm