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

[Fleet][7.17.16 to 8.12.0 Upgrade] Red banner under Elastic Defend integration. #174012

Closed
ghost opened this issue Dec 28, 2023 · 7 comments · Fixed by #174152
Closed

[Fleet][7.17.16 to 8.12.0 Upgrade] Red banner under Elastic Defend integration. #174012

ghost opened this issue Dec 28, 2023 · 7 comments · Fixed by #174152
Assignees
Labels
bug Fixes for quality problems that affect the customer experience impact:critical This issue should be addressed immediately due to a critical level of impact on the product. Team:Fleet Team label for Observability Data Collection Fleet team

Comments

@ghost
Copy link

ghost commented Dec 28, 2023

Describe the bug:
[Fleet][7.17.16 to 8.12.0 Upgrade] Red banner under Elastic Defend integration.

Kibana/Elasticsearch Stack version

Version: 8.12 BC3
Commit: 2a8afed8572a4c709aa1c64216748197eeb9b18f
Build: 69985

Browser and Browser OS Version:
Firefox for windows OS
Version: 121.0

precondition

  • Install windows endpoint with Elastic Security Integration on 7.17.16

Steps to reproduce

  • Upgrade the kibana instance to 8.12 BC3.
  • Go to Agent details page
  • Under the Integrations section, Click on Endpoint Security Integration
  • expand the details and click on it
  • Observed that red banner appears

Additional Result

  • N/A

Current Result

  • [Fleet][7.17.16 to 8.12.0 Upgrade] Red banner under Elastic Defend integration.

Expected behavior:

  • No red banner should be observed after kibana instance upgrade

Screen-Cast:

Red.Banner.Fleet.Page.mp4
@ghost ghost added bug Fixes for quality problems that affect the customer experience triage_needed Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. labels Dec 28, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-solution (Team: SecuritySolution)

@ghost ghost added impact:critical This issue should be addressed immediately due to a critical level of impact on the product. Team:Fleet Team label for Observability Data Collection Fleet team and removed Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. labels Dec 28, 2023
@elasticmachine
Copy link
Contributor

Pinging @elastic/fleet (Team:Fleet)

@amolnater-qasource amolnater-qasource removed their assignment Dec 28, 2023
@ghost ghost changed the title [Security Solution][Fleet][7.17.16 to 8.12.0 Upgrade] Red under Elastic Defend integration [Fleet][7.17.16 to 8.12.0 Upgrade] Red under Elastic Defend integration Dec 28, 2023
@ghost ghost changed the title [Fleet][7.17.16 to 8.12.0 Upgrade] Red under Elastic Defend integration [Fleet][7.17.16 to 8.12.0 Upgrade] Red banner under Elastic Defend integration. Dec 28, 2023
@amolnater-qasource
Copy link

Secondary Review for this ticket is Done.

@jen-huang
Copy link
Contributor

@juliaElastic, could you look at fixing this bug for 8.12?

@dasansol92
Copy link
Contributor

Checking this locally I noticed this is happening in main when enrolling a 7.17.16 agent (a stack upgrade is not needed).
The error occurs here: https://github.com/elastic/kibana/blob/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_details/agent_details_integration_input_status.tsx#L23

My guess is for older elastic agent versions (<8.0.0 maybe?) this value is not valid. Perhaps @jillguyonnet has more inputs on it?

I think this is not an 8.12 regression, but worth if we can confirm it. @karanbirsingh-qasource could you do this test with 8.10 and 8.11 to ensure this is not tied to 8.12?
No upgrade is needed, you can directly enroll a 7.17.16 agent to a 8.10 Kibana and do the same test.

cc: @juliaElastic

@juliaElastic
Copy link
Contributor

@dasansol92 Thanks, I reproduced it too and found the same place where the error occurs. At least I can add a null check to avoid this unhandled error.

