Search code examples
saxonoxygenxml

How to set FEATURE_SECURE_PROCESSING in Saxon's config or command line for Oxygen editor?


I couldn't find a way to enable FEATURE_SECURE_PROCESSING in Oxygen XML Developer or through Saxon's config file.

How can I enable it without writing Java code?


Solution

  • FEATURE_SECURE_PROCESSING is an XML parser feature rather than a Saxon feature per se.

    In 9.6 we've introduced a way to set XML parser features as if they were Saxon features using (in this case) the URI

    http://saxon.sf.net/feature/parserFeature?uri=http://javax.xml.XMLConstants/feature/secure-processing
    

    However, I don't think there is any way to set this from a configuration file or from oXygen without writing any Java code. The simplest way would be to write a little Initializer class that sets the property, and specify this Initializer in your oXygen scenario.