[JBoss JIRA] (WFLY-13768) JSF trying to load DTD over the network
by Farah Juma (Jira)
[ https://issues.redhat.com/browse/WFLY-13768?page=com.atlassian.jira.plugi... ]
Farah Juma updated WFLY-13768:
------------------------------
Security: (was: Red Hat Internal)
> JSF trying to load DTD over the network
> ---------------------------------------
>
> Key: WFLY-13768
> URL: https://issues.redhat.com/browse/WFLY-13768
> Project: WildFly
> Issue Type: Bug
> Components: JSF
> Reporter: Farah Juma
> Assignee: Moulali Shikalwadi
> Priority: Major
>
> JSF trying to load DTD over the network
> {code}
> - locked <0x00000000e7e3c560> (a sun.net.www.protocol.http.HttpURLConnection)
> at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(XMLEntityManager.java:1033)
> at org.apache.xerces.impl.XMLEntityManager.startEntity(XMLEntityManager.java:941)
> at org.apache.xerces.impl.XMLEntityManager.startDTDEntity(XMLEntityManager.java:908)
> at org.apache.xerces.impl.XMLDTDScannerImpl.setInputSource(XMLDTDScannerImpl.java:241)
> at org.apache.xerces.impl.XMLDocumentScannerImpl$DTDDispatcher.dispatch(XMLDocumentScannerImpl.java:1001)
> at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:324)
> at org.apache.xerces.parsers.XML11Configuration.parse(XML11Configuration.java:875)
> at org.apache.xerces.parsers.XML11Configuration.parse(XML11Configuration.java:798)
> at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:108)
> at org.apache.xerces.parsers.DOMParser.parse(DOMParser.java:230)
> at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:298)
> at org.apache.xpath.jaxp.XPathImpl.evaluate(XPathImpl.java:474)
> at org.apache.xpath.jaxp.XPathImpl.evaluate(XPathImpl.java:521)
> at com.sun.faces.util.Util.getWebXmlVersion(Util.java:1361)
> at com.sun.faces.el.ELUtils.tryAddCDIELResolver(ELUtils.java:311)
> at com.sun.faces.el.ELUtils.buildFacesResolver(ELUtils.java:242)
> at com.sun.faces.application.ApplicationAssociate.initializeELResolverChains(ApplicationAssociate.java:503)
> at com.sun.faces.application.ApplicationImpl.performOneTimeELInitialization(ApplicationImpl.java:1405)
> at com.sun.faces.application.ApplicationImpl.getELResolver(ApplicationImpl.java:529)
> at javax.faces.application.ApplicationWrapper.getELResolver(ApplicationWrapper.java:621)
> at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:256)
> {code}
> {code}
> /**
> * Get the web.xml version (if any).
> *
> * @param facesContext the Faces context.
> * @return the version found, or "" if none found.
> */
> public static String getWebXmlVersion(FacesContext facesContext) {
> String result = "";
> InputStream stream = null;
> try {
> URL url = facesContext.getExternalContext().getResource("/WEB-INF/web.xml");
> if (url != null) {
> XPathFactory factory = XPathFactory.newInstance();
> XPath xpath = factory.newXPath();
> xpath.setNamespaceContext(new JavaeeNamespaceContext());
> stream = url.openStream();
> result = xpath.evaluate("string(/javaee:web-app/@version)", new InputSource(stream));
> }
> } catch (MalformedURLException mue) {
> } catch (XPathExpressionException | IOException xpee) {
> } finally {
> if (stream != null) {
> try {
> stream.close();
> } catch (IOException ioe) {
> }
> }
> }
> return result;
> }
> {code}
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 11 months
[JBoss JIRA] (WFLY-13763) WS-Sec Regression with WFLY18+ following upgrade to SAAJ 1.4
by Andreas Weise (Jira)
[ https://issues.redhat.com/browse/WFLY-13763?page=com.atlassian.jira.plugi... ]
Andreas Weise commented on WFLY-13763:
--------------------------------------
I don't think [https://github.com/apache/santuario-java/blob/xmlsec-2.1.4/src/main/java/... be changed. Comparing instances is good there, and not the root cause. I simply tried to say, that the root cause is something else (in SAAJ), which creates new instances instead of passing references.
I have no good view over metro-saaj project, but [https://github.com/javaee/metro-saaj/commit/148757613467ee3c60ac8db364c80... quite large, is part of saaj-impl 1.4.x and so very likely related to this issue.
> WS-Sec Regression with WFLY18+ following upgrade to SAAJ 1.4
> ------------------------------------------------------------
>
> Key: WFLY-13763
> URL: https://issues.redhat.com/browse/WFLY-13763
> Project: WildFly
> Issue Type: Bug
> Components: Web Services
> Reporter: Brian Stansberry
> Assignee: Jim Ma
> Priority: Major
>
> This was reported by Andreas Weise at https://groups.google.com/g/wildfly/c/B4Gk4ljbrqE:
> After upgrading to WFY20 we are facing a regression regarding WS-Security that was introduced with Upgrade of com.sun.xml.messaging.saaj:saaj-impl in https://issues.redhat.com/browse/WFLY-12442 with WFLY18. When downgrading com.sun.xml.messaging.saaj:saaj-impl to 1.3.x the regression is fixed also in WFLY18+. We did not locate the root cause in saaj-impl 1.4+.
> The Bug was spotted within our signing algorithm used for our SOAP Web Services (which uses javax.xml.crypto.dsig Packages).
> The Bug can be reproduced easily via https://github.com/weand/wildfly-xml-sig-reproducer, which contains the most basic reproducer code of our scenario:
> Reproducer contains a Web Service implementation which uses XML Signature and more specifically the enveloped-signature transform algorithm (https://www.w3.org/TR/xmldsig-core1/#sec-EnvelopedSignature). This standard transform algorithm basically removes the whole Signature element from the digest calculation. And thats not stable since WFLY18 as the Signature element is not removed anymore! The repo also contains an arquillian test testing the SOAP webservice response using rest-assured.
> Run good scenario: Test on WFLY17
> 1) mvn clean install -Pwfly17
> 2) Test passes
> 3) see proper 'Pre-digested input' as DEBUG output of org.apache.jcp Logger (here I pretty formatted the XML):
> {code}
> 17:58:04,494 DEBUG [org.apache.jcp.xml.dsig.internal.DigesterOutputStream] (default task-1) Pre-digested input:
> 17:58:04,494 DEBUG [org.apache.jcp.xml.dsig.internal.DigesterOutputStream] (default task-1) <soap:Body xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" ID="Body">
> <ns1:echoResponse
> xmlns:ns1="http://reproducer.sig.xml.wildfly.weand.github.com/">
> <return>hello test</return>
> </ns1:echoResponse>
> </soap:Body>
> 17:58:04,495 DEBUG [org.apache.jcp.xml.dsig.internal.dom.DOMReference] (default task-1) Reference object uri = #Body
> 17:58:04,495 DEBUG [org.apache.jcp.xml.dsig.internal.dom.DOMReference] (default task-1) Reference digesting completed
> {code}
> Run failing scenario: Test on WFLY18+
> 1) mvn clean install (which defaults to 20.0.1.Final)
> 2) Test fails
> {code}
> [ERROR] testService(com.github.weand.wildfly.xml.sig.reproducer.test.XmlSignatureIT) Time elapsed: 0.874 s <<< FAILURE!
> java.lang.AssertionError:
> Expected: Expected text value '0FCBFaURtUN+0kxupRbO3pp93rPY+9d1bf7ffAw77lQ=' but was 'A+XljxuKgY2Va+YDk/Ho66i/+JQLeA9QoTH8kap7Zdk=' - comparing <DigestValue ...>0FCBFaURtUN+0kxupRbO3pp93rPY+9d1bf7ffAw77lQ=</DigestValue> at /Envelope[1]/Body[1]/Signature[1]/SignedInfo[1]/Reference[1]/DigestValue[1]/text()[1] to <DigestValue ...>A+XljxuKgY2Va+YDk/Ho66i/+JQLeA9QoTH8kap7Zdk=</DigestValue> at /Envelope[1]/Body[1]/Signature[1]/SignedInfo[1]/Reference[1]/DigestValue[1]/text()[1]:
> <DigestValue xmlns="http://www.w3.org/2000/09/xmldsig#">0FCBFaURtUN+0kxupRbO3pp93rPY+9d1bf7ffAw77lQ=</DigestValue>
> but: result was:
> <DigestValue xmlns="http://www.w3.org/2000/09/xmldsig#">A+XljxuKgY2Va+YDk/Ho66i/+JQLeA9QoTH8kap7Zdk=</DigestValue>
> at com.github.weand.wildfly.xml.sig.reproducer.test.XmlSignatureIT.testService(XmlSignatureIT.java:71)
> {code}
> 3) see invalid 'Pre-digested input' as DEBUG output of org.apache.jcp Logger:
> {code}
> 18:03:42,888 DEBUG [org.apache.jcp.xml.dsig.internal.DigesterOutputStream] (default task-1) Pre-digested input:
> 18:03:42,888 DEBUG [org.apache.jcp.xml.dsig.internal.DigesterOutputStream] (default task-1) <soap:Body xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" ID="Body">
> <ns1:echoResponse
> xmlns:ns1="http://reproducer.sig.xml.wildfly.weand.github.com/">
> <return>hello test</return>
> </ns1:echoResponse>
> <Signature
> xmlns="http://www.w3.org/2000/09/xmldsig#">
> <SignedInfo>
> <CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"></CanonicalizationMethod>
> <SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"></SignatureMethod>
> <Reference URI="#Body">
> <Transforms>
> <Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature"></Transform>
> </Transforms>
> <DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
> <DigestValue></DigestValue>
> </Reference>
> </SignedInfo>
> <SignatureValue></SignatureValue>
> </Signature>
> </soap:Body>
> 18:03:42,888 DEBUG [org.apache.jcp.xml.dsig.internal.dom.DOMReference] (default task-1) Reference object uri = #Body
> 18:03:42,888 DEBUG [org.apache.jcp.xml.dsig.internal.dom.DOMReference] (default task-1) Reference digesting completed
> {code}
> Again the digest with enveloped-signature transform algorithm works properly when downgrading saaj-impl to 1.3.x in WFLY18+.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 11 months
[JBoss JIRA] (DROOLS-5574) User can not work with project
by Jozef Marko (Jira)
[ https://issues.redhat.com/browse/DROOLS-5574?page=com.atlassian.jira.plug... ]
Jozef Marko reassigned DROOLS-5574:
-----------------------------------
Assignee: Eder Ignatowicz (was: David Gutierrez)
> User can not work with project
> ------------------------------
>
> Key: DROOLS-5574
> URL: https://issues.redhat.com/browse/DROOLS-5574
> Project: Drools
> Issue Type: Bug
> Components: Examples (Workbench)
> Affects Versions: 7.42.0.Final
> Reporter: Jozef Marko
> Assignee: Eder Ignatowicz
> Priority: Blocker
> Labels: Regression
> Attachments: Screenshot from 2020-08-12 15-57-43.png, error.log
>
>
> The issue is after user import sample project and tries to open an Asset, multiple errors appear in server log and the UI is not responsive.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 11 months
[JBoss JIRA] (DROOLS-5574) User can not work with project
by Jozef Marko (Jira)
Jozef Marko created DROOLS-5574:
-----------------------------------
Summary: User can not work with project
Key: DROOLS-5574
URL: https://issues.redhat.com/browse/DROOLS-5574
Project: Drools
Issue Type: Bug
Components: Examples (Workbench)
Affects Versions: 7.42.0.Final
Reporter: Jozef Marko
Assignee: David Gutierrez
Attachments: Screenshot from 2020-08-12 15-57-43.png, error.log
The issue is after user import sample project and tries to open an Asset, multiple errors appear in server log and the UI is not responsive.
--
This message was sent by Atlassian Jira
(v7.13.8#713008)
5 years, 11 months