juliaElastic added a commit that referenced this issue Jan 3, 2024
…ing (#174152)

## Summary

Closes #174012

Added a null check when `agent.components` is undefined, to prevent
unhandled error in Agent Details UI.

To reproduce:
1. start kibana locally/cloud version 8.12+
2. create agent policy with endpoint 1.3.0 integration (can be latest
too)
3. enroll an agent version 7.17.16, can be in container
4. navigate to agent details page, open the inputs arrows on the right
5. expect that there is no error banner coming up, but an empty content

<img width="1197" alt="image"
src="https://github.com/elastic/kibana/assets/90178898/dabcca72-4e08-4185-a166-a91136615904">


### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
kibanamachine pushed a commit to kibanamachine/kibana that referenced this issue Jan 3, 2024
…ing (elastic#174152)

## Summary

Closes elastic#174012

Added a null check when `agent.components` is undefined, to prevent
unhandled error in Agent Details UI.

To reproduce:
1. start kibana locally/cloud version 8.12+
2. create agent policy with endpoint 1.3.0 integration (can be latest
too)
3. enroll an agent version 7.17.16, can be in container
4. navigate to agent details page, open the inputs arrows on the right
5. expect that there is no error banner coming up, but an empty content

<img width="1197" alt="image"
src="https://github.com/elastic/kibana/assets/90178898/dabcca72-4e08-4185-a166-a91136615904">

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

(cherry picked from commit 9da2776)
kibanamachine referenced this issue Jan 3, 2024
…re missing (#174152) (#174156)

# Backport

This will backport the following commits from `main` to `8.12`:
- [[Fleet] fix unhandled error in agent details when components are
missing (#174152)](#174152)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Julia
Bardi","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-01-03T11:49:09Z","message":"[Fleet]
fix unhandled error in agent details when components are missing
(#174152)\n\n## Summary\r\n\r\nCloses
https://github.com/elastic/kibana/issues/174012\r\n\r\nAdded a null
check when `agent.components` is undefined, to prevent\r\nunhandled
error in Agent Details UI.\r\n\r\nTo reproduce:\r\n1. start kibana
locally/cloud version 8.12+\r\n2. create agent policy with endpoint
1.3.0 integration (can be latest\r\ntoo)\r\n3. enroll an agent version
7.17.16, can be in container\r\n4. navigate to agent details page, open
the inputs arrows on the right\r\n5. expect that there is no error
banner coming up, but an empty content\r\n\r\n<img width=\"1197\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/90178898/dabcca72-4e08-4185-a166-a91136615904\">\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"9da2776d6d89b9e62638d47f8fb5e6101c9bf8e9","branchLabelMapping":{"^v8.13.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:Fleet","v8.12.0","v8.13.0"],"title":"[Fleet]
fix unhandled error in agent details when components are
missing","number":174152,"url":"https://github.com/elastic/kibana/pull/174152","mergeCommit":{"message":"[Fleet]
fix unhandled error in agent details when components are missing
(#174152)\n\n## Summary\r\n\r\nCloses
https://github.com/elastic/kibana/issues/174012\r\n\r\nAdded a null
check when `agent.components` is undefined, to prevent\r\nunhandled
error in Agent Details UI.\r\n\r\nTo reproduce:\r\n1. start kibana
locally/cloud version 8.12+\r\n2. create agent policy with endpoint
1.3.0 integration (can be latest\r\ntoo)\r\n3. enroll an agent version
7.17.16, can be in container\r\n4. navigate to agent details page, open
the inputs arrows on the right\r\n5. expect that there is no error
banner coming up, but an empty content\r\n\r\n<img width=\"1197\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/90178898/dabcca72-4e08-4185-a166-a91136615904\">\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"9da2776d6d89b9e62638d47f8fb5e6101c9bf8e9"}},"sourceBranch":"main","suggestedTargetBranches":["8.12"],"targetPullRequestStates":[{"branch":"8.12","label":"v8.12.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.13.0","branchLabelMappingKey":"^v8.13.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/174152","number":174152,"mergeCommit":{"message":"[Fleet]
fix unhandled error in agent details when components are missing
(#174152)\n\n## Summary\r\n\r\nCloses
https://github.com/elastic/kibana/issues/174012\r\n\r\nAdded a null
check when `agent.components` is undefined, to prevent\r\nunhandled
error in Agent Details UI.\r\n\r\nTo reproduce:\r\n1. start kibana
locally/cloud version 8.12+\r\n2. create agent policy with endpoint
1.3.0 integration (can be latest\r\ntoo)\r\n3. enroll an agent version
7.17.16, can be in container\r\n4. navigate to agent details page, open
the inputs arrows on the right\r\n5. expect that there is no error
banner coming up, but an empty content\r\n\r\n<img width=\"1197\"
alt=\"image\"\r\nsrc=\"https://github.com/elastic/kibana/assets/90178898/dabcca72-4e08-4185-a166-a91136615904\">\r\n\r\n\r\n###
Checklist\r\n\r\n- [x] [Unit or
functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere
updated or added to match the most common
scenarios","sha":"9da2776d6d89b9e62638d47f8fb5e6101c9bf8e9"}}]}]
BACKPORT-->

Co-authored-by: Julia Bardi <[email protected]>
@harshitgupta-qasource
Copy link

Bug Conversion

  • Test-Case not required as this particular checkpoint is already covered in exploratory testing.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience impact:critical This issue should be addressed immediately due to a critical level of impact on the product. Team:Fleet Team label for Observability Data Collection Fleet team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants