Skip to content

Conversation

@kibanamachine
Copy link
Contributor

Backport

This will backport the following commits from main to 9.3:

Questions ?

Please refer to the Backport tool documentation

## Summary

Resolves elastic#247549

Security Labs (`installSecurityLabs`) would download to `artifactPath`
but then open the zip using `artifactPath`, not the returned safe path.
That worked "by accident" as long as the downloader wrote to exactly
that path; once `downloadToDisk()` started writing to a safe location
under `data/`, the Security Labs install started failing.

#### Root cause

`downloadToDisk()` was updated to use `@kbn/fs safe-path` handling
(dce7e81). That change makes writes
land under Kibana’s `data/` dir (like `.../data/ai-kb-artifacts/...`),
which is safer — but it exposed the bug where Security Labs didn’t use
the returned full path.

#### Fix details
Security Labs now opens the zip using the downloadToDisk() return value
(the same pattern the main product docs path already used), so it opens
the file where it was actually written, and corresponding tests to catch
this have been added.

### 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 599427f)
@kibanamachine kibanamachine added the backport This PR is a backport of another PR label Jan 7, 2026
@kibanamachine kibanamachine enabled auto-merge (squash) January 7, 2026 04:38
@elasticmachine
Copy link
Contributor

elasticmachine commented Jan 7, 2026

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] Agent Builder API Smoke Tests #1 / Agent Builder - LLM Smoke tests Connector "bedrock-claude-sonnet-3-5" Converse API sync can continue a text conversation
  • [job] [logs] Agent Builder API Smoke Tests #1 / Agent Builder - LLM Smoke tests Connector "bedrock-claude-sonnet-3-5" Converse API sync can execute a tool

Metrics [docs]

✅ unchanged

History

cc @spong

@kibanamachine kibanamachine merged commit 3b63ee5 into elastic:9.3 Jan 7, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants