Re: [TLS] Twist security for brainpoolp256r1

Manuel Pégourié-Gonnard <> Thu, 13 November 2014 15:53 UTC

Return-Path: <>
Received: from localhost ( []) by (Postfix) with ESMTP id 1B09D1A8997 for <>; Thu, 13 Nov 2014 07:53:10 -0800 (PST)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: 0.397
X-Spam-Status: No, score=0.397 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HELO_MISMATCH_COM=0.553, HOST_EQ_NL=1.545, MIME_8BIT_HEADER=0.3, SPF_PASS=-0.001] autolearn=no
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id KWQXslyNWpfT for <>; Thu, 13 Nov 2014 07:53:09 -0800 (PST)
Received: from ( []) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 8FFBF1A8978 for <>; Thu, 13 Nov 2014 07:53:05 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;; s=exim; h=Subject:Content-Transfer-Encoding:Content-Type:In-Reply-To:References:CC:To:MIME-Version:From:Date:Message-ID; bh=JnUvn559hKAtuS5PqadzkM2LhWmp3IIH8aILSNz88FE=; b=ZtwZo60JwRDuNE7YTTsLdBQWF064NYebSeUTaLPoNRL5pU6w3itZvuaC6d4YLXT+0AYRivbMeHBSjqG8cOiSqy7e7diOXTXxD4j31EdcS7H1VyUGiEtuMFDK9ADN7vymHrdrsXum7Ndh+tVaplsbXsZ7xXWKNkW5lmYljqWje/A=;
Received: from ([] helo=[]) by with esmtpsa (TLS1.2:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from <>) id 1Xowhc-0008F5-C3; Thu, 13 Nov 2014 16:52:56 +0100
Message-ID: <>
Date: Thu, 13 Nov 2014 16:53:01 +0100
From: Manuel Pégourié-Gonnard <>
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0
MIME-Version: 1.0
To: Watson Ladd <>
References: <> <> <> <>
In-Reply-To: <>
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 8bit
X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000)
X-SA-Exim-Scanned: Yes (on
Cc: Oleg Gryb <>, "" <>
Subject: Re: [TLS] Twist security for brainpoolp256r1
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: "This is the mailing list for the Transport Layer Security working group of the IETF." <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Thu, 13 Nov 2014 15:53:10 -0000

On 13/11/2014 16:42, Watson Ladd wrote:
> On Thu, Nov 13, 2014 at 1:21 AM, Manuel Pégourié-Gonnard
> <> wrote:
>> On 13/11/2014 07:35, Oleg Gryb wrote:
>>> Thanks, very helpful. Just to summarize yours and Manuel's notes in regard of
>>> quadratic non-residue, or non-quadratic twists (as they are called in other
>>> emails), they can be used as a source of malicious EC points to run
>>> invalid-curve attacks on the original curves, but since all implementations
>>> compliant with X9* standards including openssl must have point-on-curve
>>> validation, invalid-curve attacks and small-group attacks become irrelevant
>>> when it comes to brainpoool's openssl implementation.
>> The situation is actually a bit more complex. Here is a version that's still a
>> bit simplified but closer to the truth: let's say there are two kinds of
>> protocols (or curve representations):
>> 1. Those who use both coordinates of the points.
>> 2. Those who use only the x coordinate.
> The coordinates used on the wire do not determine the calculations
> used by an implementation.

Sure. That's why I said that the above was still a bit simplified.

> An interoperable implementation of TLS
> could use the Brier-Joyce ladder on x-coordinates only, and take a
> randomly chosen square root for use as the y-coordinate, validating
> signatures through a different method. This would be of interest in
> certain side-channel attack scenarios, as the Brier-Joyce ladder is
> easier to protect.
I hope that an implementer who knows this somewhat exotic option and chooses to
use it for its side-channel properties is also sufficiently knowledgeable and
security concious to properly validate points...

> Most implementations don't do this, so the rest of your email is correct.
Thank you.