#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2013
    Location
    USA
    Posts
    13
    Rep Power
    0

    New Cryptographic Algorithm


    Yeah, I know... ANOTHER new algorithm! But hey... why not?

    If anyone is interested in the details, I built an algorithm and a functional pseudo program that encrypts and decrypts plaintext using a 1024-bit user-seeded key. Here is a sample ciphertext from it, encoded in base64:

    8q2TaFqqKg87nLJGo+WSxhrl6wbti1j8FAWnVcWO7V+ZQvzvicF4a/QME8MLgdQn3TLgoS0UV0r4wxpevorissEp/nu3dz+cPQTOpwvxHk+Yv3kDzk2DNCepgf/EfVDPcbgo7SwuXrHgw/cylg7xkcNmp+iFJhF6LWk+3Sgtjhr6ntcD3LQv0I4ZA7nQD2UgFR0/1gjUX5LnnHNennUpZ/4jz9oFVlmphJfG61nptmf7lYdCTwzNdWywyM0Tz6nZrhJgN+rTEWWFsYabKDLwupPyidlsnzPKs2gYoJxh79bHLLPd62cyx7nH6/n/eNi92WlOmLdaByQSTqVJqCYcIeLLG79WliGwUJfRuEQwfQoFFEKnJzVWIfM2D0NyeWUvV4CahJDvO+8VO7mTr1EQp5B8L2fpJWM1 0CS/eeQAdGQfXsLjDD9ib0xuXt9MdsOljiSYtovo4skOKrNBdEQu/ByRHoyivIZdUsvOpETio8n3eXUI4d49xlMmCfQoOqpsyjVOesjwMxEzBKe6+HFVdDUPxTRXFkz0zsiLZUZtsfatZWVnLiSdJKfPO Bq0mPvnLEbXCQNfkfQV5FvYgCxu3rM=

    Anyone care to analyze it or beat on it to see how it stands up to scrutiny?
  2. #2
  3. Contributed User
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    Jun 2005
    Posts
    4,444
    Rep Power
    1873
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2013
    Location
    USA
    Posts
    13
    Rep Power
    0
    Originally Posted by salem
    What part of "if anyone is interested in the details" indicates that I intend to keep any part of the algorithm a secret? If someone expresses interest, I'll go to the trouble of posting the details.

    Idea: if you have no interest in the thread... don't post?
  6. #4
  7. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2013
    Location
    USA
    Posts
    13
    Rep Power
    0
    Originally Posted by salem
    Secret Algorithms
    I offered to disclose the details, should someone express interest. Otherwise, I'm not going to bother. Either way, your non-post proceeds from a false assumption.
  8. #5
  9. Contributed User
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    Jun 2005
    Posts
    4,444
    Rep Power
    1873
    Why don't you just post the damn algorithm and stop wasting peoples time with random (and broken) dumps of the encrypted output.

    If you want a serious debate, post the algorithm or the source code.

    After all, there's nothing stopping me saying "I know how to decode your algorithm, but I'm not going to tell you how I did it".

    At that point, your game is over - nobody will believe your little secret scheme is secure.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper
  10. #6
  11. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2013
    Location
    USA
    Posts
    13
    Rep Power
    0
    Originally Posted by salem
    Why don't you just post the damn algorithm and stop wasting peoples time with random (and broken) dumps of the encrypted output.

    If you want a serious debate, post the algorithm or the source code.

    After all, there's nothing stopping me saying "I know how to decode your algorithm, but I'm not going to tell you how I did it".

    At that point, your game is over - nobody will believe your little secret scheme is secure.
    Hmmm. Sounds like someone needs to get out a little more. Does this site have an ignore feature?
  12. #7
  13. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2013
    Location
    USA
    Posts
    13
    Rep Power
    0
    Update: I found the ignore list. Happy Day!
  14. #8
  15. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2013
    Location
    USA
    Posts
    13
    Rep Power
    0
    OK...I'm posting the algorithm, but not because mister high-strung above demands it. My apologies if my terminology isn't exactly "industry standard." I'm a newb to the field.

    1. User Inputs (ASCII only):
    a. Plaintext message ($M)
    b. Password 1 ($P1)
    i. Passwords greater than 64 bytes are rejected
    c. Password 2 ($P2)
    i. Passwords greater than 64 bytes are rejected
    2. Key 1 Derivation ($K1)
    a. Obtain base-10 salt ($P1S) from $P1 through a looped calculation: ($P1S + ($P1n(v *2)) where n = an integer representing the position in $P1 and v = an integer
    i. initial values: n = 1 ; v = 2
    ii. with each cycle, n and v are increased by 1; loop ends when n = length of $P1
    b. Extract base-10 constant-lookup value ($P1L) from $P1S
    i. $P1L = last two digits of $P1S
    c. Salt $P1 with $P1S using addition modulo 10 per char of $P1; result: $P1T
    d. Convert $P1T to Binary ; result: $P1B
    e. Expand $P1B to 512 bits through a looped calculation: ($P1B & ($P1B shifted 1 bit to the left) ; XOR the resultóbit by bitówith a 512-bit constant looked up from $P1L) ; result: $P1EK
    f. Shift $P1EK in three cycles of two parts (result: $K1):
    i. Part 1: XOR $P1EK bit by bit with the constant used looked up through $P1L
    ii. Part 2: shift the result n bits to the left, where n = $P1L
    3. Key 2 Derivation ($K2)
    a. $K2 is derived in an identical manner as is $K1, with the exception that the various 512-bit constants used to derive $K2 are different than those used to derive $K1
    4. Final Key Derivation ($K)
    a. $K1 and $K2 are interleaved, bit by bit, to form a 1024-bit string ($S)ó$K1 interleaves from back to front, $K2 interleaves from front to back
    b. Extract base-10 constant-lookup value ($SL) from $S using the result ($C) of a looped calculation: ($C + ($Sn[u](v *2)) where n = an integer representing the position in $P1, u = number of digits modified and v = an integer
    i. initial values: n = 1 ; u = 2 (fixed) ; v =1.01
    ii. with each cycle, n is increased by 2 and v is increased by .01 ; loop ends when n + 2 > length of $S
    iii. $SL = the last two digits of $C
    c. Shift $S in three cycles of two parts (result: $K):
    i. Part 1: XOR $S bit by bit with a looked-up 512-bit constant from $SL
    ii. Part 2: shift the result n bits to the left, where n = $SL
    5. Encryption ($Y) of Plaintext Message ($M)
    a. Extract base-10 constant-lookup value ($TL) from $M using the result ($C) of a looped calculation: ($C + ($Mn(v *2)) where n = an integer representing the position in $M and v = an integer
    i. initial values: n = 1 ; v = 1.01
    ii. with each cycle, n is increased by 1 and v is increased by .01 ; loop ends when n = length of $M
    iii. $TL = the last two digits of $C
    b. Convert $M to Binary ; result: $MB
    c. Add padding to $MB until modulo 64 of $MB = 0 ; result: $MB
    d. Convert $TL to binary and append to $MB ; result: $MB
    e. XOR $MB bit by bit with a looked-up 512-bit constant from $TL ; result: $MX
    f. XOR $MX bit by bit with $K ; result: $ME
    i. if $MX is longer than $K, shift $K one bit to the left for each new cycle
    g. Encode $ME in base-64 ; result: $M64
    h. Add padding to $M64 until modulo 8 of $M64 = 0 ; result: $Y

IMN logo majestic logo threadwatch logo seochat tools logo