Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-20439

WFLY-15452 & WFLY-14255 added new attributes to XML parsing description for every undertow subsystem schema version

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Blocker Blocker
    • 36.0.0.Beta1, 36.0.0.Final
    • 33.0.0.Final, 33.0.1.Final, 33.0.2.Final, 34.0.0.Final, 34.0.1.Final, 35.0.0.Beta1, 35.0.1.Final
    • Web (Undertow)
    • None
    • Hide
      1. Modify any of the test XML for an old undertow subsystem schema version, e.g. https://github.com/wildfly/wildfly/blob/main/undertow/src/test/resources/org/wildfly/extension/undertow/undertow-4.0.xml
      2. Add allowed-request-attributes-pattern="foo" to an <ajp-listener/> element.
      3. Run the undertow subsystem unit test.
        e.g.
        cd undertow
        mvn clean install -Dtest=UndertowSubsystemTestCase

      The test XML should fail to parse. However, it does not. Instead the corresponding add operation fails because it does not recognize the new attribute.

      Show
      Modify any of the test XML for an old undertow subsystem schema version, e.g. https://github.com/wildfly/wildfly/blob/main/undertow/src/test/resources/org/wildfly/extension/undertow/undertow-4.0.xml Add allowed-request-attributes-pattern="foo" to an <ajp-listener/> element. Run the undertow subsystem unit test. e.g. cd undertow mvn clean install -Dtest=UndertowSubsystemTestCase The test XML should fail to parse. However, it does not. Instead the corresponding add operation fails because it does not recognize the new attribute.
    • ---
    • ---

      As detect here: https://ci.wildfly.org/buildConfiguration/WildFlyCore_PullRequest_WildFlyCoreFullIntegrationLinuxJdk17/490053
      ... WFLY-15452 added a new "allowed-request-attributes-pattern" attribute to the <ajp-listener/> element. However, it was added to every schema version, not just the new version.
      Worse, this attribute should only exist in preview versions of the schema, but exists in all versions.
      The existing PersistenceResourceXMLDescription implementation makes this too easy to mess up, especially when using non-DEFAULT stability level, and is, among other reasons, the impetus for WFCORE-6779.

      It appears that the same issue affects the "reuse-x-forwarded-header" and "rewrite-host-header" attributes of the <reverse-proxy-handler/> element.

              pferraro@redhat.com Paul Ferraro
              pferraro@redhat.com Paul Ferraro
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: