[ 
https://issues.apache.org/jira/browse/WICKET-6454?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Martin Grigorov resolved WICKET-6454.
-------------------------------------
       Resolution: Fixed
    Fix Version/s: 7.9.0

The fix won't be ported to 8.x because 2.3 is too old. Everyone should use 3.x 
these days.

> WicketApplication behind a proxy with restrictive internet access can not 
> initialized
> -------------------------------------------------------------------------------------
>
>                 Key: WICKET-6454
>                 URL: https://issues.apache.org/jira/browse/WICKET-6454
>             Project: Wicket
>          Issue Type: Improvement
>          Components: wicket
>    Affects Versions: 7.6.0
>         Environment: WicketApplication behind a proxy with restrictive 
> internet access
>            Reporter: Hans Schneider
>            Assignee: Martin Grigorov
>             Fix For: 7.9.0
>
>
> I have a Application with a Wicket frontend developed and on my developer 
> workstation with internet access starts the application successul. In a 
> production server with restricte internet access the application can not 
> start because the following exception.
> {code}
> ERROR org.apache.wicket.util.file.WebXmlFile getFilterPath  Error reading 
> servlet/filter path from web.xml 
> java.net.UnknownHostException: java.sun.com
>       at 
> java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:178) 
> ~[na:1.7.0_79]
>       at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172) 
> ~[na:1.7.0_79]
>       at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) 
> ~[na:1.7.0_79]
>       at java.net.Socket.connect(Socket.java:579) ~[na:1.7.0_79]
>       at java.net.Socket.connect(Socket.java:528) ~[na:1.7.0_79]
>       at sun.net.NetworkClient.doConnect(NetworkClient.java:180) ~[na:na]
>       at sun.net.www.http.HttpClient.openServer(HttpClient.java:432) ~[na:na]
>       at sun.net.www.http.HttpClient.openServer(HttpClient.java:527) ~[na:na]
>       at sun.net.www.http.HttpClient.<init>(HttpClient.java:211) ~[na:na]
>       at sun.net.www.http.HttpClient.New(HttpClient.java:308) ~[na:na]
>       at sun.net.www.http.HttpClient.New(HttpClient.java:326) ~[na:na]
>       at 
> sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:997)
>  ~[na:na]
>       at 
> sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:933)
>  ~[na:na]
>       at 
> sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:851)
>  ~[na:na]
>       at 
> sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1301)
>  ~[na:na]
>       at 
> org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(XMLEntityManager.java:986)
>  ~[na:na]
>       at 
> org.apache.xerces.impl.XMLEntityManager.startEntity(XMLEntityManager.java:897)
>  ~[na:na]
>       at 
> org.apache.xerces.impl.XMLEntityManager.startDTDEntity(XMLEntityManager.java:864)
>  ~[na:na]
>       at 
> org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(XMLDTDScannerImpl.java:241)
>  ~[na:na]
>       at 
> org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(XMLDocumentScannerImpl.java:1001)
>  ~[na:na]
>       at 
> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:324)
>  ~[na:na]
>       at 
> org.apache.xerces.parsers.XML11Configuration.parse(XML11Configuration.java:845)
>  ~[na:na]
>       at 
> org.apache.xerces.parsers.XML11Configuration.parse(XML11Configuration.java:768)
>  ~[na:na]
>       at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:108) 
> ~[na:na]
>       at org.apache.xerces.parsers.DOMParser.parse(DOMParser.java:230) 
> ~[na:na]
>       at 
> org.apache.xerces.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:285)
>  ~[na:na]
>       at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:121) 
> ~[na:1.7.0_79]
>       at 
> org.apache.wicket.util.file.WebXmlFile.getFilterPath(WebXmlFile.java:206) 
> [wicket-util-7.6.0.jar:7.6.0]
>       at 
> org.apache.wicket.util.file.WebXmlFile.getFilterPath(WebXmlFile.java:88) 
> [wicket-util-7.6.0.jar:7.6.0]
>       at 
> org.apache.wicket.util.file.WebXmlFile.getUniqueFilterPath(WebXmlFile.java:67)
>  [wicket-util-7.6.0.jar:7.6.0]
> {code}
> Would not it be a good idea if there was a possibility in the future to 
> disable the validation of the XML?
> I have found a link on how the improvement could be implemented in the Class 
> org.apache.wicket.util.file.WebXmlFile and Method
> {code}
> public final Set<String> getFilterPath(final boolean isServlet, final String 
> filterName,
>               final InputStream is) throws ParserConfigurationException, 
> SAXException, IOException
> {code}
> https://stackoverflow.com/questions/4002885/unknown-host-exception-while-parsing-an-xml-file



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to