com.ibm.broker.config.appdev

Class APIConnectClient.FlexibleBasicAuthentication

  • java.lang.Object
    • org.eclipse.jetty.client.util.BasicAuthentication
      • com.ibm.broker.config.appdev.APIConnectClient.FlexibleBasicAuthentication
  • All Implemented Interfaces:
    org.eclipse.jetty.client.api.Authentication
    Enclosing class:
    APIConnectClient


    public class APIConnectClient.FlexibleBasicAuthentication
    extends org.eclipse.jetty.client.util.BasicAuthentication
    Overrides the BasicAuthentication class provided by the Jetty http client. The standard BasicAuthentication class provided by the Jetty client does not handle including a port number in the URL, and it also matches on a predefined Realm (which should be 'IBM-APIManagement' but we do not want to be broken if this changes, so we override the match method to be a bit more forgiving and pass everything else on to the real BasicAuthetication.
    • Nested Class Summary

      • Nested classes/interfaces inherited from interface org.eclipse.jetty.client.api.Authentication

        org.eclipse.jetty.client.api.Authentication.HeaderInfo, org.eclipse.jetty.client.api.Authentication.Result
    • Constructor Summary

      Constructors 
      Constructor and Description
      FlexibleBasicAuthentication(java.net.URI uri, java.lang.String realm, java.lang.String user, java.lang.String password) 
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      boolean matches(java.lang.String type, java.net.URI uri, java.lang.String realm) 
      • Methods inherited from class org.eclipse.jetty.client.util.BasicAuthentication

        authenticate
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FlexibleBasicAuthentication

        public FlexibleBasicAuthentication(java.net.URI uri,
                                           java.lang.String realm,
                                           java.lang.String user,
                                           java.lang.String password)
    • Method Detail

      • matches

        public boolean matches(java.lang.String type,
                               java.net.URI uri,
                               java.lang.String realm)
        Specified by:
        matches in interface org.eclipse.jetty.client.api.Authentication
        Overrides:
        matches in class org.eclipse.jetty.client.util.BasicAuthentication