Skip to Content.
Sympa Menu

mace-opensaml-users - RE: SAMLSubject.stronglyMatches

Subject: OpenSAML user discussion

List archive

RE: SAMLSubject.stronglyMatches


Chronological Thread 
  • From: "Scott Cantor" <>
  • To: "'Tom Scavo'" <>, "'OpenSAML'" <>
  • Subject: RE: SAMLSubject.stronglyMatches
  • Date: Fri, 13 Jan 2006 20:29:55 -0500
  • Organization: The Ohio State University

> SAMLSubject does not implement the notion of "strongly matches"
> (defined in SAMLCore) but one possible approach might be
>
> public boolean stronglyMatches(Object o);

Another might be:

public boolean stronglyMatches(SAMLSubject s1, SAMLSubject s2);

(It doesn't have to be part of the class.)

> How would you implement such a method without a corresponding equals
> method for SAMLNameIdentifier?

If there's a need for a matching method that has specific semantics, then
you can argue SAMLNameIdentifier should have one. I would argue that using
equals() for that is not only not necessary, but in fact a really horrible
idea. If everything I've said in this thread doesn't make that self-evident,
we're just talking past each other about the very notion of equality.

But you can also just define a function:

public boolean stronglyMatches(SAMLNameIdentifier n1, SAMLNameIdentifier
n2);

I don't see any particular reason why it would need intimate access to the
implementation classes, plus defining such a method on a particular class
won't help since it would take a matching parameter that it wouldn't
necessarily have that knowledge of.

> Same question for SAMLSubjectConfirmation?

I would say the same, but I can't make anything rational out of "strongly
matching" a schema that is open ended. It would be complex, at the very
least.

-- Scott




Archive powered by MHonArc 2.6.16.

Top of Page