jamesnetherton commented on issue #9182:
URL: https://github.com/apache/camel-quarkus/issues/9182#issuecomment-5716922589

   I think it comes from the Camel 4.22.0 upgrade in Camel Quarkus 3.39.0.
   
   Camel now restricts the Saxon transformer's access to external resources by 
default. It's covered in the Camel 4.22 upgrade guide:
   
   
https://camel.apache.org/manual/camel-4x-upgrade-guide-4_22.html#_camel_xslt_saxon_secure_processing_now_applied_unconditionally
   
   So either use your custom `TransformerFactory` bean workaround. Or perhaps 
better, use `TransformerFactoryConfigurationStrategy`. That way Camel will 
still apply its own security config. 
   
   **TransformerFactoryConfigurationStrategy bean:**
   
   ```java
   @Produces
   @Singleton
   @Unremovable
   @Named("allowFileAccess")
   public TransformerFactoryConfigurationStrategy allowFileAccess() {
       return (factory, endpoint) -> 
factory.setAttribute(XMLConstants.ACCESS_EXTERNAL_STYLESHEET, "file");
   }
   ```
   
   **Route endpoint:**
   
   ```java
   
to("xslt-saxon:my.xsl?transformerFactoryConfigurationStrategy=#allowFileAccess")
   ```
   
   There is also a `secureProcessing=false` option but it does not lift all of 
the required restrictions.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to