Re: [Cfrg] Crystalline Cipher

Ryan Daurne <rdaurne77@gmail.com> Thu, 21 May 2015 20:50 UTC

Return-Path: <rdaurne77@gmail.com>
X-Original-To: cfrg@ietfa.amsl.com
Delivered-To: cfrg@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 38F051A8AE2 for <cfrg@ietfa.amsl.com>; Thu, 21 May 2015 13:50:46 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: 0.95
X-Spam-Level:
X-Spam-Status: No, score=0.95 tagged_above=-999 required=5 tests=[BAYES_50=0.8, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, SPF_PASS=-0.001] autolearn=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Y-zR9Nk8TzOR for <cfrg@ietfa.amsl.com>; Thu, 21 May 2015 13:50:44 -0700 (PDT)
Received: from mail-wi0-x230.google.com (mail-wi0-x230.google.com [IPv6:2a00:1450:400c:c05::230]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id F19171A8ADA for <cfrg@irtf.org>; Thu, 21 May 2015 13:50:43 -0700 (PDT)
Received: by wichy4 with SMTP id hy4so27100383wic.1 for <cfrg@irtf.org>; Thu, 21 May 2015 13:50:42 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=ooFjzaNNTOvNONRTzQg96SBwbMeir3oFmULD6OAh8t8=; b=M6FmU5s4bj9FLOmAeXMicFXS0HeL3dxEwLrUJ0cUF0kAQItPUIfhXMWZkPfFsm9oQ6 p0YVCt9JMccwLEWnUsZ/yVKwM8nqCR/t6opfxYI1xcoLC6+Cn/PSD8C0fBjdbJWG2AtT MzDzcB/V7Y5BxteKAKTzHhX8U9gl0/Ra4KAoopkANM+x+ts4Deg4MZDoGmeAnmznE4+t GibdJI3yuSrBij3pr0I7daf5x69mUpiLOz4x22u4ACUKLoXPNBSaVoYeiBnMgJujRgf+ mnmivBL9zXgqNU+n8QHO5oJeTpVJRNBLObB97t/EmN4r+2sWPJ7kv6cvRUP20XBDj84A qFOw==
X-Received: by 10.194.9.161 with SMTP id a1mr8726199wjb.39.1432241442672; Thu, 21 May 2015 13:50:42 -0700 (PDT)
Received: from [192.168.0.13] (97e180cc.skybroadband.com. [151.225.128.204]) by mx.google.com with ESMTPSA id l6sm4553849wib.18.2015.05.21.13.50.41 for <cfrg@irtf.org> (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 21 May 2015 13:50:41 -0700 (PDT)
Message-ID: <555E4524.2060600@gmail.com>
Date: Thu, 21 May 2015 21:50:44 +0100
From: Ryan Daurne <rdaurne77@gmail.com>
User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0
MIME-Version: 1.0
To: cfrg@irtf.org
References: <78c28854a0cbb9ab7930141285059c6c@mail.eclipso.de> <2F4CC1DD-32CE-4D0A-B8F6-7BCEAD39F931@shiftleft.org> <55433468cb391822b334aa3363962202@mail.eclipso.de> <CAHOTMVJa64otGeoRYrQVRTwt53_0Dpa_s8Hgg5PVMLo8eWeXLg@mail.gmail.com> <385e922556bc3cabb98f7bb3f7faa47b@mail.eclipso.de> <555D7E95.9080500@shiftleft.org> <8e7ec9ae7082fac7061fe60faaa00106@mail.eclipso.de> <555DF1B7.4010500@shiftleft.org> <b5451ad486d461a38a6d19655322cfd3@mail.eclipso.de> <264518D0-89EE-427C-B011-B1582B9C98E2@shiftleft.org> <aa8324752ab4c6ec26650852318766f4@mail.eclipso.de>
In-Reply-To: <aa8324752ab4c6ec26650852318766f4@mail.eclipso.de>
Content-Type: text/plain; charset="windows-1252"; format="flowed"
Content-Transfer-Encoding: 7bit
Archived-At: <http://mailarchive.ietf.org/arch/msg/cfrg/WQrO1cS81f-CmF1W6P5b5b_h4S8>
Subject: Re: [Cfrg] Crystalline Cipher
X-BeenThere: cfrg@irtf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Crypto Forum Research Group <cfrg.irtf.org>
List-Unsubscribe: <http://www.irtf.org/mailman/options/cfrg>, <mailto:cfrg-request@irtf.org?subject=unsubscribe>
List-Archive: <http://www.irtf.org/mail-archive/web/cfrg/>
List-Post: <mailto:cfrg@irtf.org>
List-Help: <mailto:cfrg-request@irtf.org?subject=help>
List-Subscribe: <http://www.irtf.org/mailman/listinfo/cfrg>, <mailto:cfrg-request@irtf.org?subject=subscribe>
X-List-Received-Date: Thu, 21 May 2015 20:50:46 -0000

Hi Mark,

Let us compare: 
https://www.schneier.com/crypto-gram/archives/1999/0215.html#snakeoil 
and http://www.interhack.net/people/cmcurtin/snake-oil-faq.html with 
your statements:

FAQ: Beware of any vendor who claims to have invented a ``new type of 
cryptography'' or a ``revolutionary breakthrough.''
Mark: Crystalline adopts a unique (as far as I know) approach to encryption.

Schneier: Warning Sign #4: Extreme cluelessness.
Mark: the cipher appears to be information-theoretically secure
Mark: the fud that has been posted to this group in regards to what is, 
or is not, a break in a cipher.

Schneier: Warning Sign #5: Ridiculous key lengths.
Mark: The recommended minimum key/salt length is 16KB, providing an 
effective key strength of 131072 bits. The key/salt size is arbitrary 
and can be extended to Gigabytes or a continuous random stream if necessary.
Mark: In general, security should improve as the key size grows.

Schneier: Warning Sign #6: One-time pads.
Mark: In short, the final ciphertext contains no mathematical 
relationships and is impractical to attack by brute-force. This is 
effectively the same as a one-time pad.

Schneier: Warning Sign #7: Unsubstantiated claims.
Mark: When you examine the byte stream, it is chaotic and the 
salt/key/plaintext are mathematically unrecoverable.

FAQ: Be wary of anything that claims that competing algorithms or 
products are insecure without providing evidence for these claims.
Mark: I would like to understand why the list has become dedicated to 
the likes of AES and Eliptic curve cryptography. Coincidently, the same 
techniques and ciphers being pushed by the NSA. Many people, including 
myself, don't trust these techniques and feel that there is a certain 
dollar amount in hardware before weaknesses emerge.

In regards to relevance to this list, I hope that providing 
entertainment to readers to improve morale will suffice.

Regards,

Ryan Daurne

On 21/05/2015 20:34, Mark McCarron wrote:
> Hi Mike,
>
> The goal is to understand where the bodies are buried in the cipher 
> and of what practical consequence those flaws are.  I'm a 
> traditionalist when it comes to ciphers, their function is to hide a 
> message/file and ensure it can only be recovered using the key.  I 
> understand that from the perspective of logic, I must remove the 
> ability of an attacker to relate information to ensure a cipher cannot 
> be broken.  I must present an attacker with a ciphertext from which he 
> can compute nothing of value.
>
> Let's look at the information you requested.
>
> 1. What is your cipher supposed to do?
> Rearrange the contents of a file at the binary and byte level in such 
> a manner that it can only be reversed by those possessing the key.
>
> 2. How should I use it?
> In its simplist form, supply the plaintext, key, salt and IV and 
> execute the program.
>
> 3. What does it mean for it to be secure or broken?
> To be secure, there should be no means for an attacker to 
> computationally (including quantum) retrieve the plaintext, key, salt 
> or IV other than brute force.  Exceptions can be made in certain 
> 'test' scenarios such as a file filled with 0x00, as long as this can 
> be corrected by applying compression.  To be broken, partial 
> (substantially useful) or complete recovery of the plaintext, key, 
> salt and/or IV given only a randomly selected ciphertext.
>
> How big of a key should I use?
> A key that is beyond any realm of possibilty of ever being able to 
> brute force.  A key that is impractical to memorise. At a minimum, 
> 16KB with no upper limit.
>
> What does the salt do, and how big does it need to be?
> It increases the solution space and reduces attack surface of the 
> cipher.  It also serves to mask the key.  Conceptually, it can also be 
> thought of as a split key.  Crystalline, in its final form, will allow 
> unlimited keys and unlimited salts to be added to any encryption process.
>
> What does the IV do, and how do I need to choose it?
> This value is user supplied and can be selected any in manner a user 
> wishes.  Randomly would be best.  It increases the solution space and 
> reduces the attack surface of the cipher.  In the Beta 3 code (not 
> released yet, but in CodePlex), it computes values to be selected from 
> the key and salt, which are then used to compute how many iterations 
> (rounds) the cipher will perform.  Presently, this will be a value of 
> between 10 and 27 iterations (rounds) inclusive.  A further usage (yet 
> to be implemented for Beta 3) is the randomisation of the starting 
> point in the circular buffer for the plaintext, key and salt in each 
> round.  This will vastly increase the solution space and again reduce 
> the attack surface.
>
> How many messages can I encrypt with the same key, salt and IV?
> This is a complex question to answer.  As the cipher moves bits and 
> bytes, the patterns that emerge in the ciphertext are a product of 
> random noise and the bits are a product of the plaintext coupled with 
> an XOR process.  This is further complicated by the fact that the 
> process runs in a manner which causes those bit/byte swaps to 
> overlap.  Thus, disorder in the final output is highly effected by 
> initial starting conditions.  This means, in general, there is good 
> resistance against repetitive patterns even in substantially similar 
> plaintexts using the same salt, key and IV that could be used in a 
> practical break.  Whilst best practice would dictate unique keys, 
> salts and IVs for each encryption, the cipher is forgiving of mistakes 
> providing a window of safety for the user.  The absolute limit, is an 
> unknown quantity at this point but what is known is that confidence in 
> the absolute security of the ciphertexts would degrade with time if 
> keys, salts and IVs are reused.
>
> In large files, the situation is quite different.  As the encryption 
> process runs as an overlapping chain, repetition will not occur, 
> although a skewed fractal-like pattern may emerge as in the case of a 
> file filled with 0x00.  This will not, however, reveal the key, salt, 
> plaintext or IV as there are no absolute reference points from which 
> to begin analysis.  This is something that will change in the Beta 3 
> release, as it is a product of resetting the circular buffers to index 
> zero on each iteration (round).  In Beta 3, this will be random and 
> the order will vanish.
>
> Regards,
>
> Mark McCarron