groovyx.net.http
Class AuthConfig
java.lang.Object
groovyx.net.http.AuthConfig
public class AuthConfig
- extends Object
Encapsulates all configuration related to HTTP authentication methods.
- Author:
- Tom Nichols
- See Also:
HTTPBuilder.getAuth()
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
builder
protected HTTPBuilder builder
AuthConfig
public AuthConfig(HTTPBuilder builder)
basic
public void basic(String user,
String pass)
- Set authentication credentials to be used for the current
default host
. This method name is a bit of
a misnomer, since these credentials will actually work for "digest"
authentication as well.
- Parameters:
user
- pass
-
basic
public void basic(String host,
int port,
String user,
String pass)
- Set authentication credentials to be used for the given host and port.
- Parameters:
host
- port
- user
- pass
-
certificate
public void certificate(String certURL,
String password)
throws GeneralSecurityException,
MalformedURLException,
IOException
- Sets a certificate to be used for SSL authentication.
- Parameters:
certURL
- URL to a JKS keystore where the certificate is storedpassword
- password to decrypt the keystore
- Throws:
GeneralSecurityException
MalformedURLException
IOException
Copyright © 2008-2009. All Rights Reserved.