org.apache.commons.httpclient.auth
Class AuthChallengeParser

java.lang.Object
  |
  +--org.apache.commons.httpclient.auth.AuthChallengeParser

public final class AuthChallengeParser
extends java.lang.Object

This class provides utility methods for parsing HTTP www and proxy authentication challenges.

Since:
2.0beta1
Author:
Oleg Kalnichevski

Constructor Summary
AuthChallengeParser()
           
 
Method Summary
static java.util.Map extractParams(java.lang.String challengeStr)
          Extracts a map of challenge parameters from an authentication challenge.
static java.lang.String extractScheme(java.lang.String challengeStr)
          Extracts authentication scheme from the given authentication challenge.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AuthChallengeParser

public AuthChallengeParser()
Method Detail

extractScheme

public static java.lang.String extractScheme(java.lang.String challengeStr)
                                      throws MalformedChallengeException
Extracts authentication scheme from the given authentication challenge.
Parameters:
challengeStr - the authentication challenge string
Returns:
authentication scheme
Throws:
MalformedChallengeException - when the authentication challenge string is malformed
Since:
2.0beta1

extractParams

public static java.util.Map extractParams(java.lang.String challengeStr)
                                   throws MalformedChallengeException
Extracts a map of challenge parameters from an authentication challenge. Keys in the map are lower-cased
Parameters:
challengeStr - the authentication challenge string
Returns:
a map of authentication challenge parameters
Throws:
MalformedChallengeException - when the authentication challenge string is malformed
Since:
2.0beta1


Copyright © 2001-2004 Apache Software Foundation. All Rights Reserved.