Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Anonymous access if BasicAuth is enabled #54

Open
omazilov opened this issue Nov 13, 2017 · 2 comments
Open

Anonymous access if BasicAuth is enabled #54

omazilov opened this issue Nov 13, 2017 · 2 comments

Comments

@omazilov
Copy link

There are no possibility to use pact-broker with anonymous access if Basic Auth is enabled

@omazilov omazilov changed the title Anonymous access with if BA is enabled Anonymous access with if BasicAuth is enabled Nov 13, 2017
@omazilov omazilov changed the title Anonymous access with if BasicAuth is enabled Anonymous access if BasicAuth is enabled Nov 13, 2017
@bethesque
Copy link
Contributor

bethesque commented Nov 13, 2017

You'll need to build your own docker image. I would fork the dius repo, and the modify the pact_broker/basic_auth.rb file.

Change this method:

  def use_basic_auth?(env)
    !(env[PATH_INFO] =~ BADGE_PATH)
  end

to this:

  def use_basic_auth?(env)
    env['REQUEST_METHOD'] != 'GET'
  end

@bethesque
Copy link
Contributor

As mentioned on gitter, there is currently no support for user management. However, if you wish to give every user their own account, you should look up how to set up password authentication with nginx.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants