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

[Reporting] Config Schema Validation for rules[N].protocol strings #80766

Merged
merged 1 commit into from
Oct 15, 2020

Conversation

tsullivan
Copy link
Member

@tsullivan tsullivan commented Oct 15, 2020

Summary

A Reporting Network Policy is a newly documented feature (separate PR), it's expected that more users will implement it in their config. Those who do so should have a safety measure against inputting protocol strings without an ending colon, which would be parsed correctly.

This PR adds config schema validation to xpack.reporting.capture.networkPolicy.rules[].protocol - it must end in colon.

This PR is breaking, as Kibana will not start up after upgrading if a kibana.yml file has a protocol string that does match the new validation. Since this is a newly documented feature, that doesn't seem highly likely. On the other hand, this change is important for the new adopters in 7.x.

Checklist

Delete any items that are not applicable to this PR.

For maintainers

Release Note

The Reporting plugin added new validation for protocol strings in Network Policy configurations. See "Restrict requests with a Reporting network policy" in the Kibana documentation. If the kibana.yml has a Reporting network policy before upgrade, the protocol strings must end with a colon. Otherwise, config validation will fail and Kibana will not start.

@tsullivan tsullivan added release_note:breaking (Deprecated) Feature:Reporting Use Reporting:Screenshot, Reporting:CSV, or Reporting:Framework instead v8.0.0 Team:AppArch v7.11.0 labels Oct 15, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app-arch (Team:AppArch)

@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-reporting-services (Team:Reporting Services)

Copy link
Contributor

@joelgriffith joelgriffith left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for the follow up

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

@tsullivan tsullivan merged commit 2fa0837 into elastic:master Oct 15, 2020
@tsullivan tsullivan deleted the reporting/proto-end-in-colon branch October 15, 2020 23:14
gmmorris added a commit to gmmorris/kibana that referenced this pull request Oct 16, 2020
* master: (115 commits)
  [ML] Transforms/DF Analytics: Fix data grid column sorting. (elastic#80618)
  added brace import to vis editor (elastic#80652)
  Fix error rate sorting in services list (elastic#80764)
  Emit info log when using custom registry URL (elastic#80768)
  [Reporting] Config Schema Validation for rules[N].protocol strings (elastic#80766)
  Add Storybook a11y addon (elastic#80069)
  Fix anomaly alert selection text (elastic#80746)
  [Security Solution] [Maps] Kibana index pattern, comma bug fix (elastic#80208)
  [kbn/optimizer] tweak split chunks options (elastic#80444)
  update template to use the new team label (elastic#80748)
  [Security Solution] Fix the Field dropdown in Timeline data providers resets when scrolled (elastic#80718)
  Adjusts observability alerting perms to require "all" (elastic#79896)
  [Security Solutions][Detection Engine] Fixes pre-packaged rules which contain exception lists to not overwrite user defined lists   (elastic#80592)
  [data.ui] Fix flaky test & lazy loading rendering artifacts. (elastic#80612)
  Licensed feature usage for connectors (elastic#77679)
  [Security Solution] Cypress template creation (elastic#80180)
  [APM] Hide service if only data is from ML (elastic#80145)
  Fix role mappings test for ESS (elastic#80604)
  [Maps] Add support for envelope (elastic#80614)
  [Security Solution] Update button text according to status (elastic#80389)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
(Deprecated) Feature:Reporting Use Reporting:Screenshot, Reporting:CSV, or Reporting:Framework instead release_note:breaking v7.11.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants