Top Inners Fields Constructors Methods
com.sun.istack.tools

public Class DefaultAuthenticator

extends Authenticator
Class Inheritance
Imports
org.xml.sax.Locator, org.xml.sax.helpers.LocatorImpl, java.io.BufferedReader, .File, .FileInputStream, .FileNotFoundException, .IOException, .InputStreamReader, java.net.Authenticator, .MalformedURLException, .PasswordAuthentication, .URL, .URLDecoder, .URLEncoder, java.nio.charset.StandardCharsets, java.util.ArrayList, .List, java.util.logging.Level, .Logger, java.util.regex.Pattern

Authors
Vivek Pandey, Lukas Jungmann

Nested and Inner Type Summary

Modifier and TypeClass and Description
pack-priv static class
DefaultAuthenticator.AuthInfo

Represents authorization information needed by DefaultAuthenticator to authenticate access to remote resources.

private static class
public static interface

Field Summary

Modifier and TypeField and Description
private final List<DefaultAuthenticator.AuthInfo>
private static int
private static DefaultAuthenticator
private static final Logger
private String
private String
private static Authenticator

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public static synchronized DefaultAuthenticator
pack-priv static Authenticator
protected PasswordAuthentication
getPasswordAuthentication()

Overrides java.net.Authenticator.getPasswordAuthentication.

Called when password authorization is needed.

private DefaultAuthenticator.AuthInfo
public static synchronized void
public void
public void
setProxyAuth(String
Proxy authorization string
proxyAuth
)

Proxy authorization string in form of username:password.

Inherited from java.net.Authenticator:
getDefaultgetRequestingHostgetRequestingPortgetRequestingPromptgetRequestingProtocolgetRequestingSchemegetRequestingSitegetRequestingURLgetRequestorTyperequestPasswordAuthenticationrequestPasswordAuthenticationrequestPasswordAuthenticationrequestPasswordAuthenticationrequestPasswordAuthenticationInstancesetDefault

Field Detail

authInfoback to summary
private final List<DefaultAuthenticator.AuthInfo> authInfo
counterback to summary
private static int counter
instanceback to summary
private static DefaultAuthenticator instance
LOGGERback to summary
private static final Logger LOGGER
proxyPasswdback to summary
private String proxyPasswd
proxyUserback to summary
private String proxyUser
systemAuthenticatorback to summary
private static Authenticator systemAuthenticator

Constructor Detail

DefaultAuthenticatorback to summary
pack-priv DefaultAuthenticator()

Method Detail

getAuthenticatorback to summary
public static synchronized DefaultAuthenticator getAuthenticator()
getCurrentAuthenticatorback to summary
pack-priv static Authenticator getCurrentAuthenticator()
getPasswordAuthenticationback to summary
protected PasswordAuthentication getPasswordAuthentication()

Overrides java.net.Authenticator.getPasswordAuthentication.

Doc from java.net.Authenticator.getPasswordAuthentication.

Called when password authorization is needed. Subclasses should override the default implementation, which returns null.

Annotations
@Override
parseLineback to summary
private DefaultAuthenticator.AuthInfo parseLine(String text) throws Exception
resetback to summary
public static synchronized void reset()

Hides java.net.Authenticator.reset.

setAuthback to summary
public void setAuth(File f, DefaultAuthenticator.Receiver l)
setProxyAuthback to summary
public void setProxyAuth(String proxyAuth)

Proxy authorization string in form of username:password.

Parameters
proxyAuth:String

Proxy authorization string

com.sun.istack.tools back to summary

pack-priv final Class DefaultAuthenticator.AuthInfo

extends Object
Class Inheritance

Represents authorization information needed by DefaultAuthenticator to authenticate access to remote resources.
Authors
Vivek Pandey, Lukas Jungmann

Field Summary

Modifier and TypeField and Description
private final String
private final Pattern
private final String

Constructor Summary

AccessConstructor and Description
public
AuthInfo(URL url, String user, String password)

Method Summary

Modifier and TypeMethod and Description
public String
public String
public boolean
matchingHost(URL requestingURL)

Returns if the requesting host and port are associated with this AuthInfo

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

passwordback to summary
private final String password
urlPatternback to summary
private final Pattern urlPattern
userback to summary
private final String user

Constructor Detail

AuthInfoback to summary
public AuthInfo(URL url, String user, String password)

Method Detail

getPasswordback to summary
public String getPassword()
getUserback to summary
public String getUser()
matchingHostback to summary
public boolean matchingHost(URL requestingURL)

Returns if the requesting host and port are associated with this AuthInfo

com.sun.istack.tools back to summary

private Class DefaultAuthenticator.DefaultRImpl

extends Object
implements Receiver
Class Inheritance
All Implemented Interfaces
com.sun.istack.tools.DefaultAuthenticator.Receiver

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
private String
public void
public void
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

DefaultRImplback to summary
private DefaultRImpl()

Method Detail

getLocationStringback to summary
private String getLocationString(Locator l)
onErrorback to summary
public void onError(Exception e, Locator loc)

Implements com.sun.istack.tools.DefaultAuthenticator.Receiver.onError.

Annotations
@Override
onParsingErrorback to summary
public void onParsingError(String line, Locator loc)

Implements com.sun.istack.tools.DefaultAuthenticator.Receiver.onParsingError.

Annotations
@Override
com.sun.istack.tools back to summary

public Interface DefaultAuthenticator.Receiver

Known Direct Implementers
com.sun.istack.tools.DefaultAuthenticator.DefaultRImpl

Method Summary

Modifier and TypeMethod and Description
public void
public void

Method Detail

onErrorback to summary
public void onError(Exception e, Locator loc)
onParsingErrorback to summary
public void onParsingError(String line, Locator loc)