You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2018/03/20 16:17:11 UTC

syncope git commit: Solves some edge cases with JDK 7

Repository: syncope
Updated Branches:
  refs/heads/1_2_X 0301561b9 -> 3b9ef4107


Solves some edge cases with JDK 7


Project: http://git-wip-us.apache.org/repos/asf/syncope/repo
Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/3b9ef410
Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/3b9ef410
Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/3b9ef410

Branch: refs/heads/1_2_X
Commit: 3b9ef41079b8a6ccaa57485d02a43dc1c9f5de2a
Parents: 0301561
Author: Francesco Chicchiriccò <il...@apache.org>
Authored: Tue Mar 20 17:16:41 2018 +0100
Committer: Francesco Chicchiriccò <il...@apache.org>
Committed: Tue Mar 20 17:16:41 2018 +0100

----------------------------------------------------------------------
 .../apache/syncope/core/rest/controller/XSLTTransformer.java   | 6 ++++++
 1 file changed, 6 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/syncope/blob/3b9ef410/core/src/main/java/org/apache/syncope/core/rest/controller/XSLTTransformer.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/syncope/core/rest/controller/XSLTTransformer.java b/core/src/main/java/org/apache/syncope/core/rest/controller/XSLTTransformer.java
index d4ad75d..02f408d 100644
--- a/core/src/main/java/org/apache/syncope/core/rest/controller/XSLTTransformer.java
+++ b/core/src/main/java/org/apache/syncope/core/rest/controller/XSLTTransformer.java
@@ -191,6 +191,12 @@ public class XSLTTransformer extends AbstractSAXTransformer implements CachingPi
         } catch (TransformerConfigurationException e) {
             LOG.error("Could not enable secure XML processing", e);
         }
+        try {
+            transformerFactory.setAttribute(XMLConstants.ACCESS_EXTERNAL_DTD, "");
+        } catch (IllegalArgumentException e) {
+            LOG.error("Could not disable {}", XMLConstants.ACCESS_EXTERNAL_DTD, e);
+        }
+
         return transformerFactory;
     }