Modify

Opened 6 years ago

Last modified 8 months ago

#8207 new defect

download getting incorrect data gets exception

Reported by: richlv Owned by: team
Priority: normal Milestone:
Component: Core Version: tested
Keywords: template_report hotel wifi access point Cc:

Description

tried to download and got redirected to a crappy hotel login page

Repository Root: http://josm.openstreetmap.de/svn
Build-Date: 2012-11-10 02:31:13
Last Changed Author: bastiK
Revision: 5576
Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
URL: http://josm.openstreetmap.de/svn/trunk
Last Changed Date: 2012-11-09 21:16:38 +0100 (Fri, 09 Nov 2012)
Last Changed Rev: 5576

Identification: JOSM/1.5 (5576 en)
Memory Usage: 142 MB / 682 MB (20 MB allocated, but free)
Java version: 1.6.0_24, Sun Microsystems Inc., OpenJDK 64-Bit Server VM
Operating system: Linux
Dataset consistency test: No problems found

Plugin: PicLayer (28807)
Plugin: terracer (28807)

org.openstreetmap.josm.io.OsmTransferException: org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 6; The processing instruction target matching "[xX][mM][lL]" is not allowed.
	at org.openstreetmap.josm.io.BoundingBoxDownloader.parseRawGps(BoundingBoxDownloader.java:91)
	at org.openstreetmap.josm.actions.downloadtasks.DownloadGpsTask$DownloadTask.realRun(DownloadGpsTask.java:105)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:82)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:145)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
	at java.util.concurrent.FutureTask.run(FutureTask.java:166)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
	at java.lang.Thread.run(Thread.java:679)
Caused by: org.xml.sax.SAXParseException; lineNumber: 2; columnNumber: 6; The processing instruction target matching "[xX][mM][lL]" is not allowed.
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:198)
	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(ErrorHandlerWrapper.java:177)
	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:391)
	at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(XMLScanner.java:1404)
	at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanPIData(XMLScanner.java:691)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanPIData(XMLDocumentFragmentScannerImpl.java:997)
	at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanPI(XMLScanner.java:659)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:931)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:625)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:488)
	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:819)
	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:748)
	at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1208)
	at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:525)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:392)
	at org.openstreetmap.josm.io.GpxReader.parse(GpxReader.java:420)
	at org.openstreetmap.josm.io.BoundingBoxDownloader.downloadRawGps(BoundingBoxDownloader.java:45)
	at org.openstreetmap.josm.io.BoundingBoxDownloader.parseRawGps(BoundingBoxDownloader.java:79)
	... 9 more

Attachments (2)

josm_exception_download.txt (16.1 KB) - added by richlv 6 years ago.
tcpdump -w output when downloading
josm_exception_ctrl-h.txt (8.8 KB) - added by richlv 6 years ago.
tcpdump -w output when pressing ctrl-h

Download all attachments as: .zip

Change History (9)

comment:1 Changed 6 years ago by bastiK

Could you please describe the redirect process in as much detail as possible? I'm asking, because (as far as I know) there is no code that would cause JOSM to open a browser window at that point.

Is it reproducible? In that case a wireshark log would be very helpful.

Please save the JOSM file that caused this and note the URL you got redirected to.

Changed 6 years ago by richlv

Attachment: josm_exception_download.txt added

tcpdump -w output when downloading

Changed 6 years ago by richlv

Attachment: josm_exception_ctrl-h.txt added

tcpdump -w output when pressing ctrl-h

comment:2 Changed 6 years ago by richlv

this is easily reproducible in two cases :

  • press download button, dialog opens, click "download";
  • select an object, press ctrl-h (note that shift-ctrl-h does not produce and exception)

attached is tcpdump -w output in both cases

comment:3 Changed 6 years ago by bastiK

JOSM sends a GET request to http://api.openstreetmap.org, the server seemingly answers with 302 REDIRECT to http://wireless.hp.internal:8080/index.asp. JOSM follows the redirect and downloads some kind of wireless login page, which is not the OSM/GPX data it expects.

Please call

wget -SO output.txt http://api.openstreetmap.org/api/0.6/map?bbox=-105.1615114,39.9732381,-105.1580688,39.9748677

on the command line. If you get the same login page, then this is not a JOSM problem, but caused by your local setup (router, firewall) or the OSM server (unlikely).

comment:4 Changed 6 years ago by stoecker

This looks much like a login mechanism of mobile web access. You once need to open a browser, request any page and login before you can use the connection for other purposes.

comment:5 Changed 6 years ago by richlv

of course. exactly. but josm shouldn't throw an unexpected exception at me and ask me to report a bug ;)
it already knows it's not proper data, it should gracefully fail and tell me that (which it partially does upon download, btw)

comment:6 Changed 8 months ago by Don-vip

Ticket #6194 has been marked as a duplicate of this ticket.

comment:7 Changed 8 months ago by Don-vip

Keywords: hotel wifi access point added

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain team.
as The resolution will be set.
to The owner will be changed from team to the specified user.
The owner will change to richlv
as duplicate The resolution will be set to duplicate.The specified ticket will be cross-referenced with this ticket
The owner will be changed from team to anonymous.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.