Problem with WMS service

Started by pykowiec, August 18, 2014, 01:40:29 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

pykowiec

There is a problem in adding Polish WMS service geoportal. The services works fine on other applications like Locus Maps.

I tried to add services described on the website http://geoportal.gov.pl/uslugi/usluga-przegladania-wms">http://geoportal.gov.pl/uslugi/usluga-przegladania-wms, but it fails



This site works well on locus

http://mapy.geoportal.gov.pl/wss/service/img/guest/ORTO_TIME/MapServer/WMSServer">http://mapy.geoportal.gov.pl/wss/servic ... /WMSServer">http://mapy.geoportal.gov.pl/wss/service/img/guest/ORTO_TIME/MapServer/WMSServer

http://mapy.geoportal.gov.pl/wss/service/pub/guest/kompozycjaG2_BDO_WMS/MapServer/WMSServer">http://mapy.geoportal.gov.pl/wss/servic ... /WMSServer">http://mapy.geoportal.gov.pl/wss/service/pub/guest/kompozycjaG2_BDO_WMS/MapServer/WMSServer



Any suggestions ?

orux

#1
Quote from: "pykowiec"There is a problem in adding Polish WMS service geoportal. The services works fine on other applications like Locus Maps.

I tried to add services described on the website http://geoportal.gov.pl/uslugi/usluga-przegladania-wms">http://geoportal.gov.pl/uslugi/usluga-przegladania-wms, but it fails



This site works well on locus

http://mapy.geoportal.gov.pl/wss/service/img/guest/ORTO_TIME/MapServer/WMSServer">http://mapy.geoportal.gov.pl/wss/servic ... /WMSServer">http://mapy.geoportal.gov.pl/wss/service/img/guest/ORTO_TIME/MapServer/WMSServer

http://mapy.geoportal.gov.pl/wss/service/pub/guest/kompozycjaG2_BDO_WMS/MapServer/WMSServer">http://mapy.geoportal.gov.pl/wss/servic ... /WMSServer">http://mapy.geoportal.gov.pl/wss/service/pub/guest/kompozycjaG2_BDO_WMS/MapServer/WMSServer



Any suggestions ?


Hi,



That server does not like the default user agent used by OruxMaps, returns a null file.



Solved for next version,



orux

pykowiec

#2
Thanks for the answer.

rydzejak

#3
Hi ORUX and PYKOWIEC !



I've contacted with Geoportal Admins and they said they can change filtering by user-agent by registering OruxMaps in their system.



The only thing they need is to know the exact value for "user-agent" used by OruxMaps application.

I don't know how to check it so please let me know what is this value and the problem will by solved for Geoportal without changes in Your app.



(another issue is to prevent vulnerability to such problem in other WMS portals)



rgds

Jakub

orux

#4
Quote from: "rydzejak"Hi ORUX and PYKOWIEC !



I've contacted with Geoportal Admins and they said they can change filtering by user-agent by registering OruxMaps in their system.



The only thing they need is to know the exact value for "user-agent" used by OruxMaps application.

I don't know how to check it so please let me know what is this value and the problem will by solved for Geoportal without changes in Your app.



(another issue is to prevent vulnerability to such problem in other WMS portals)



rgds

Jakub


Hello;



OruxMaps uses default android httpclient user agent in WMS (it depends on device and android version); but for next version it will be set to: OruxMaps v.x.xx.xx



where xx.xx.xx is current version, 5.5.22 for example.



orux

rydzejak

#5
Thanks Orux,

Here are recent news about Geoportal / WMS / user-agent.



First - I found the way to detect user-agent by myself (creating http server with max logging and redirecting oruxmaps to this server). Log shown user-agent as: "Apache-HttpClient/UNAVAILABLE (java 1.4)"  

Second - I passed this value to Geoportal  Admins and they declared to continue my issue (I hope it means changes in filtering rules an permission to access portal by oruxmaps).



You declare now to set individual user-agent for OruxMaps. This will very probably block access to portals with filtering (not only Geoportal but also those which accepted default "apache-httpclient"). I don't understand the idea of filtering by user-agent (which may be changed by developer) - and suspect that new value for user-agent will be allowed in those portals (soon or later). But this require user investigation and effort to argue with Admins (which is risky and user may give-up).



What I think about is to set a new parameter in configuration file to let user change default user-agent per portal. For example such spoofing ;-):

