cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: [PATCH] TLS hostname check conforming to RFC 6125

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Sun, 1 Apr 2012 15:29:33 +0200 (CEST)

On Sun, 1 Apr 2012, Tatsuhiro Tsujikawa wrote:

> This patch replaces RFC 2818 based hostname check in OpenSSL build with RFC
> 6125 [1] based one.

Thanks a lot! A little nit though: strcasecmp() cannot be used. It is A) not
portable enough and B) not good enough.

A - due to things like Windows
B - due to things like POSIX and Turkish:
     http://daniel.haxx.se/blog/2008/10/15/strcasecmp-in-turkish/

Curl_raw_equal() is the libcurl internal replacement for strcasecmp() but it
has a slightly different return code. Can you update your patch to use this,
please?

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2012-04-01