-1

  The service "hwi_oauth.security.oauth_utils" has a dependency on a non-existent service "hwi_oauth.resource_ownerma
  p.main".

This is the error i got after executing the below command. and now this error have been displayed for every single command via prompt

composer require hwi/oauth-bundle php-http/guzzle6-adapter php-http/httplug-bundle
Mr Zid
  • 111
  • 6

1 Answers1

1

Did you configure the bundle as described in the documentation? https://github.com/hwi/HWIOAuthBundle/blob/master/Resources/doc/3-configuring_the_security_layer.md#b-configure-the-oauth-firewall

You probably need to add the firewall configuration:

# app/config/security.yml
security:
    firewalls:
        secured_area:
            anonymous: ~
            oauth:
                resource_owners:
                    facebook:           "/login/check-facebook"
                    google:             "/login/check-google"
                    my_custom_provider: "/login/check-custom"
                    my_github:          "/login/check-github"
                login_path:        /login
                use_forward:       false
                failure_path:      /login

                oauth_user_provider:
                    service: my.oauth_aware.user_provider.service

    access_control:
        - { path: ^/login, roles: IS_AUTHENTICATED_ANONYMOUSLY }
Jeroen
  • 1,991
  • 2
  • 16
  • 32