Codota Logo
AuthenticatorUtils.computeDigestAuthentication
Code IndexAdd Codota to your IDE (free)

How to use
computeDigestAuthentication
method
in
org.asynchttpclient.util.AuthenticatorUtils

Best Java code snippets using org.asynchttpclient.util.AuthenticatorUtils.computeDigestAuthentication (Showing top 4 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Gson g =
  • Codota Iconnew Gson()
  • Codota IconGsonBuilder gsonBuilder;gsonBuilder.create()
  • Codota Iconnew GsonBuilder().create()
  • Smart code suggestions by Codota
}
origin: AsyncHttpClient/async-http-client

    .setMethodName(request.getMethod())
    .build();
authorizationHeader = computeDigestAuthentication(realm);
origin: AsyncHttpClient/async-http-client

public static String perRequestProxyAuthorizationHeader(Request request, Realm proxyRealm) {
 String proxyAuthorization = null;
 if (proxyRealm != null && proxyRealm.isUsePreemptiveAuth()) {
  switch (proxyRealm.getScheme()) {
   case BASIC:
    proxyAuthorization = computeBasicAuthentication(proxyRealm);
    break;
   case DIGEST:
    if (isNonEmpty(proxyRealm.getNonce())) {
     // update realm with request information
     proxyRealm = realm(proxyRealm)
         .setUri(request.getUri())
         .setMethodName(request.getMethod())
         .build();
     proxyAuthorization = computeDigestAuthentication(proxyRealm);
    }
    break;
   case NTLM:
   case KERBEROS:
   case SPNEGO:
    // NTLM, KERBEROS and SPNEGO are only set on the first request with a connection,
    // see perConnectionProxyAuthorizationHeader
    break;
   default:
    throw new IllegalStateException("Invalid Authentication scheme " + proxyRealm.getScheme());
  }
 }
 return proxyAuthorization;
}
origin: org.asynchttpclient/async-http-client-api

  public static String perRequestAuthorizationHeader(Request request, Realm realm) {

    String authorizationHeader = null;

    if (realm != null && realm.getUsePreemptiveAuth()) {

      switch (realm.getScheme()) {
      case BASIC:
        authorizationHeader = computeBasicAuthentication(realm);
        break;
      case DIGEST:
        if (isNonEmpty(realm.getNonce()))
          authorizationHeader = computeDigestAuthentication(realm);
        break;
      case NTLM:
      case KERBEROS:
      case SPNEGO:
        // NTLM, KERBEROS and SPNEGO are only set on the first request,
        // see firstRequestOnlyAuthorizationHeader
      case NONE:
        break;
      default:
        throw new IllegalStateException("Invalid Authentication " + realm);
      }
    }

    return authorizationHeader;
  }
}
origin: org.asynchttpclient/async-http-client-api

public static String perRequestProxyAuthorizationHeader(Request request, ProxyServer proxyServer, Realm realm, boolean connect) {
  String proxyAuthorization = null;
  if (!connect && proxyServer != null && proxyServer.getScheme() == AuthScheme.BASIC) {
    proxyAuthorization = computeBasicAuthentication(proxyServer);
  } else if (realm != null && realm.getUsePreemptiveAuth() && realm.isTargetProxy()) {
    switch (realm.getScheme()) {
    case BASIC:
      proxyAuthorization = computeBasicAuthentication(realm);
      break;
    case DIGEST:
      if (isNonEmpty(realm.getNonce()))
        proxyAuthorization = computeDigestAuthentication(realm);
      break;
    case NTLM:
    case KERBEROS:
    case SPNEGO:
      // NTLM, KERBEROS and SPNEGO are only set on the first request,
      // see firstRequestOnlyAuthorizationHeader
    case NONE:
      break;
    default:
      throw new IllegalStateException("Invalid Authentication " + realm);
    }
  }
  return proxyAuthorization;
}
org.asynchttpclient.utilAuthenticatorUtilscomputeDigestAuthentication

Popular methods of AuthenticatorUtils

  • perConnectionAuthorizationHeader
  • perConnectionProxyAuthorizationHeader
  • perRequestAuthorizationHeader
  • perRequestProxyAuthorizationHeader
  • append
  • computeBasicAuthentication
  • computeRealmURI
  • getHeaderWithPrefix
  • getProxyAuthorizationHeader

Popular in Java

  • Running tasks concurrently on multiple threads
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • scheduleAtFixedRate (Timer)
    Schedules the specified task for repeated fixed-rate execution, beginning after the specified delay.
  • runOnUiThread (Activity)
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • FileWriter (java.io)
    Convenience class for writing character files. The constructors of this class assume that the defaul
  • PrintWriter (java.io)
    Prints formatted representations of objects to a text-output stream. This class implements all of th
  • SortedMap (java.util)
    A map that has its keys ordered. The sorting is according to either the natural ordering of its keys
  • JPanel (javax.swing)
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now