Page 1 of 1

publishing data publicly auto login not working

PostPosted: Thu Jan 25, 2018 10:18 am
by vkumar
Hi all,

We are trying to set up public access or our omero instance so that we can make some data accessible using URL(publicly).

We followed this URL: https://docs.openmicroscopy.org/omero/5 ... ublic.html

However, when we open URL

http://omeros.ourhost.com/webgateway/img_detail/6/

This is redirecting to login page.

but, with a valid token auto login is working fine

http://omeros.ourhost.com/webgateway/im ... sessionkey

--------


The web version we are using is: 5.4.0

This is what we did:

1. Created group using omero ui "public-data" and setting permission "Read-only" to this group.

2. Create a user with username = publicuser and password = abcdefg.

3. Add publicuser to public-data group.

4. We also added data to this group.

5. Omero config settings:

[OMERO.server]$ bin/omero config get omero.web.public.enabled
True

[OMERO.server]$ bin/omero config get omero.web.public.user
publicuser

[OMERO.server]$ bin/omero config get omero.web.public.password
abcdefg

[OMERO.server]$ bin/omero config get omero.web.public.get_only
false

[OMERO.server]$ bin/omero config get omero.web.public.url_filter
^/(webadmin/myphoto/|webclient/(?!(script_ui|ome_tiff|figure_script))|webgateway/(?!(archived_files|download_as)))


Any help would be appreciated.Is there anything we are missing?

Re: publishing data publicly auto login not working

PostPosted: Thu Jan 25, 2018 6:15 pm
by jmoore
vkumar wrote:Hi all,


Hi Vinod,

...
However, when we open URL

http://omeros.ourhost.com/webgateway/img_detail/6/

...


[OMERO.server]$ bin/omero config get omero.web.public.url_filter
^/(webadmin/myphoto/|webclient/(?!(script_ui|ome_tiff|figure_script))|webgateway/(?!(archived_files|download_as)))


The configuration looks quite good, but just in case, here's our url_filter in case you want to try it:

Code: Select all
config set -- omero.web.public.url_filter '^\/(figure|webadmin\/myphoto\/|webclient\/(?!(script_ui|ome_tiff|figure_script|render_image_download|download_|ome_tiff_script|archived_files\/download|download_orig_metadata))|webgateway\/(?!(archived_files|download_as)))'


I'd also suggest leaving get_only as the default value unless you want the public user POST'ing to your server.
Code: Select all
# Revert to the default for get_only
bin/omero config set omero.web.public.get_only


Cheers,
~Josh.

Re: publishing data publicly auto login not working

PostPosted: Wed Feb 21, 2018 8:07 pm
by vkumar
Dear Josh,

Thank you for the reply and apologise for coming here late. I tried your suggestions and still, it's the same issue. Autologin doesn't work.

Just for the clarification, why do we need to set user and password in the config?

Am I misunderstanding that autologin here means user will have an URL (ex. http://omeros.ourhost.com/webgateway/img_detail/6/) once they will open the URL in their browser login page will not appear (system would check url segments and using filter in config system will do login in background using user and password in config file) and user will see image without login?

Also, once configs are set, do I have to restart the server or something else to make setting into effect?


Thanks

Re: publishing data publicly auto login not working

PostPosted: Wed Feb 21, 2018 8:43 pm
by jmoore
Hi Vinod,

vkumar wrote:Thank you for the reply and apologise for coming here late.


No worries.

I tried your suggestions and still, it's the same issue. Autologin doesn't work.


Sorry to hear that. Let's see if we can work on it below.

Just for the clarification, why do we need to set user and password in the config?


This web-only public user mechanism works by having an actual user whose password is not available for external use to perform the logins.

Am I misunderstanding that autologin here means user will have an URL (ex. http://omeros.ourhost.com/webgateway/img_detail/6/) once they will open the URL in their browser login page will not appear (system would check url segments and using filter in config system will do login in background using user and password in config file) and user will see image without login?


Correct.

Also, once configs are set, do I have to restart the server or something else to make setting into effect?


It depends to some extent how you deployed your server, and a restart is definitely necessary for config changes to take effect, so let's begin there. If you started your servers manually, then you'll need to use:

  • bin/omero admin restart
  • bin/omero web restart

If you set your servers up in systemd you'll need to use:

  • systemctl restart omero-server
  • systemctl restart omero-web

Cheers,
~Josh



Thanks[/quote]

Re: publishing data publicly auto login not working

PostPosted: Mon May 07, 2018 10:49 am
by derekeh
Hi,
Did you get this working in the end?
I have exactly the same problem.

Derek

Re: publishing data publicly auto login not working

PostPosted: Mon May 07, 2018 12:13 pm
by kennethgillen
Hi Derek,

It might be worth starting a new if that's possible? We can then work through with you what you're trying to achieve and suggest how best to go about it.

Thanks,

Kenny