Re: [TLS] Suspicious behaviour of TLS server implementations

Peter Gutmann <> Wed, 21 September 2016 15:53 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 07F6912B4FE for <>; Wed, 21 Sep 2016 08:53:43 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -6.516
X-Spam-Status: No, score=-6.516 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, RCVD_IN_DNSWL_MED=-2.3, RP_MATCHES_RCVD=-2.316] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (2048-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id V_oayubU28vg for <>; Wed, 21 Sep 2016 08:53:41 -0700 (PDT)
Received: from ( []) (using TLSv1.2 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 1C4A712B17C for <>; Wed, 21 Sep 2016 08:53:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple;;; q=dns/txt; s=mail; t=1474473221; x=1506009221; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=XmvNpM1tjYnvKX51+AEzDYwZxg1cNk0v2fD4reZurdM=; b=3uiqCXfg4tztAnQI5dEBL9SgeJwsZGqsMuZNuGrRJLNfw1R1GBACPN6t BJVX9LGZhAy6zkacEO7u/DWGAME4qA1vFdRo0+dPqv8ozi4kUNEVIpUtM gbF7HQmiyuTwvh8k9A+s8yayFWOT9vJfcCBxLi1rbA7vqyZ32hkoMahC8 kUN9Rnwl+c2CPEFObvUev/GHk3+zxk3Sn9ZW0o3t3MIDZU7vSizVbIvq/ cNCJ59S8JFvuC7uJ+/3XPJ7dePPd1a7ermeWouxYfse2gkf8xSgZBwhCJ +KaYonq6pJreIlGIBuLP94PmpwqLXBhmA4DdaJBwwXZeHjsYuYtxsTxIM g==;
X-IronPort-AV: E=Sophos;i="5.30,374,1470657600"; d="scan'208";a="106852287"
X-Ironport-Source: - Outgoing - Outgoing
Received: from (HELO ([]) by with ESMTP/TLS/AES256-SHA; 22 Sep 2016 03:53:34 +1200
Received: from ( by ( with Microsoft SMTP Server (TLS) id 15.0.1178.4; Thu, 22 Sep 2016 03:53:34 +1200
Received: from ([]) by ([]) with mapi id 15.00.1178.000; Thu, 22 Sep 2016 03:53:33 +1200
From: Peter Gutmann <>
To: Andreas Walz <>, "" <>
Thread-Topic: [TLS] Suspicious behaviour of TLS server implementations
Thread-Index: AQHSCqXVmMdwMkXxhEmPq8Svce2cg6Bwf1GAgAhiD77//1nRAIAKl8wAgAABIICAACcigIABLwcE
Date: Wed, 21 Sep 2016 15:53:33 +0000
Message-ID: <>
References: <> <> <> <> <> <>, <>
In-Reply-To: <>
Accept-Language: en-NZ, en-GB, en-US
Content-Language: en-NZ
x-ms-exchange-transport-fromentityheader: Hosted
x-originating-ip: []
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
MIME-Version: 1.0
Archived-At: <>
Cc: "" <>
Subject: Re: [TLS] Suspicious behaviour of TLS server implementations
X-Mailman-Version: 2.1.17
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: Wed, 21 Sep 2016 15:53:43 -0000

Andreas Walz <> writes:

>Actually, I wasn't aware of the fact that the TLS 1.3 draft now explicitly
>addresses this in the Presentation Language section:
>  "Peers which receive a message which cannot be parsed according to the
>  syntax (e.g., have a length extending beyond the message boundary or
>  contain an out-of-range length) MUST terminate the connection with a
>  "decoding_error" alert."

And how many implementations are going to do this?  Consider the error-message
litmus test I proposed earlier, reasons for failing to connect to (say)

  Error: Couldn't connect to Amazon because its certificate isn't valid.
  Error: Couldn't connect to Amazon because no suitable encryption was

  Error: Couldn't connect to Amazon because <explanation for 
         decoding_error alert>.

What would you put for the explanation for this case?  And if you say "decode
error" the user's response will be to switch to some less buggy software that
doesn't have problems connecting.

If you're writing a strict validating protocol parser than disconnecting in
this case is a valid response, but if it's software that will be used by
actual humans then failing a connect based on something like this makes no