gnodet-bot commented on code in PR #28527:
URL: https://github.com/apache/camel/pull/28527#discussion_r4387461918
##########
catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/as2.json:
##########
@@ -78,23 +78,24 @@
"proxyHost": { "index": 37, "kind": "parameter", "displayName": "Proxy
Host", "group": "proxy", "label": "producer,proxy", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The host name of an HTTP proxy the client
sends its AS2 messages through. The connection to the proxy is plain http; when
an SSL context is configured, the AS2 message goes through a CONNECT tunnel to
the target." },
"proxyPort": { "index": 38, "kind": "parameter", "displayName": "Proxy
Port", "group": "proxy", "label": "producer,proxy", "required": false, "type":
"integer", "javaType": "java.lang.Integer", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The port number of the HTTP proxy." },
"accessToken": { "index": 39, "kind": "parameter", "displayName": "Access
Token", "group": "security", "label": "security", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": true, "security": "secret", "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The access token that is used by the client
for bearer authentication." },
- "asyncMdnAllowedHosts": { "index": 40, "kind": "parameter", "displayName":
"Async Mdn Allowed Hosts", "group": "security", "label": "security",
"required": false, "type": "string", "javaType": "java.lang.String",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "Comma separated list of host names an
asynchronous MDN may be delivered to. The delivery address is chosen by the
sender of the AS2 message, so this is the list of hosts the operator vouches
for. When set, an asynchronous MDN whose delivery address names a host outside
the list is refused, and the configured
mdnUserName\/mdnPassword\/mdnAccessToken are attached only to a host on the
list. When not set, the MDN is still delivered to the sender-supplied address
but no credentials are attached. The option applies to the consumer endpoint it
is set on: consumers sharing a serverPortNumber ea
ch apply their own list." },
- "decryptingPrivateKey": { "index": 41, "kind": "parameter", "displayName":
"Decrypting Private Key", "group": "security", "label": "security", "required":
false, "type": "object", "javaType": "java.security.PrivateKey", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The key used to encrypt the EDI message." },
- "encryptingAlgorithm": { "index": 42, "kind": "parameter", "displayName":
"Encrypting Algorithm", "group": "security", "label": "security", "required":
false, "type": "enum", "javaType":
"org.apache.camel.component.as2.api.AS2EncryptionAlgorithm", "enum": [
"AES128_CBC", "AES192_CBC", "AES256_CBC", "AES128_CCM", "AES192_CCM",
"AES256_CCM", "AES128_GCM", "AES192_GCM", "AES256_GCM", "CAMELLIA128_CBC",
"CAMELLIA192_CBC", "CAMELLIA256_CBC", "CAST5_CBC", "DES_CBC", "DES_EDE3_CBC",
"GOST28147_GCFB", "IDEA_CBC", "RC2_CBC", "RC4", "SEED_CBC" ], "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The algorithm used to encrypt EDI message." },
- "encryptingCertificateChain": { "index": 43, "kind": "parameter",
"displayName": "Encrypting Certificate Chain", "group": "security", "label":
"security", "required": false, "type": "object", "javaType":
"java.security.cert.Certificate[]", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The chain of certificates used to encrypt EDI
message." },
- "hostnameVerifier": { "index": 44, "kind": "parameter", "displayName":
"Hostname Verifier", "group": "security", "label": "security", "required":
false, "type": "object", "javaType": "javax.net.ssl.HostnameVerifier",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "Set hostname verifier for SSL session." },
- "mdnAccessToken": { "index": 45, "kind": "parameter", "displayName": "Mdn
Access Token", "group": "security", "label": "security", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": true, "security": "secret", "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The access token that is used by the server
when it sends an async MDN. The option applies to the consumer endpoint it is
set on, like mdnUserName." },
- "mdnPassword": { "index": 46, "kind": "parameter", "displayName": "Mdn
Password", "group": "security", "label": "security", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": true, "security": "secret", "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The password that is used by the server for
basic authentication when it sends an async MDN. The option applies to the
consumer endpoint it is set on, like mdnUserName." },
- "mdnUserName": { "index": 47, "kind": "parameter", "displayName": "Mdn
User Name", "group": "security", "label": "security", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": true, "security": "secret", "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The user-name that is used by the server for
basic authentication when it sends an async MDN. If options for basic
authentication and bearer authentication are both set then basic authentication
takes precedence. The option applies to the consumer endpoint it is set on:
consumers sharing a serverPortNumber each send their async MDNs with their own
values." },
- "password": { "index": 48, "kind": "parameter", "displayName": "Password",
"group": "security", "label": "security", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": true, "security": "secret", "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The password that is used by the client for
basic authentication." },
- "signatureVerificationRequired": { "index": 49, "kind": "parameter",
"displayName": "Signature Verification Required", "group": "security", "label":
"security", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue":
false, "configurationClass": "org.apache.camel.component.as2.AS2Configuration",
"configurationField": "configuration", "description": "Whether to reject an
inbound signed AS2 message that cannot be verified because no
validateSigningCertificateChain is configured (server only). When false
(default), such a message is delivered after logging a warning, preserving the
previous behaviour. When true, the message is rejected instead of being
delivered without verifying its signature. Has no effect when
validateSigningCertificateChain is set (signatures are always validated then)
or for unsigned messages." },
- "signedReceiptMicAlgorithms": { "index": 50, "kind": "parameter",
"displayName": "Signed Receipt Mic Algorithms", "group": "security", "label":
"security", "required": false, "type": "string", "javaType":
"java.lang.String", "deprecated": false, "autowired": false, "secret": false,
"configurationClass": "org.apache.camel.component.as2.AS2Configuration",
"configurationField": "configuration", "description": "The list of algorithms,
in order of preference, requested to generate a message integrity check (MIC)
returned in message disposition notification (MDN). Multiple algorithms can be
separated by comma." },
- "signingAlgorithm": { "index": 51, "kind": "parameter", "displayName":
"Signing Algorithm", "group": "security", "label": "security", "required":
false, "type": "enum", "javaType":
"org.apache.camel.component.as2.api.AS2SignatureAlgorithm", "enum": [
"SHA3_224WITHRSA", "SHA3_256WITHRSA", "SHA3_384withRSA", "SHA3_512WITHRSA",
"MD5WITHRSA", "SHA1WITHRSA", "MD2WITHRSA", "SHA224WITHRSA", "SHA256WITHRSA",
"SHA384WITHRSA", "SHA512WITHRSA", "RIPEMD128WITHRSA", "RIPEMD160WITHRSA",
"RIPEMD256WITHRSA", "SHA224WITHDSA", "SHA256WITHDSA", "SHA384WITHDSA",
"SHA512WITHDSA", "SHA3_224WITHDSA", "SHA3_256WITHDSA", "SHA3_384WITHDSA",
"SHA3_512WITHDSA", "SHA1WITHDSA", "SHA3_224WITHECDSA", "SHA3_256WITHECDSA",
"SHA3_384WITHECDSA", "SHA3_512WITHECDSA", "SHA1WITHECDSA", "SHA224WITHECDSA",
"SHA256WITHECDSA", "SHA384WITHECDSA", "SHA512WITHECDSA", "SHA1WITHPLAIN_ECDSA",
"SHA224WITHPLAIN_ECDSA", "SHA256WITHPLAIN_ECDSA", "SHA384WITHPLAIN_ECDSA",
"SHA512WITHPLAIN_ECDSA", "RIPEMD160WITHPLAIN_ECDSA", "SHA1WIT
HRSAANDMGF1", "SHA224WITHRSAANDMGF1", "SHA256WITHRSAANDMGF1",
"SHA384WITHRSAANDMGF1", "SHA512WITHRSAANDMGF1", "SHA3_224WITHRSAANDMGF1",
"SHA3_256WITHRSAANDMGF1", "SHA3_384WITHRSAANDMGF1", "SHA3_512WITHRSAANDMGF1" ],
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The algorithm used to sign EDI message." },
- "signingCertificateChain": { "index": 52, "kind": "parameter",
"displayName": "Signing Certificate Chain", "group": "security", "label":
"security", "required": false, "type": "object", "javaType":
"java.security.cert.Certificate[]", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The chain of certificates used to sign EDI
message." },
- "signingPrivateKey": { "index": 53, "kind": "parameter", "displayName":
"Signing Private Key", "group": "security", "label": "security", "required":
false, "type": "object", "javaType": "java.security.PrivateKey", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The key used to sign the EDI message." },
- "sslContext": { "index": 54, "kind": "parameter", "displayName": "Ssl
Context", "group": "security", "label": "security", "required": false, "type":
"object", "javaType": "javax.net.ssl.SSLContext", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "Set SSL context for connection to remote
server." },
- "userName": { "index": 55, "kind": "parameter", "displayName": "User
Name", "group": "security", "label": "security", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": true, "security": "secret", "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "The user-name that is used by the client for
basic authentication. If options for basic authentication and bearer
authentication are both set then basic authentication takes precedence." },
- "validateSigningCertificateChain": { "index": 56, "kind": "parameter",
"displayName": "Validate Signing Certificate Chain", "group": "security",
"label": "security", "required": false, "type": "object", "javaType":
"java.security.cert.Certificate[]", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "Certificates to validate the message's
signature against. If not supplied, validation will not take place. Server:
validates the received message. Client: not yet implemented, should validate
the MDN" }
+ "asyncMdnAllowedHosts": { "index": 40, "kind": "parameter", "displayName":
"Async Mdn Allowed Hosts", "group": "security", "label": "security",
"required": false, "type": "string", "javaType": "java.lang.String",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.as2.AS2Configuration", "configurationField":
"configuration", "description": "Comma separated list of hosts an asynchronous
MDN may be delivered to. The delivery address is chosen by the sender of the
AS2 message, so this is the list of destinations the operator vouches for. Each
entry is a host with an optional port in host:port form (IPv6 literals use
bracket notation, for example ::1 or ::1:8443); a bare-host entry (for example
partner.example) matches only the default port for the scheme (80 or 443), so a
non-default port is listed explicitly (for example partner.example:8443). When
set, an asynchronous MDN whose delivery address is not on the list is refused,
and the configured mdnUserName\/mdnPassword\/mdnAccessToken are attached only
to an address on the list. When not set, the MDN is still delivered to the
sender-supplied address but no credentials are attached. The option applies to
the consumer endpoint it is set on: consumers sharing a serverPortNumber each
apply their own list." },
Review Comment:
⚠️ The codegen has stripped the square brackets from the IPv6 examples. The
description currently reads:
> (IPv6 literals use bracket notation, for example `::1` or `::1:8443`)
But the correct forms are `[::1]` and `[::1]:8443`. The unbracketed form
`::1:8443` is silently broken: `authorityMatches("::1:8443", ...)` detects
multiple colons and assigns the entire string as `entryHost`, so it can never
match any URI host (which is `::1` after `normalizeHost`). An operator who
copies `::1:8443` from the catalog description will have every IPv6 MDN
silently refused.
The source Javadoc in `AS2Configuration.java` and the upgrade guide are
already correct (`[::1]` or `[::1]:8443`). Re-generate the artifacts after
ensuring the Javadoc brackets survive the code-generator (e.g. wrap examples in
`{@code [::1]}` or use HTML entities `[::1]`), or correct the
descriptions in the generated files manually.
--
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]