Class AuthScope
java.lang.Object
edu.internet2.middleware.grouperClientExt.org.apache.commons.httpclient.auth.AuthScope
- Direct Known Subclasses:
HttpAuthRealm
The class represents an authentication scope consisting of a host name,
a port number, a realm name and an authentication scheme name which
Credentials
apply to.- Since:
- 3.0
-
Field Summary
Modifier and TypeFieldDescriptionstatic final AuthScope
Default scope matching any host, port, realm and authentication scheme.static final String
The null value represents any host.static final int
The -1 value represents any port.static final String
The null value represents any realm.static final String
The null value represents any authentication scheme. -
Constructor Summary
ConstructorDescriptionCreates a copy of the given credentials scope.Creates a new credentials scope for the given host, port, any realm name, and any authentication scheme.Creates a new credentials scope for the given host, port, realm, and any authentication scheme.Creates a new credentials scope for the given host, port, realm, and authentication scheme. -
Method Summary
-
Field Details
-
ANY_HOST
The null value represents any host. In the future versions of HttpClient the use of this parameter will be discontinued. -
ANY_PORT
public static final int ANY_PORTThe -1 value represents any port.- See Also:
-
ANY_REALM
The null value represents any realm. -
ANY_SCHEME
The null value represents any authentication scheme. -
ANY
Default scope matching any host, port, realm and authentication scheme. In the future versions of HttpClient the use of this parameter will be discontinued.
-
-
Constructor Details
-
AuthScope
Creates a new credentials scope for the given host, port, realm, and authentication scheme.- Parameters:
host
- the host the credentials apply to. May be set to null if credenticals are applicable to any host.port
- the port the credentials apply to. May be set to negative value if credenticals are applicable to any port.realm
- the realm the credentials apply to. May be set to null if credenticals are applicable to any realm.scheme
- the authentication scheme the credentials apply to. May be set to null if credenticals are applicable to any authentication scheme.- Since:
- 3.0
-
AuthScope
Creates a new credentials scope for the given host, port, realm, and any authentication scheme.- Parameters:
host
- the host the credentials apply to. May be set to null if credenticals are applicable to any host.port
- the port the credentials apply to. May be set to negative value if credenticals are applicable to any port.realm
- the realm the credentials apply to. May be set to null if credenticals are applicable to any realm.- Since:
- 3.0
-
AuthScope
Creates a new credentials scope for the given host, port, any realm name, and any authentication scheme.- Parameters:
host
- the host the credentials apply to. May be set to null if credenticals are applicable to any host.port
- the port the credentials apply to. May be set to negative value if credenticals are applicable to any port.- Since:
- 3.0
-
AuthScope
Creates a copy of the given credentials scope.- Since:
- 3.0
-
-
Method Details
-
getHost
- Returns:
- the host
- Since:
- 3.0
-
getPort
public int getPort()- Returns:
- the port
- Since:
- 3.0
-
getRealm
- Returns:
- the realm name
- Since:
- 3.0
-
getScheme
- Returns:
- the scheme type
- Since:
- 3.0
-
match
Tests if the authentication scopes match.- Returns:
- the match factor. Negative value signifies no match. Non-negative signifies a match. The greater the returned value the closer the match.
- Since:
- 3.0
-
equals
-
toString
-
hashCode
public int hashCode()
-