Package com.sun.mail.smtp
Class DigestMD5
java.lang.Object
com.sun.mail.smtp.DigestMD5
DIGEST-MD5 authentication support.
- Author:
- Dean Gibson, Bill Shannon
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbyte[]Return client's authentication response to server's challenge.booleanauthServer(String serverResponse) Allow the client to authenticate the server based on its response.
-
Constructor Details
-
DigestMD5
-
-
Method Details
-
authClient
public byte[] authClient(String host, String user, String passwd, String realm, String serverChallenge) throws IOException Return client's authentication response to server's challenge.- Parameters:
host- the host nameuser- the user namepasswd- the user's passwordrealm- the security realmserverChallenge- the challenge from the server- Returns:
- byte array with client's response
- Throws:
IOException- for I/O errors
-
authServer
Allow the client to authenticate the server based on its response.- Parameters:
serverResponse- the response that was received from the server- Returns:
- true if server is authenticated
- Throws:
IOException- for character conversion failures
-