|
GigaSpaces XAP 9.7.2 API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.jini.core.constraint.ServerMinPrincipal
public final class ServerMinPrincipal
Represents a constraint on the server, such that if the server authenticates itself, then it must authenticate itself as at least all of the specified principals. The mechanisms and credentials used to authenticate the server as those principals are not specified by this constraint.
The use of an instance of this class does not imply directly a
ServerAuthentication.YES
constraint; that must be specified
separately to ensure that the server actually authenticates itself.
Because this constraint is conditional on server authentication, it does
not conflict with ServerAuthentication.NO
.
It is important to understand that specifying
ServerAuthentication.YES
as a requirement does not
ensure that a server is to be trusted; it does ensure that the
server authenticates itself as someone, but it does not ensure that the
server authenticates itself as anyone in particular. Without knowing who
the server authenticated itself as, there is no basis for actually
trusting the server. The client generally needs to specify a
ServerMinPrincipal
requirement in addition, or else verify
that the server has specified a satisfactory
ServerMinPrincipal
requirement for each of the methods that
the client cares about.
ServerAuthentication
,
AuthenticationPermission
,
Serialized FormConstructor Summary | |
---|---|
ServerMinPrincipal(Collection c)
Creates a constraint containing the specified principals, with duplicates removed. |
|
ServerMinPrincipal(Principal p)
Creates a constraint containing the specified principal. |
|
ServerMinPrincipal(Principal[] principals)
Creates a constraint containing the specified principals, with duplicates removed. |
Method Summary | |
---|---|
Set |
elements()
Returns an immutable set of all of the principals. |
boolean |
equals(Object obj)
Two instances of this class are equal if they have the same principals (ignoring order). |
int |
hashCode()
Returns a hash code value for this object. |
String |
toString()
Returns a string representation of this object. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ServerMinPrincipal(Principal p)
p
- the principal
NullPointerException
- if the argument is null
public ServerMinPrincipal(Principal[] principals)
principals
- the principals
NullPointerException
- if the argument is null
or
any element is null
IllegalArgumentException
- if the argument is emptypublic ServerMinPrincipal(Collection c)
c
- the principals
NullPointerException
- if the argument is null
or
any element is null
IllegalArgumentException
- if the argument is empty or the
elements do not all implement the Principal
interfaceMethod Detail |
---|
public Set elements()
UnsupportedOperationException
being
thrown.
public int hashCode()
hashCode
in class Object
public boolean equals(Object obj)
equals
in class Object
public String toString()
toString
in class Object
|
GigaSpaces XAP 9.7.2 API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |