Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KAFKA-7715: Added a configuration parameter to Connect which disables WADL output for OPTIONS method. #6025

Closed
wants to merge 2 commits into from

Conversation

avocader
Copy link
Contributor

@avocader avocader commented Dec 12, 2018

Currently, Connect REST endpoint replies to OPTIONS request with verbose WADL information, which could be used for an attack.
It's not recommended for the production system to expose that information, but for the backward-compatibility reasons, it may still be available by default, with a possibility to turn it off by setting rest.wadl.enable=false.

Added unit tests in RestServerTest, which asserts that Content-type is either application/vnd.sun.wadl+xml if rest.wadl.enable=true or rest.wadl.enable is not set; or text/plain otherwise.

Committer Checklist (excluded from commit message)

  • Verify design and implementation
  • Verify test coverage and CI build status
  • Verify documentation (including upgrade notes)

Copy link
Contributor

@rhauch rhauch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, @avocader. One minor question/request below.

@@ -75,6 +75,9 @@ offset.flush.interval.ms=10000
#rest.advertised.host.name=
#rest.advertised.port=

# Controls presence of WADL information in a response to OPTIONS request
#rest.wadl.enable=false

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we also want to include this in the connect-standalone.properties?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch @rhauch , thanks. I've included new config into the standalone config file.

@avocader
Copy link
Contributor Author

Closing this PR since related KIP was discarded. Will address it in https://issues.apache.org/jira/browse/KAFKA-7759.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants