[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: encoding an X.509 certificate
Hi Ben,
Thanks for gently pushing back on my remarks. I was trying to distill
the essence of the profile, but I'm not sure I've adequately done
that. As I said earlier, I probably I have to provide more detail
before the issues clearly emerge. Please bear with me as I try to do
that below.
On Fri, Nov 7, 2008 at 3:19 AM, Ben Laurie <ben@xxxxxxxxx> wrote:
> Tom Scavo wrote:
>>
>> The SAML profile that makes use of the XML structure posted earlier
>> does not require that the certificate in question be validated by the
>> receiving party. The certificate is merely a container for a public
>> key, for which the client proves possession of the corresponding
>> private key, nothing more.
Sorry, the above is an overstatement on my part. Although it happens
to be true, it doesn't really have anything to do with my original
question regarding certificate encodings.
>> If the receiving party is a SAML identity provider, the presented
>> certificate is bound to a SAML assertion (using the XML structure
>> posted earlier). If the receiving party is a SAML service provider,
>> the presented certificate is compared to the certificate bound to the
>> SAML assertion. So the actual encoding applied to the certificate is
>> not important, except of course the identity provider and the service
>> provider need to be on the same page, otherwise certificate comparison
>> at the service provider will fail.
>
> If that's true, then your first paragraph is incorrect - all of the
> certificate matters.
Well, it depends on the content of the assertion. In the case of
<ds:X509Certificate>, yes, all of the certificate does matter, but
other kinds of X.509 data may be bound to the assertion, namely,
<ds:X509SKI>, <ds:X509SubjectName>, or <ds:X509IssuerSerial>. As it
turns out, it's these other elements that require additional
processing of the certificate by both parties.
See this short write-up that discusses each element in some detail:
http://docs.google.com/Doc?id=ddj3qnj2_231hms5vtgq
If a <ds:X509Certificate> element is bound to the assertion, it's
all-or-nothing, yes. On the other hand, if a <ds:X509SubjectName>
element is bound to the assertion, only the subject DN of the
certificate matters. Indeed, in that case the identity provider and
the service provider may be holding different certificates. Moreover,
in the case of <ds:X509SubjectName> we assume the service provider
trusts the issuer of the certificate in its possession. If not, the
subject DN should not be used by the service provider to confirm the
subject.
> However, if all you really care about is the public
> key, why does the receiving party not just check that and ignore the
> certificate?
Again, I misspoke (or spoke out of context) earlier. Now that I've
had a chance to explain myself, would you care to rephrase your
question?
Cheers,
Tom