conwetlab / ckanext-oauth2

OAuth2 support for CKAN
GNU Affero General Public License v3.0
25 stars 56 forks source link

redirected to http "/dashboard" (non "https") #58

Closed higuchi-toshio-intec closed 2 years ago

higuchi-toshio-intec commented 2 years ago

Very thanks for your project.

My execution environment is built with these versions.

I got a probrem with following steps.

  1. browse 'https://myckan.example.com/' , and "CKAN" is displayed
  2. click "Log in"
  3. wait a few minutes
  4. redirected "http://myckan.example.com/dashboard" and got error
    • Why "http"?
    • Why "/dashboard"?

And I got same result with this URL.

NOTE [Success] authenticate with cognito

I read source files and found. Why exists these steps? (about 79 line at "ckanext/oauth2/plugin.py")

    pages = ['/', '/user/logged_out_redirect']
    if came_from_url_parsed.path in pages:
        came_from_url = default_page

In other way Can't I set the "default_page" specified in an environment variable?

regards

aitormagan commented 2 years ago

Probably you are being redirected to the HTTP site because the value of site.url in your config is not set appropriately.

Regarding de /dashboard path, is the standard CKAN behaviour.

Regards Aitor Magán

El 3 ago 2022, a las 6:17, higuchi-toshio-intec @.***> escribió:

 Very thanks for your project.

My execution environment is built with these versions.

AWS Fargate CKAN [2.9.5] ckanext-oauth2 [0.7.0] Amazon ELB (for "https" front-end listener) Amazon Cognito I got a probrem with following steps.

browse 'https://myckan.example.com/' , and "CKAN" is displayed click "Log in" wait a few minutes redirected "http://myckan.example.com/dashboard" and got error Why "http"? Why "/dashboard"? And I got same result with this URL.

'https://myckan.example.com/user/logged_out_redirect' NOTE [Success] authenticate with cognito

'https://myckan.example.com/dataset/' 'https://myckan.example.com/organization/' 'https://myckan.example.com/group/' I read source files and found. Why exists these steps? (about 79 line at "ckanext/oauth2/plugin.py")

pages = ['/', '/user/logged_out_redirect']
if came_from_url_parsed.path in pages:
    came_from_url = default_page

In other way Can't I set the "default_page" specified in an environment variable?

regards

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you are subscribed to this thread.