How "unbreakable" is my code?
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 11 of 11

Thread: How "unbreakable" is my code?

  1. #1
    Join Date
    Mar 2013
    Posts
    4

    How "unbreakable" is my code?

    So I came up with a new form (to my knowledge) of code last night.

    It has obvious cryptographic applications, and fascinatingly can also be applied to programming language.

    The beauty of this is it's affinity for randomness. Any symbol can be used, and the values, while still somewhat a defined set, have an almost infinite number of variations available. (Hint1)

    I need your help to see how "unbreakable" it is. So all of you who have any skill or interest in this area, please try and crack my code!

    It's in English, a quote from a philosopher who lived 2500 years ago in Asia, and it's one sentence. (Hint2)

    Name:  qode1fin.jpg
Views: 304
Size:  38.8 KB

    Here's a pastebin of it so you can copy and paste in a text editor to better have at it : http://pastebin.com/Rv4HLHVX

    Sorry if this is in the wrong forum or anything. This is my first post here.

    Thanks for your time!

  2. #2
    Join Date
    Mar 2013
    Location
    Saint Petersburg, Florida, USA
    Posts
    4

    Re: How "unbreakable" is my code?

    "Everything has its beauty, but not everyone sees it"

    "Wherever you go, go with all your heart."

  3. #3
    Join Date
    Jan 2006
    Location
    Singapore
    Posts
    6,322

    Re: How "unbreakable" is my code?

    What's the algorithm? Of course, if you cannot tell us that as it would allow your encryption to be broken easily, then your encryption algorithm is probably snake oil and you need to read up on Kerckhoffs' principle before proceeding.
    C + C++ Compiler: MinGW port of GCC
    Build + Version Control System: SCons + Bazaar

    Look up a C/C++ Reference and learn How To Ask Questions The Smart Way
    Kindly rate my posts if you found them useful

  4. #4
    Join Date
    Mar 2013
    Posts
    4

    Re: How "unbreakable" is my code?

    Hi Kevin, thanks for trying! I love the quotes you came up with, unfortunately they are not the correct answer . I encourage you to try again though!

  5. #5
    Join Date
    Mar 2013
    Posts
    4

    Re: How "unbreakable" is my code?

    Laserlight! You're sharp as a tack, and I appreciate your input. The code is sound according to Kerckhoffs' principles, however, I will maintain obscurity not in the interest of protecting
    the actual message, but the novel system used. If I gave away the principle behind the cipher, you still would be hard pressed to decrypt the message. You could, however, just use your own key and present a new system as your own (and profit through the sale of such). I hope my response doesn't discourage you from trying your hand at it's decryption though! At best you can try your hand at a fun, and challenging problem, and have a new and unique idea to wrap your head around. At worst, I have no idea what I'm talking about and my code is weak and easily broken. No sweat, either way
    Last edited by 051R15; March 21st, 2013 at 10:10 AM. Reason: grammar

  6. #6
    Join Date
    Feb 2011
    Location
    United States
    Posts
    1,006

    Re: How "unbreakable" is my code?

    Resisted my attempt to decrypt it using HMM-based frequency analysis . But I am not an accomplished cryptanalyst, so that might not mean much. Might have to do with not knowing what the possible character set is (are lower case letters allowed? which punctuation marks, if any, are included? are spaces included?). Might try again if I knew about the input character set.

    In any event, here is the cyphertext, translated into a more useful format, for anyone who wants to have a go at it:

    00 01 01 02 03 04 01 03 05 06 03 05 07 01 05 07 04 08 06 05 03 08 09 07 05 03 10 03 11 08 07 11 05 10 03 13 08 05 07 11 12 09 10 08 01 11 06 13 09 05 12 11 07 03 08 14 11 15 10 03 07 05 11 14 15 08 16 11 05 10 12 13 03 11 07 14 08 15 17 05 11 00 07 08 18 12 19 11 18 05 03 07 11 08 01 20 14 15 18 05 20 11 03 17 21 20 16 18 07 22 08 11 20 12 05 15 14 18 04 13 07 05 20 08 11 04 18 03 01 20 05 22 04 14 06 23 24 04 23 18 20 23 11 04 24 23 10 03 04 23 08 23 04 05 15 23 04 07 20 24 23 14 23 04 23 18 23 04 11 23 22 23 05 25 25 25 25 25 23 25 25 25 25 25 04 25 03 25 25 25 20 25 25 25 01 23 25

    Each pair of numbers (separated by spaces) indicates one of the unicode symbols from the initial pastebin post.
    Best Regards,

    BioPhysEngr
    http://blog.biophysengr.net
    --
    All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.

  7. #7
    Join Date
    Jan 2006
    Location
    Singapore
    Posts
    6,322

    Re: How "unbreakable" is my code?

    Quote Originally Posted by 051R15
    The code is sound according to Kerckhoffs' principles, however, I will maintain obscurity not in the interest of protecting the actual message, but the novel system used.
    By saying that, it means that you have no clue as to what I was talking about. Kerckhoffs' principle implies that the attacker knows the algorithm.

    Furthermore, keeping the algorithm secret is not very useful when you want to bring this up for discussion here, or indeed in any public forum. For example, I could also claim to have developed a novel cryptosystem. Secretly, I use a one time pad to encrypt, then present the ciphertext as a challenge. Thus, it appears that my undisclosed novel cryptosystem is unbreakable.

    Quote Originally Posted by 051R15
    If I gave away the principle behind the cipher, you still would be hard pressed to decrypt the message.
    Problem is that plenty of "snake oil" cryptosystems make the same claim. Are you an expert cryptographer? Did you get experts to review your work? It sounds like a "no" to me, otherwise you would not be asking for help to 'see how "unbreakable" it is'.

    Quote Originally Posted by 051R15
    You could, however, just use your own key and present a new system as your own (and profit through the sale of such).
    Then patent your system.
    C + C++ Compiler: MinGW port of GCC
    Build + Version Control System: SCons + Bazaar

    Look up a C/C++ Reference and learn How To Ask Questions The Smart Way
    Kindly rate my posts if you found them useful

  8. #8
    Join Date
    Mar 2013
    Posts
    4

    Re: How "unbreakable" is my code?

    BioPhysEngr, there is no punctuation present, or spaces, although these may be added. I did not for the sake of simplicity. There is no difference here for upper or lowercase letters. You are on the right track for sure by using unicode to make better sense of the symbols, however you have several steps to go through before you could apply HMM analysis (mind you, I'm no expert in this), though when you do, I believe the set displays multivariate hypergeometric distribution.

    laserlight, I fully stand by my last response. I understand it is common protocol for the "l33t" on forums to grill the forum "n00bs", but this is supposed to be fun. My entire life I've enjoyed cracking ciphers and codes of all kinds, and I've presented my code here knowing that others also enjoy challenges of this kind. If you are completly dead set on not giving this a shot, it's your time and effort, and no one is forcing your hand. And this is no Vernam cipher, as stated in the opening post if you read closely. I do appreciate and thank you for your input though, as it clarifies things a bit for the interested. I'd like to add, your usage of the term "snake oil" implies I'm trying to sell you something, and I am not. Thought I would point this out before someone got the wrong idea. I'd also be wary of making assumptions about my background and who else may have seen and tried to decrypt this. After all, to assume anything makes a "blank" out of you and me.
    Last edited by 051R15; March 30th, 2013 at 06:07 PM. Reason: to add

  9. #9
    Join Date
    Jan 2006
    Location
    Singapore
    Posts
    6,322

    Re: How "unbreakable" is my code?

    Quote Originally Posted by 051R15
    I understand it is common protocol for the "l33t" on forums to grill the forum "n00bs", but this is supposed to be fun.
    My apologies if this came across as "grilling", but my intention is to respond to what I see is your request for help, rather than say, a fun challenge to solve. Not that we cannot have both simultaneously, of course

    Quote Originally Posted by 051R15
    And this is no Vernam cipher, as stated in the opening post if you read closely.
    Yeah, I'm not saying it is or that you're not telling the truth. I was presenting a scenario in which there could be a practical problem of someone providing the same information as you did might not telling the truth, for whatever gain they perceive.

    Quote Originally Posted by 051R15
    I'd like to add, your usage of the term "snake oil" implies I'm trying to sell you something, and I am not. Thought I would point this out before someone got the wrong idea.
    I'm using "snake oil" to mean those weak ciphers that have been presented as strong ones, rather than an actual attempt to sell an implementation of such a cipher. It might be inaccurate use it here given the historical background of the term, so if you got the wrong idea, my bad.

    Quote Originally Posted by 051R15
    I'd also be wary of making assumptions about my background and who else may have seen and tried to decrypt this.
    It is not so much an assumption but a conclusion that I have tentatively come to considering that you posted here rather than in a crypto specific group and replied the way you did concerning Kerckhoffs' principle. I could be wrong, of course: you could be an expert posting this as just a fun challenge, in which case my replies so far are off the mark: your game, your rules. However, if you are indeed looking for assistance 'to see how "unbreakable" it is', then your refusal to provide the algorithm is inconsistent with what an expert looking for such assistance would provide.
    C + C++ Compiler: MinGW port of GCC
    Build + Version Control System: SCons + Bazaar

    Look up a C/C++ Reference and learn How To Ask Questions The Smart Way
    Kindly rate my posts if you found them useful

  10. #10
    Join Date
    Feb 2011
    Location
    United States
    Posts
    1,006

    Re: How "unbreakable" is my code?

    Several observations:

    (1) The presence of 26 distinct glyphs suggests some sort of substitution cypher.
    (2) The cypher does not appear to be a simple polyalphabetic substitution cypher using a key of size 10 or less, based on index of coincidence analysis.
    (3) The length of the cyphertext is unusual: 197, a prime number. Possibly co-incidental, but could be related to the encryption method. Perhaps a stream cypher having something to do with the group of integers modulo 197? It is not clear what the key might be (can't think of an obvious exponential keyspace).
    Best Regards,

    BioPhysEngr
    http://blog.biophysengr.net
    --
    All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.

  11. #11
    Join Date
    May 2009
    Posts
    2,413

    Re: How "unbreakable" is my code?

    Quote Originally Posted by BioPhysEngr View Post
    Several observations:
    According to one of the hints the message consists of a single sentence. But then 197 symbols seem like too many, it would be a very long sentence. This suggests a redundant code is used.

    If so a possible scheme goes like this: First the original message is expressed using an error correcting code. Then errors are introduced at random resulting in an encrypted message. Decryption would mean these errors are detected and corrected. Finally the message is translated back from the error correcting code recovering the original.

    This approach fits the other hint very well that speaks of "affinity for randomness". Error correcting codes have been around for ages but what may be novel is the introduction of errors on purpose to achieve randomization.
    Last edited by nuzzle; April 4th, 2013 at 01:10 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center