Uploaded image for project: 'JBoss BPMS Platform'
  1. JBoss BPMS Platform
  2. RHBPMS-193

Unable to access Workbench Maven repository with Basic Authentication enabled

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Blocker Blocker
    • 6.1.0
    • 6.1.0
    • Business Central
    • None

      Description of problem:

      The Workbench's Maven Repository is a protected resource meaning it needs (Basic Authentication) User credentials supplied in HTTP requests. It is impossible to use Drools Engine's UrlResource to add KJARs from the Workbench's Maven repository due to flawed implementation of Basic Authentication HTTP headers in the UrlResource class.

      Version-Release number of selected component (if applicable):

      6.1.x (Product), 6.2.x (Community)

      How reproducible:

      Always

      Steps to Reproduce:

      Try to access the Workbench Maven Repository with something like this:

      KieServices ks = KieServices.Factory.get();
      KieRepository kr = ks.getRepository();
      UrlResource urlResource = (UrlResource) ks.getResources().newUrlResource("http://business-central/maven2/<path-to-JAR>.jar");
      urlResource.setUsername("username");
      urlResource.setPassword("password");
      urlResource.setBasicAuthentication("enabled");

      InputStream is = urlResource.getInputStream();
      KieModule kModule = kr.addKieModule( ks.getResources().newInputStreamResource(is) );

      Actual results:

      HTTP401/HTTP403 (see comments)

      Expected results:

      HTTP200

              manstis@redhat.com Michael Anstis
              manstis@redhat.com Michael Anstis
              Marek Baluch Marek Baluch
              Marek Baluch Marek Baluch
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: