org.mitre.jsip.util
Class DigestAuthentication
java.lang.Object
|
+--org.mitre.jsip.util.DigestAuthentication
- public class DigestAuthentication
- extends java.lang.Object
Constructor Summary |
DigestAuthentication(java.lang.String authRequest)
Create a new instance using the information passed from the server
in the WWW-Authenticate field |
Method Summary |
java.lang.String |
createAuthorizationHeader(java.lang.String username,
java.lang.String password,
java.lang.String method,
java.lang.String requestUrl)
Create a string to use in a Authorization header field |
static void |
main(java.lang.String[] args)
|
boolean |
passwordRequired()
See if a password authentication is required. |
void |
updateAuthRequest(java.lang.String authRequest)
If another WWW-Authenticate field is sent, update our information
using this new field |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DigestAuthentication
public DigestAuthentication(java.lang.String authRequest)
- Create a new instance using the information passed from the server
in the WWW-Authenticate field
updateAuthRequest
public void updateAuthRequest(java.lang.String authRequest)
- If another WWW-Authenticate field is sent, update our information
using this new field
passwordRequired
public boolean passwordRequired()
- See if a password authentication is required. This is normally the case if
the "stale" variable from the WWW-Authenticate field is false
createAuthorizationHeader
public java.lang.String createAuthorizationHeader(java.lang.String username,
java.lang.String password,
java.lang.String method,
java.lang.String requestUrl)
throws DigestAuthenticationException
- Create a string to use in a Authorization header field
main
public static void main(java.lang.String[] args)