<wms>
<name>GeoPortal TOPO</name>
<uid>1002</uid>
<url><![CDATA[http://mapy.geoportal.gov.pl:80/wss/service/img/guest/TOPO/MapServer/WMSServer?]]></url>
<user-agent>Mozilla/5.0 (X11; Linux i686; rv:22.0) Gecko/20100101 Firefox/22.0</user-agent>
<minzoomlevel>14</minzoomlevel>
......
</wms>


Decision is of course Yours as You are the owner and developer and may want to distinguish the application in the net.



Anyhow, thanks very much for Your interest in the problem



rgds

Jakub

orux

#6
Quote from: "rydzejak"Thanks Orux,

Here are recent news about Geoportal / WMS / user-agent.



First - I found the way to detect user-agent by myself (creating http server with max logging and redirecting oruxmaps to this server). Log shown user-agent as: "Apache-HttpClient/UNAVAILABLE (java 1.4)"  

Second - I passed this value to Geoportal  Admins and they declared to continue my issue (I hope it means changes in filtering rules an permission to access portal by oruxmaps).



You declare now to set individual user-agent for OruxMaps. This will very probably block access to portals with filtering (not only Geoportal but also those which accepted default "apache-httpclient"). I don't understand the idea of filtering by user-agent (which may be changed by developer) - and suspect that new value for user-agent will be allowed in those portals (soon or later). But this require user investigation and effort to argue with Admins (which is risky and user may give-up).



What I think about is to set a new parameter in configuration file to let user change default user-agent per portal. For example such spoofing ;-):

<wms>
<name>GeoPortal TOPO</name>
<uid>1002</uid>
<url><![CDATA[http://mapy.geoportal.gov.pl:80/wss/service/img/guest/TOPO/MapServer/WMSServer?]]></url>
<user-agent>Mozilla/5.0 (X11; Linux i686; rv:22.0) Gecko/20100101 Firefox/22.0</user-agent>
<minzoomlevel>14</minzoomlevel>
......
</wms>


Decision is of course Yours as You are the owner and developer and may want to distinguish the application in the net.



Anyhow, thanks very much for Your interest in the problem



rgds

Jakub




Hi,



The policy should be to accept all user agent, except those that cause problems to the wms server.



There should not be problems with OruxMaps user agent.



Try with last beta-->http://www.oruxmaps.com/foro/viewtopic.php?f=4&t=2054">http://www.oruxmaps.com/foro/viewtopic.php?f=4&t=2054



I think that it is working fine with 'OruxMaps vxxxxx' user agent.



The wms_services.xml file is deprecated, I would rather people to use the built-in wms builder.





orux

rydzejak

#7
Quote from: "orux"
The policy should be to accept all user agent, except those that cause problems to the wms server.

Sounds logical to me, hope the same to portal Admistrators


Quote from: "orux"
There should not be problems with OruxMaps user agent.

Try with last beta-->http://www.oruxmaps.com/foro/viewtopic.php?f=4&t=2054">http://www.oruxmaps.com/foro/viewtopic.php?f=4&t=2054

I think that it is working fine with 'OruxMaps vxxxxx' user agent.

Confirmed. OruxMaps v. 5.5.23 beta 14 works with Geoportal WMS. THANKS !!!


Quote from: "orux"
The wms_services.xml file is deprecated, I would rather people to use the built-in wms builder.

Bad news :( Text file configuration is very convenient (for me) because of:

- easier typing and copying long URLs (prepare it on computer)

- sharing configuration with other devices (friends etc...)

- backup (I don't know how to protect my map definitions during upgrade)

 

1. When will You cut it off definitely ?

2. Will You depreciate onlinemapsources.xml also ?

3. Maybe there is a possibility to edit offline the configuration used by built-in wms builder ?



rgds

Jakub

goosiebn

#8
I agree, text file settings are a draw for me for Oruxmaps. More, not less, settings should be accessible this way.

orux

#9
Quote from: "rydzejak"
Quote from: "orux"
The policy should be to accept all user agent, except those that cause problems to the wms server.

Sounds logical to me, hope the same to portal Admistrators


Quote from: "orux"
There should not be problems with OruxMaps user agent.

Try with last beta-->http://www.oruxmaps.com/foro/viewtopic.php?f=4&t=2054">http://www.oruxmaps.com/foro/viewtopic.php?f=4&t=2054

I think that it is working fine with 'OruxMaps vxxxxx' user agent.

Confirmed. OruxMaps v. 5.5.23 beta 14 works with Geoportal WMS. THANKS !!!


Quote from: "orux"
The wms_services.xml file is deprecated, I would rather people to use the built-in wms builder.

Bad news :( Text file configuration is very convenient (for me) because of:

- easier typing and copying long URLs (prepare it on computer)

- sharing configuration with other devices (friends etc...)

- backup (I don't know how to protect my map definitions during upgrade)

 

1. When will You cut it off definitely ?

2. Will You depreciate onlinemapsources.xml also ?

3. Maybe there is a possibility to edit offline the configuration used by built-in wms builder ?



rgds

Jakub


Hi,



Do not worry, it will not disappear, but I will not develop further options in the file.



orux