Re: Fwd: TLS/SSH bugs

Frederik Kriewitz <[email protected]> Tue, 9 Dec 2014 11:55:38 +0100
Newsgroups gmane.comp.encryption.cryptlib
Message-ID <CAKCUjRVp-FL3uoEHkWuc7c5x30-jtmon8YuGTBFdQNcjqWdv+w@mail.gmail.com>
On Sun, Dec 7, 2014 at 5:53 AM, Peter Gutmann <[email protected]> wrote:
> I wrote:
>>Frederik Kriewitz <[email protected]> writes:
>>>There seems to be a problem with TLS ClientHello extension handling (breaking
>>>compatibility with Chrome and Firefox without SSLv3 support):
>>>http://forums.apc.com/message/65421#65421
>>
>>That's a somewhat long discussion, I'll have to look at that in more detail.
>
> Do you have any more details on this?  I've just run up a cryptlib TLS 1.1
> server and connected to it with Firefox 34.0 (the post also mentions that
> Firefox has problems) and it connects fine.  cryptlib warns about Firefox
> downgrading from TLS 1.1 to 1.0 which I'll look into, but there don't seem to
> be any problems with extensions.



I looked at the code a little bit and found at least one problematic
part in readExtensions():

if( length < UINT16_SIZE + UINT16_SIZE + UINT16_SIZE + minPayloadLength )
        {
        retExt( CRYPT_ERROR_BADDATA,
                ( CRYPT_ERROR_BADDATA, SESSION_ERRINFO,
                  "TLS hello contains %d bytes extraneous data", length ) );
        }

This will kill the connection if there's no extension at all. Length
will be 2 in this case (just the Extension Length Header (0x0000)).
It will also fail if the first extension doesn't have any payload as
minPayloadLength defaults to 1 (There's already an exception in the
code for the server name extension)

That explains some of the issues but not all of them.
Can you share your example/reference TLS server implementation so I
can actually run some real test against the lib?

I tried to find out which version of cryptlib is actually running on
the APC devices as it might already have been fixed in the latest
version.
I expected the SSH server to include the version in the identification
string but it doesn't (it's only "cryptlib"). You might want to fix
that to to make the lib a little bit more RFC compliant (ident string
must contain the version).

Best Regards,
Freddy

_______________________________________________
Cryptlib mailing list
[email protected] via Mail: [email protected]
Archive: ftp://ftp.franken.de/pub/crypt/cryptlib/archives/
http://news.gmane.org/gmane.comp.encryption.cryptlib
Posts from non-subscribed addresses are blocked to prevent spam, please
subscribe in order to post messages.