AuthnCallback
.@Deprecated
public interface UserPasswordCallback
The interface for requesting authentication credentials from the user. Should the javahl bindings need the matching information, these methodes will be called.
This callback can also be used to provide the equivalent of the
--no-auth-cache
and --non-interactive
arguments accepted by the command-line client.
Modifier and Type | Field and Description |
---|---|
static int |
AcceptPermanently
Deprecated.
Accept the connection to the server forever.
|
static int |
AcceptTemporary
Deprecated.
Accept the connection to the server once.
|
static int |
Reject
Deprecated.
Reject the connection to the server.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
askQuestion(java.lang.String realm,
java.lang.String question,
boolean showAnswer)
Deprecated.
ask the user a question where she answers with a text.
|
java.lang.String |
askQuestion(java.lang.String realm,
java.lang.String question,
boolean showAnswer,
boolean maySave)
Deprecated.
Ask the user a question, and (usually) store the auth
credential caching preference specified by
maySave
(used by userAllowedSave() ). |
int |
askTrustSSLServer(java.lang.String info,
boolean allowPermanently)
Deprecated.
If there are problems with the certifcate of the SSL-server, this
callback will be used to deside if the connection will be used.
|
boolean |
askYesNo(java.lang.String realm,
java.lang.String question,
boolean yesIsDefault)
Deprecated.
ask the user a yes/no question
|
java.lang.String |
getPassword()
Deprecated.
retrieve the password entered during the prompt call
|
java.lang.String |
getUsername()
Deprecated.
retrieve the username entered during the prompt call
|
boolean |
prompt(java.lang.String realm,
java.lang.String username)
Deprecated.
Ask the user for username and password
The entered username/password is retrieved by the getUsername
getPasswort methods.
|
boolean |
prompt(java.lang.String realm,
java.lang.String username,
boolean maySave)
Deprecated.
Request a user name and password from the user, and (usually)
store the auth credential caching preference specified by
maySave (used by userAllowedSave() ). |
boolean |
userAllowedSave()
Deprecated.
|
@Native static final int Reject
@Native static final int AcceptTemporary
@Native static final int AcceptPermanently
int askTrustSSLServer(java.lang.String info, boolean allowPermanently)
info
- the probblems with the certificate.allowPermanently
- if AcceptPermantly is a legal answerboolean prompt(java.lang.String realm, java.lang.String username)
realm
- for which server realm this information is requested.username
- the default usernameboolean askYesNo(java.lang.String realm, java.lang.String question, boolean yesIsDefault)
realm
- for which server realm this information is
requested.question
- question to be askedyesIsDefault
- if yes should be the defaultjava.lang.String askQuestion(java.lang.String realm, java.lang.String question, boolean showAnswer)
realm
- for which server realm this information is
requested.question
- question to be askedshowAnswer
- if the answer is shown or hiddenjava.lang.String getUsername()
java.lang.String getPassword()
boolean prompt(java.lang.String realm, java.lang.String username, boolean maySave)
maySave
(used by userAllowedSave()
).
Applications wanting to emulate the behavior of
--non-interactive
will implement this method in a
manner which does not require user interaction (e.g. a no-op
which assumes pre-cached auth credentials).realm
- The realm from which the question originates.username
- The name of the user in realm
.maySave
- Whether caching of credentials is allowed.
Usually affects the return value of the userAllowedSave()
method.java.lang.String askQuestion(java.lang.String realm, java.lang.String question, boolean showAnswer, boolean maySave)
maySave
(used by userAllowedSave()
). Applications wanting to
emulate the behavior of --non-interactive
will
implement this method in a manner which does not require user
interaction (e.g. a no-op).realm
- The realm from which the question originates.question
- The text of the question.showAnswer
- Whether the answer may be displayed.maySave
- Whether caching of credentials is allowed.
Usually affects the return value of the userAllowedSave()
method.boolean userAllowedSave()
prompt(String, String, boolean)
was called.
Applications wanting to emulate the behavior of
--no-auth-cache
will probably always return
false
.