camel-xmlsecurity-verify-kafka-connector sink configuration

When using camel-xmlsecurity-verify-kafka-connector as sink make sure to use the following Maven dependency to have support for the connector:

<dependency>
  <groupId>org.apache.camel.kafkaconnector</groupId>
  <artifactId>camel-xmlsecurity-verify-kafka-connector</artifactId>
  <version>x.x.x</version>
  <!-- use the same version as your Camel Kafka connector version -->
</dependency>

To use this Sink connector in Kafka connect you’ll need to set the following connector.class

connector.class=org.apache.camel.kafkaconnector.xmlsecurityverify.CamelXmlsecurityverifySinkConnector

The camel-xmlsecurity-verify sink connector supports 39 options, which are listed below.

Name Description Default Priority

camel.sink.path.name

The name part in the URI can be chosen by the user to distinguish between different verify endpoints within the camel context.

null

HIGH

camel.sink.endpoint.baseUri

You can set a base URI which is used in the URI dereferencing. Relative URIs are then concatenated with the base URI.

null

MEDIUM

camel.sink.endpoint.clearHeaders

Determines if the XML signature specific headers be cleared after signing and verification. Defaults to true.

"true"

MEDIUM

camel.sink.endpoint.cryptoContextProperties

Sets the crypto context properties. See {link XMLCryptoContext#setProperty(String, Object)}. Possible properties are defined in XMLSignContext an XMLValidateContext (see Supported Properties). The following properties are set by default to the value Boolean#TRUE for the XML validation. If you want to switch these features off you must set the property value to Boolean#FALSE. org.jcp.xml.dsig.validateManifests javax.xml.crypto.dsig.cacheReference

null

MEDIUM

camel.sink.endpoint.disallowDoctypeDecl

Disallows that the incoming XML document contains DTD DOCTYPE declaration. The default value is Boolean#TRUE.

"true"

MEDIUM

camel.sink.endpoint.keySelector

Provides the key for validating the XML signature.

null

MEDIUM

camel.sink.endpoint.lazyStartProducer

Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel’s routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing.

false

MEDIUM

camel.sink.endpoint.omitXmlDeclaration

Indicator whether the XML declaration in the outgoing message body should be omitted. Default value is false. Can be overwritten by the header XmlSignatureConstants#HEADER_OMIT_XML_DECLARATION.

"false"

MEDIUM

camel.sink.endpoint.outputNodeSearch

Sets the output node search value for determining the node from the XML signature document which shall be set to the output message body. The class of the value depends on the type of the output node search. The output node search is forwarded to XmlSignature2Message.

null

MEDIUM

camel.sink.endpoint.outputNodeSearchType

Determines the search type for determining the output node which is serialized into the output message bodyF. See setOutputNodeSearch(Object). The supported default search types you can find in DefaultXmlSignature2Message.

"Default"

MEDIUM

camel.sink.endpoint.outputXmlEncoding

The character encoding of the resulting signed XML document. If null then the encoding of the original XML document is used.

null

MEDIUM

camel.sink.endpoint.removeSignatureElements

Indicator whether the XML signature elements (elements with local name Signature and namesapce http://www.w3.org/2000/09/xmldsig#) shall be removed from the document set to the output message. Normally, this is only necessary, if the XML signature is enveloped. The default value is Boolean#FALSE. This parameter is forwarded to XmlSignature2Message. This indicator has no effect if the output node search is of type DefaultXmlSignature2Message#OUTPUT_NODE_SEARCH_TYPE_DEFAULT.F

"false"

MEDIUM

camel.sink.endpoint.schemaResourceUri

Classpath to the XML Schema. Must be specified in the detached XML Signature case for determining the ID attributes, might be set in the enveloped and enveloping case. If set, then the XML document is validated with the specified XML schema. The schema resource URI can be overwritten by the header XmlSignatureConstants#HEADER_SCHEMA_RESOURCE_URI.

null

MEDIUM

camel.sink.endpoint.secureValidation

Enables secure validation. If true then secure validation is enabled.

"true"

MEDIUM

camel.sink.endpoint.validationFailedHandler

Handles the different validation failed situations. The default implementation throws specific exceptions for the different situations (All exceptions have the package name org.apache.camel.component.xmlsecurity.api and are a sub-class of XmlSignatureInvalidException. If the signature value validation fails, a XmlSignatureInvalidValueException is thrown. If a reference validation fails, a XmlSignatureInvalidContentHashException is thrown. For more detailed information, see the JavaDoc.

null

MEDIUM

camel.sink.endpoint.xmlSignature2Message

Bean which maps the XML signature to the output-message after the validation. How this mapping should be done can be configured by the options outputNodeSearchType, outputNodeSearch, and removeSignatureElements. The default implementation offers three possibilities which are related to the three output node search types Default, ElementName, and XPath. The default implementation determines a node which is then serialized and set to the body of the output message If the search type is ElementName then the output node (which must be in this case an element) is determined by the local name and namespace defined in the search value (see option outputNodeSearch). If the search type is XPath then the output node is determined by the XPath specified in the search value (in this case the output node can be of type Element, TextNode or Document). If the output node search type is Default then the following rules apply: In the enveloped XML signature case (there is a reference with URI= and transform http://www.w3.org/2000/09/xmldsig#enveloped-signature), the incoming XML document without the Signature element is set to the output message body. In the non-enveloped XML signature case, the message body is determined from a referenced Object; this is explained in more detail in chapter Output Node Determination in Enveloping XML Signature Case.

null

MEDIUM

camel.sink.endpoint.xmlSignatureChecker

This interface allows the application to check the XML signature before the validation is executed. This step is recommended in http://www.w3.org/TR/xmldsig-bestpractices/#check-what-is-signed

null

MEDIUM

camel.sink.endpoint.basicPropertyBinding

Whether the endpoint should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities

false

MEDIUM

camel.sink.endpoint.synchronous

Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported).

false

MEDIUM

camel.sink.endpoint.uriDereferencer

If you want to restrict the remote access via reference URIs, you can set an own dereferencer. Optional parameter. If not set the provider default dereferencer is used which can resolve URI fragments, HTTP, file and XPpointer URIs. Attention: The implementation is provider dependent!

null

MEDIUM

camel.component.xmlsecurity-verify.baseUri

You can set a base URI which is used in the URI dereferencing. Relative URIs are then concatenated with the base URI.

null

MEDIUM

camel.component.xmlsecurity-verify.clearHeaders

Determines if the XML signature specific headers be cleared after signing and verification. Defaults to true.

"true"

MEDIUM

camel.component.xmlsecurity-verify.cryptoContext Properties

Sets the crypto context properties. See {link XMLCryptoContext#setProperty(String, Object)}. Possible properties are defined in XMLSignContext an XMLValidateContext (see Supported Properties). The following properties are set by default to the value Boolean#TRUE for the XML validation. If you want to switch these features off you must set the property value to Boolean#FALSE. org.jcp.xml.dsig.validateManifests javax.xml.crypto.dsig.cacheReference

null

MEDIUM

camel.component.xmlsecurity-verify.disallowDoctype Decl

Disallows that the incoming XML document contains DTD DOCTYPE declaration. The default value is Boolean#TRUE.

"true"

MEDIUM

camel.component.xmlsecurity-verify.keySelector

Provides the key for validating the XML signature.

null

MEDIUM

camel.component.xmlsecurity-verify.lazyStart Producer

Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel’s routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing.

false

MEDIUM

camel.component.xmlsecurity-verify.omitXml Declaration

Indicator whether the XML declaration in the outgoing message body should be omitted. Default value is false. Can be overwritten by the header XmlSignatureConstants#HEADER_OMIT_XML_DECLARATION.

"false"

MEDIUM

camel.component.xmlsecurity-verify.outputNode Search

Sets the output node search value for determining the node from the XML signature document which shall be set to the output message body. The class of the value depends on the type of the output node search. The output node search is forwarded to XmlSignature2Message.

null

MEDIUM

camel.component.xmlsecurity-verify.outputNode SearchType

Determines the search type for determining the output node which is serialized into the output message bodyF. See setOutputNodeSearch(Object). The supported default search types you can find in DefaultXmlSignature2Message.

"Default"

MEDIUM

camel.component.xmlsecurity-verify.outputXml Encoding

The character encoding of the resulting signed XML document. If null then the encoding of the original XML document is used.

null

MEDIUM

camel.component.xmlsecurity-verify.removeSignature Elements

Indicator whether the XML signature elements (elements with local name Signature and namesapce http://www.w3.org/2000/09/xmldsig#) shall be removed from the document set to the output message. Normally, this is only necessary, if the XML signature is enveloped. The default value is Boolean#FALSE. This parameter is forwarded to XmlSignature2Message. This indicator has no effect if the output node search is of type DefaultXmlSignature2Message#OUTPUT_NODE_SEARCH_TYPE_DEFAULT.F

"false"

MEDIUM

camel.component.xmlsecurity-verify.schemaResource Uri

Classpath to the XML Schema. Must be specified in the detached XML Signature case for determining the ID attributes, might be set in the enveloped and enveloping case. If set, then the XML document is validated with the specified XML schema. The schema resource URI can be overwritten by the header XmlSignatureConstants#HEADER_SCHEMA_RESOURCE_URI.

null

MEDIUM

camel.component.xmlsecurity-verify.secure Validation

Enables secure validation. If true then secure validation is enabled.

"true"

MEDIUM

camel.component.xmlsecurity-verify.validation FailedHandler

Handles the different validation failed situations. The default implementation throws specific exceptions for the different situations (All exceptions have the package name org.apache.camel.component.xmlsecurity.api and are a sub-class of XmlSignatureInvalidException. If the signature value validation fails, a XmlSignatureInvalidValueException is thrown. If a reference validation fails, a XmlSignatureInvalidContentHashException is thrown. For more detailed information, see the JavaDoc.

null

MEDIUM

camel.component.xmlsecurity-verify.xmlSignature2 Message

Bean which maps the XML signature to the output-message after the validation. How this mapping should be done can be configured by the options outputNodeSearchType, outputNodeSearch, and removeSignatureElements. The default implementation offers three possibilities which are related to the three output node search types Default, ElementName, and XPath. The default implementation determines a node which is then serialized and set to the body of the output message If the search type is ElementName then the output node (which must be in this case an element) is determined by the local name and namespace defined in the search value (see option outputNodeSearch). If the search type is XPath then the output node is determined by the XPath specified in the search value (in this case the output node can be of type Element, TextNode or Document). If the output node search type is Default then the following rules apply: In the enveloped XML signature case (there is a reference with URI= and transform http://www.w3.org/2000/09/xmldsig#enveloped-signature), the incoming XML document without the Signature element is set to the output message body. In the non-enveloped XML signature case, the message body is determined from a referenced Object; this is explained in more detail in chapter Output Node Determination in Enveloping XML Signature Case.

null

MEDIUM

camel.component.xmlsecurity-verify.xmlSignature Checker

This interface allows the application to check the XML signature before the validation is executed. This step is recommended in http://www.w3.org/TR/xmldsig-bestpractices/#check-what-is-signed

null

MEDIUM

camel.component.xmlsecurity-verify.basicProperty Binding

Whether the component should use basic property binding (Camel 2.x) or the newer property binding with additional capabilities

false

MEDIUM

camel.component.xmlsecurity-verify.uriDereferencer

If you want to restrict the remote access via reference URIs, you can set an own dereferencer. Optional parameter. If not set the provider default dereferencer is used which can resolve URI fragments, HTTP, file and XPpointer URIs. Attention: The implementation is provider dependent!

null

MEDIUM

camel.component.xmlsecurity-verify.verifier Configuration

To use a shared XmlVerifierConfiguration configuration to use as base for configuring endpoints.

null

MEDIUM

The camel-xmlsecurity-verify sink connector has no converters out of the box.

The camel-xmlsecurity-verify sink connector has no transforms out of the box.

The camel-xmlsecurity-verify sink connector has no aggregation strategies out of the box.