omniauth-azure-activedirectory icon indicating copy to clipboard operation
omniauth-azure-activedirectory copied to clipboard

Fixed missing net/http

Open xdrr opened this issue 6 years ago • 5 comments

The Issue

The azure_activedirectory.rb strategy in this project does not include the net/http library but uses it heavily.

On Ubuntu 16+, Ruby 2.5, authentication attempts fail because of this missing requirement.

NameError (uninitialized constant Net):

omniauth-azure-activedirectory (1.0.0) lib/omniauth/strategies/azure_activedirectory.rb:169:in `fetch_openid_config'
omniauth-azure-activedirectory (1.0.0) lib/omniauth/strategies/azure_activedirectory.rb:190:in `openid_config'
omniauth-azure-activedirectory (1.0.0) lib/omniauth/strategies/azure_activedirectory.rb:105:in `authorize_endpoint_url'
omniauth-azure-activedirectory (1.0.0) lib/omniauth/strategies/azure_activedirectory.rb:79:in `request_phase'
omniauth (1.8.1) lib/omniauth/strategy.rb:224:in `request_call'
omniauth (1.8.1) lib/omniauth/strategy.rb:187:in `call!'
omniauth (1.8.1) lib/omniauth/strategy.rb:168:in `call'

The solution

I've simply included net/http in the Azure Active Directory strategy to resolve this.

I've tested authentication is working normally after this change.

xdrr avatar Oct 19 '18 06:10 xdrr

Maintainers: Can this please be merged? I will have to fork just to get this to work at all.

beautifulcode avatar May 17 '19 15:05 beautifulcode

Hello @aj-michael, @brandwe, @cchar could you please let us know whether this gem is abandoned or whether it is possible to at least merge this request?

I think there are more people interested in Azure AD integration with Ruby. Is there any other alternative or more modern solution for this topic? Thank you very much!

Laykou avatar Sep 05 '19 22:09 Laykou

Hi @laykou , I do not have ownership nor write permissions to this repository or the ruby gem.

Perhaps @brandwe or @RandalliLama can clarify future plans to maintain it.

aj-michael avatar Sep 05 '19 23:09 aj-michael

Hi! would appreciate an update on the status of this repo.

ktn00b avatar Oct 10 '19 15:10 ktn00b

I've also needed to fork and make updates to this repo, since my team needs omniauth with microsoft as a provider for a customer of ours, but this gem was out of date and had conflicts with other providers. If anybody would like to use my fork it's at https://github.com/davevanfleet/omniauth-activedirectory. I've also made a ruby gem available based on my fork. I'm happy to maintain the repo there (though I'm sure I'll need help at some point).

davevanfleet avatar Aug 02 '21 13:08 davevanfleet