-
-
Notifications
You must be signed in to change notification settings - Fork 489
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
Link within approval email does not work for oauth providers. #6934
Comments
I would like confirmation that |
I'm not sure if the following is a good email address for redirection as it loses any language specific information from the url and will revert back to the default language. http://localhost:8080/geonetwork?uuid=e3b63ab5-c277-4dd8-8cff-ee78555bd809 So I found another url that may work - I tried to go to and it redirected to Which then redirected to Geonetwork 3.12.x has the following code
It was implemented in the following PR #6139 I’m guessing that if we change this so that the redirect does not lose the language then it may work? Maybe something like this? (Not tested) We would need to do some testing. |
In 4, we also change link in email to have it consistent in all places in https://github.com/geonetwork/core-geonetwork/pull/6792/files pointing to the landing page ie. srv/api/records/uuid (but this is not the JS app). |
@fxprunayre http://localhost:8080/geonetwork/srv/api/records/e3b63ab5-c277-4dd8-8cff-ee78555bd809?language=eng But the viewer is not correct and buggy It seems to be using skin.xls for the display. And the footer does not seem to check if footer is enabled - we have it disabled but it still shows the footer. Are these bugs? |
Here indeed https://github.com/geonetwork/core-geonetwork/blob/main/web/src/main/webapp/xslt/skin/default/skin.xsl#L55-L63 this does not check session status and UI configuration. So something to improve. |
Is there anywheres in the code where we use xsl to parse the ui configuratrion settings? Or maybe it is possible to change it to use a js version like the search page? I'm not sure I understand why a nojs version is used? |
Check
It was done for SEO purpose for landing page mainly. |
Describe the bug
The link within the approver email does not work if using external authentication.
To Reproduce
Expected behavior
Expecting the link to work as intended.
Desktop (please complete the following information):
Additional context
The issue is that the redirect email tries to go to a url similar to the following
http://localhost:8080/geonetwork/srv/eng/catalog.search#/metadata/e3b63ab5-c277-4dd8-8cff-ee78555bd809
But as the user is not logged in the authentication will redirect the user to the oauth application (i.e. keycloak). The redirect will not contain the anchor "#/metadata/e3b63ab5-c277-4dd8-8cff-ee78555bd809" because the redirect is generated from the server and is not available - it is only available to the browser. The browser will detect that the redirect is to a different host so it will not include the anchor. So after the login the user goes to http://localhost:8080/geonetwork/srv/eng/catalog.search which is not the intended location.
Suggesting that the link get changed to the following
http://localhost:8080/geonetwork?uuid=e3b63ab5-c277-4dd8-8cff-ee78555bd809
Which should fix the issue.
Note that this issue may apply in other links applied to the catalogue - I'm not sure where all occurrences may be?
Also this issue is also affecting users bookmarking the urls to metadata records for the same issue. The only time the books marks wil work is when the user is already logged in.
The text was updated successfully, but these errors were encountered: