TransWikia.com

How to disable Layer Preview in geoserver, which is available by default for public?

Geographic Information Systems Asked on June 28, 2021

I am using geoserver for publishing my spatial data. The problem I am facing is, Any public user can download my spatial data without my permission using default URL of geoserver. This is obviously undesirable in any context.

Please provide guidelines.

4 Answers

If you uncheck the Advertised box for the layer under the Publishing tab the layer will not show up in the Layer Preview. Would that be sufficient for your needs?

Correct answer by Ralph Dell on June 28, 2021

If you don't want people to download your data, use the security subsystem or disable the WFS services, the preview is just building links to standard OGC calls. But if you really just want to remove it, you can remove it for everybody (including the admin) by taking out the geoserver demo jar in geoserver/web-inf/lib

Answered by Andrea Aime on June 28, 2021

The best way is to hide all layers to unauthorized users.

You can do this, by changing the rules in the security section. The default settings, when starting a new GeoServer grants access to all the demo layers of all workspaces to all users. Just change this rules to restrict the access to the desired roles, users, workspaces or layers. All the layers for which the ROLE_ANONYMOUS is not selected are hidden in the Layer Preview.

Answered by geom on June 28, 2021

In Data Security change the line

*.*.r ________________    *

to

*.*.r ________________ GROUP_ADMIN, ADMIN

and the layers with Advertised box checked will show up in the Layer Preview but hidden for the public.

Answered by Zsolt Gál on June 28, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP