Re: Re: [COMMITTERS] pgsql: Add support for matching wildcard server certificates to the new

From: "Robert Haas" <robertmhaas(at)gmail(dot)com>
To: "Magnus Hagander" <magnus(at)hagander(dot)net>
Cc: "Peter Eisentraut" <peter_e(at)gmx(dot)net>, pgsql-hackers(at)postgresql(dot)org, "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: Re: [COMMITTERS] pgsql: Add support for matching wildcard server certificates to the new
Date: 2008-11-29 15:56:42
Message-ID: 603c8f070811290756n34fc6927m8883bfae7050a299@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

> Perhaps the best method would actually be to match only "*." at the
> beginning of the CN for now, and see if people complain? I would much
> like someone who knows more about what would be reasonable to speak up
> here, but it seems we don't have anybody here who knows...

I would encourage you to adopt a solution where * matches only a
single pathname component. This seems to be the intention of both
RFC2818 and RFC2595. It is also the behavior of IE7; FF2 seems to
deviate from the spec.

http://www.hanselman.com/blog/SomeTroubleWithWildcardSSLCertificatesFireFoxAndRFC2818.aspx

There are several other advantages of this approach that seem worth mentioning:

1. If you make it match a single pathname component now, and later
decide that you were wrong and change your mind, it is guaranteed not
to break any working installations. The reverse is not true.

2. I can't see any possible way that matching a single component could
create security holes that would be eliminated by matching multiple
components, but I'm more skeptical about the other direction. What
about the old DNS hack where you create a DNS record for
example.com.sample.com and hijack connections intended for example.com
made by people whose default DNS suffix is sample.com? There may be
reason to believe this isn't a problem, but matching less seems like
it can't possibly be a bad thing.

3. It would be truly bizarre if www*.example.com matched
www17.some.stuff.in.the.middle.example.com. (That having been said, I
wouldn't worry about wildcards intended to match part of a component
too much. I suspect that it's an extremely rare case, and we can
always add support later if there is demand for it. Not worrying
about this now will help keep the code simple and free of bugs, always
good in a security-critical context.)

...Robert

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message User Cunha17 2008-11-30 02:31:03 snapshot - src: Changed reference to the constant PG_DATETIME to
Previous Message Magnus Hagander 2008-11-29 13:49:35 Re: Re: [COMMITTERS] pgsql: Add support for matching wildcard server certificates to the new

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Treat 2008-11-29 17:37:26 Re: Statement-level triggers and inheritance
Previous Message Bruce Momjian 2008-11-29 15:42:05 Re: Updates of SE-PostgreSQL 8.4devel patches (r1197)