Replace host sensor with node agent sensing#681
Conversation
Signed-off-by: Bezalel Brandwine <bez@softwine.net>
Signed-off-by: Bezalel Brandwine <bez@softwine.net>
|
this is very early draft :) |
Signed-off-by: Bezalel Brandwine <bez@softwine.net>
Signed-off-by: Bezalel Brandwine <bez@softwine.net>
Signed-off-by: Bezalel Brandwine <bez@softwine.net>
Signed-off-by: Bezalel Brandwine <bez@softwine.net>
Signed-off-by: Bezalel Brandwine <bez@softwine.net>
📝 WalkthroughWalkthroughThis pull request introduces a Host Sensor Manager system that periodically collects host system information (OS release, kernel version, security settings, network ports, cloud provider metadata, CNI configuration, kubelet/kube-proxy details, and control plane components) and persists collected data as Kubernetes Custom Resources. The system integrates configuration, multiple sensor implementations, a CRD client, and lifecycle management. Changes
Sequence Diagram(s)sequenceDiagram
participant Main as Main Process
participant HSM as HostSensorManager
participant Sensors as Sensors
participant CRDClient as CRDClient
participant K8s as Kubernetes API
Main->>HSM: NewHostSensorManager(config)
HSM->>HSM: Initialize sensors<br/>(OS, Kernel, Security, Network, etc.)
HSM->>CRDClient: NewCRDClient(nodeName)
CRDClient->>K8s: Build in-cluster config
Main->>HSM: Start(ctx)
activate HSM
HSM->>HSM: runSensing() - initial sense
loop Periodic Sensing
HSM->>Sensors: runSensor(sensor)
activate Sensors
Sensors->>Sensors: Sense()
Sensors-->>HSM: sensor data
deactivate Sensors
alt On Sensor Success
HSM->>CRDClient: CreateOrUpdateHostData(spec)
CRDClient->>K8s: Create/Update CRD
K8s-->>CRDClient: Resource Version
else On Sensor Error
HSM->>CRDClient: UpdateStatus(errorMsg)
CRDClient->>K8s: Patch status
end
HSM->>HSM: Wait for interval
end
Main->>HSM: Stop()
HSM->>HSM: Signal stop, drain in-flight
deactivate HSM
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
Comment |
There was a problem hiding this comment.
Actionable comments posted: 9
🤖 Fix all issues with AI agents
In `@pkg/hostsensormanager/crd_client.go`:
- Around line 107-131: The status patch must target the CRD status subresource
if the CRD exposes .status; update the Patch call in UpdateStatus to use the
status subresource by calling
c.dynamicClient.Resource(gvr).SubResource("status").Patch(...) (keep
MergePatchType and the same patchData and PatchOptions). Ensure the call still
uses c.nodeName as the resource name and context ctx; adjust any imports/err
handling as needed.
In `@pkg/hostsensormanager/sensor_cloudprovider.go`:
- Around line 74-80: The loop currently uses defer res.Body.Close() after
client.Do(httpReq), which delays closing until function exit and leaks
resources; change it to close the response body immediately when you are done
with it (for example after checking res.StatusCode), by ensuring you check err
and res != nil, read or discard the body if needed, and call res.Body.Close()
directly instead of deferring; update the logic around client.Do, httpReq, res
and the http.StatusOK check so each response body is promptly closed within the
iteration.
In `@pkg/hostsensormanager/sensor_controlplane.go`:
- Around line 7-21: The Sense() implementation currently omits Etcd and the API
server encryption provider arg: add code to locate the etcd process (using
constant etcdExe), parse its command-line for the --data-dir (etcdDataDirArg)
and set ControlPlaneInfoSpec.EtcdDataDir; likewise, when inspecting the API
server process (apiServerExe) parse its command-line for
--encryption-provider-config (and existing auditPolicyFileArg) and populate
ApiServerInfo.EncryptionProviderConfigFile (and ensure AuditPolicyFile remains
set). Implement these extra parses in the same process-walking logic used for
kube-apiserver/controller-manager/scheduler inside Sense() so the Etcd data
directory and API server encryption file are filled before returning
ControlPlaneInfoSpec.
In `@pkg/hostsensormanager/sensor_kernelvars.go`:
- Around line 68-76: The loop opens files into varFile and defers
varFile.Close() inside the loop (using hVarFileName and varFile) which leaks FDs
across iterations due to batched Readdirnames(100) and recursive traversal;
change the code to close varFile before the next iteration/return by replacing
the defer with an explicit Close call scoped per iteration (e.g., wrap the
per-file processing in an anonymous function that calls varFile.Close() at the
end or call varFile.Close() immediately after use and before continue/return) so
each opened file is closed promptly.
In `@pkg/hostsensormanager/sensor_network.go`:
- Around line 12-14: The current constant tcpListeningState (value 10) is
misleading and is being applied to ICMP where "listening" has no semantic
meaning; rename the constant to listeningState and change the filtering logic in
sensor_network.go so the listeningState filter is applied only to protocols that
support socket states (e.g., TCP and UDP) and skip or treat ICMP entries
separately (do not filter ICMP by listeningState or explicitly exclude ICMP when
checking state). Update all references to tcpListeningState to listeningState
and add a small conditional around the state check that checks the protocol
(e.g., protocol == "tcp" || protocol == "udp") before comparing to
listeningState.
In `@pkg/hostsensormanager/sensor_osrelease.go`:
- Around line 67-76: The loop over etcDir.Readdirnames(100) currently swallows
non-EOF errors and always returns "not found"; update the logic so that
Readdirnames errors are propagated: call etcDir.Readdirnames in a loop and if
err != nil then if err == io.EOF break the loop, else return "", err; continue
scanning filenames for osReleaseFileSuffix (logger.L().Debug uses helpers.String
for filename) and only after exhausting entries return the os-release not found
error referencing hEtcDir. Ensure you use the existing etcDir.Readdirnames,
osReleaseFileSuffix and hEtcDir identifiers and avoid masking errors by
returning the actual error when non-EOF occurs.
In `@pkg/hostsensormanager/sensor_security.go`:
- Around line 7-10: The SELinux constant is pointing at the wrong file; update
seLinuxConfigFileName (currently set to "/etc/selinux/semanage.conf") to
"/etc/selinux/config" and change any code that reads the file (e.g., functions
referencing seLinuxConfigFileName) to parse the "SELINUX=" line and return the
mode (enforcing/permissive/disabled) instead of returning the whole file
contents.
In `@pkg/hostsensormanager/types.go`:
- Around line 134-139: OpenPortsSpec's ICMPPorts field is misleading because
ICMP uses type/code pairs instead of ports; replace or rename it: either (A)
rename ICMPPorts to ICMPConnections to clarify semantics, or (B) better, define
a new struct (e.g., ICMPRecord { Type int `json:"type"`; Code int `json:"code"`;
/* optional meta fields */ }) and change OpenPortsSpec.ICMPPorts from
[]Connection to []ICMPRecord with an appropriate json tag, and update all usages
(constructors, serializers, tests) that reference OpenPortsSpec.ICMPPorts or the
Connection type to use the new field/type (or new name) so code no longer stores
ICMP data in LocalPort/RemotePort fields of Connection.
- Around line 76-229: The CRD types (OsReleaseFile, KernelVersion,
LinuxSecurityHardening, OpenPorts, LinuxKernelVariables, KubeletInfo,
KubeProxyInfo, ControlPlaneInfo, CloudProviderInfo, CNIInfo) lack DeepCopy
methods required by controller-runtime/client-go; add codegen by installing and
running controller-gen (sigs.k8s.io/controller-tools) and annotate each type
with +kubebuilder:object:root=true and +kubebuilder:subresource:status as
appropriate, then run controller-gen object:headerFile=<path> paths=./... to
generate zz_generated.deepcopy.go files, or alternatively implement manual
DeepCopyInto/DeepCopy/DeepCopyObject methods for the listed types (and their
Spec structs) to satisfy kubernetes runtime.Object and deepcopy-gen
requirements; ensure generated files are committed and the build/Makefile
updated to run controller-gen in CI.
🧹 Nitpick comments (12)
pkg/hostsensormanager/sensor_network.go (1)
80-100: Error handling stops on first missing file, potentially skipping valid data.If any file in
pathsListdoesn't exist (e.g.,/proc/net/icmp6on systems without IPv6, or/proc/net/udplite*if the module isn't loaded), the function returns early and skips remaining files. Consider continuing onos.ErrNotExisterrors.♻️ Proposed fix
func (s *OpenPortsSensor) getOpenedPorts(pathsList []string) ([]Connection, error) { res := make([]Connection, 0) for _, p := range pathsList { hPath := hostPath(p) bytesBuf, err := os.ReadFile(hPath) if err != nil { + if os.IsNotExist(err) { + continue // File doesn't exist on this system, skip + } return res, fmt.Errorf("failed to ReadFile(%s): %w", hPath, err) } netCons := procspy.NewProcNet(bytesBuf, tcpListeningState) for c := netCons.Next(); c != nil; c = netCons.Next() { res = append(res, Connection{ Transport: c.Transport, LocalAddress: c.LocalAddress.String(), LocalPort: c.LocalPort, RemoteAddress: c.RemoteAddress.String(), RemotePort: c.RemotePort, }) } } return res, nil }pkg/hostsensormanager/sensor_cloudprovider.go (1)
45-58: Consider AWS IMDSv2 support for broader compatibility.The AWS metadata check uses IMDSv1 (direct GET). Many AWS environments now require IMDSv2, which needs a session token obtained via PUT request first. This could result in false negatives on security-hardened instances.
pkg/config/config.go (1)
101-103: Validate HostSensorInterval to prevent invalid scheduling.Consider guarding against zero/negative values after unmarshal so misconfigurations fail fast rather than causing runtime instability.
Proposed validation
// Validate seccompProfileBackend value if config.SeccompProfileBackend != "" && config.SeccompProfileBackend != SeccompBackendStorage && config.SeccompProfileBackend != SeccompBackendCRD { return Config{}, fmt.Errorf("invalid seccompProfileBackend value: %q (must be %q or %q)", config.SeccompProfileBackend, SeccompBackendStorage, SeccompBackendCRD) } + + if config.HostSensorInterval <= 0 { + return Config{}, fmt.Errorf("invalid hostSensorInterval value: %s (must be > 0)", config.HostSensorInterval) + }pkg/hostsensormanager/sensor_kubeproxy.go (1)
43-46: Consider soft-failing when kube-proxy is absent.On clusters that don’t run kube-proxy, returning an error may cause noisy logs or failed sensing cycles. Please verify the manager’s error handling and, if needed, downgrade “not found” to a non-fatal outcome (empty spec + nil error).
pkg/hostsensormanager/crd_client.go (2)
133-147: Remove unusedtoUnstructuredfunction.This function is defined but never called anywhere in the codebase.
88-91: Remove unnecessary UID assignment on update.The UID is server-assigned and immutable. Setting it on the update object is unnecessary—only
resourceVersionis required for optimistic concurrency.// Update the object with the resource version and other metadata unstructuredObj.SetResourceVersion(existing.GetResourceVersion()) - unstructuredObj.SetUID(existing.GetUID())pkg/hostsensormanager/sensor_cni.go (1)
54-81: Consider extending CNI detection list.The current list covers major CNIs but misses some cloud-provider-specific ones like Azure CNI (
azure-vnet) or GKE's CNI. This could be extended in future iterations.pkg/hostsensormanager/sensor_security.go (2)
43-56: Redundant file operations ingetAppArmorStatus.The code opens the file with
os.Opento check existence, then separately callsreadFileOnHostFileSystemwhich likely opens and reads the file again. Consolidate into a single read operation.Proposed simplification
func (s *LinuxSecurityHardeningSensor) getAppArmorStatus() string { statusStr := "unloaded" - hAppArmorProfilesFileName := hostPath(appArmorProfilesFileName) - profFile, err := os.Open(hAppArmorProfilesFileName) - if err == nil { - defer profFile.Close() - statusStr = "stopped" - content, err := readFileOnHostFileSystem(appArmorProfilesFileName) - if err == nil && len(content) > 0 { - statusStr = string(content) - } + content, err := readFileOnHostFileSystem(appArmorProfilesFileName) + if err != nil { + return statusStr // "unloaded" if file doesn't exist + } + if len(content) == 0 { + return "stopped" } - return statusStr + return string(content) }
58-70: Same redundant file operations and raw content return.Similar to
getAppArmorStatus, this has redundant file operations. Additionally, returning the raw file content isn't useful—the SELinux status should be parsed from theSELINUX=line in the config.Proposed improvement
func (s *LinuxSecurityHardeningSensor) getSELinuxStatus() string { content, err := readFileOnHostFileSystem(seLinuxConfigFileName) if err != nil { return "not found" } // Parse SELINUX= line for _, line := range strings.Split(string(content), "\n") { line = strings.TrimSpace(line) if strings.HasPrefix(line, "SELINUX=") { return strings.TrimPrefix(line, "SELINUX=") } } return "unknown" }pkg/hostsensormanager/manager.go (2)
70-76: Initial sensing blocksStart()return.The initial
runSensing(ctx)call at line 72 runs synchronously, which could blockStart()for several seconds while all sensors execute. Consider making this async or document thatStart()may take time.If fast startup is desired:
// Run initial sensing immediately - m.runSensing(ctx) + go m.runSensing(ctx) // Start periodic sensing
131-157: Consider adding timeout for individual sensor execution.If a sensor hangs (e.g., blocking on a slow/unresponsive filesystem), the entire sensing loop is blocked. Consider wrapping sensor execution with a per-sensor timeout.
func (m *manager) runSensor(ctx context.Context, sensor Sensor) error { sensorCtx, cancel := context.WithTimeout(ctx, 30*time.Second) defer cancel() // Pass sensorCtx to any context-aware operations // ... }Note: This requires sensors to respect context cancellation, which they currently don't. This could be addressed in a follow-up.
pkg/hostsensormanager/types.go (1)
24-32: Consider stronger typing forSense()return value.Returning
interface{}provides no compile-time guarantees about the returned data. Callers must perform type assertions, which can lead to runtime errors if a sensor returns an unexpected type.If all sensors return a CRD-like struct, consider defining a common interface or using generics:
type SensorData interface { GetSpec() interface{} GetStatus() Status }This is a recommended improvement that can be addressed in a follow-up iteration.
This PR contains the following updates: | Package | Update | Change | |---|---|---| | [kubescape-operator](https://kubescape.io/) ([source](https://redirect.github.com/kubescape/helm-charts)) | patch | `1.30.2` → `1.30.3` | --- ### Release Notes <details> <summary>kubescape/helm-charts (kubescape-operator)</summary> ### [`v1.30.3`](https://redirect.github.com/kubescape/helm-charts/releases/tag/kubescape-operator-1.30.3) [Compare Source](https://redirect.github.com/kubescape/helm-charts/compare/kubescape-operator-1.30.2...kubescape-operator-1.30.3) Kubescape is an E2E Kubernetes cluster security platform #### What's Changed - chore: adding the ability to adjust the source of busybox by [@​drew-viles](https://redirect.github.com/drew-viles) in [#​784](https://redirect.github.com/kubescape/helm-charts/pull/784) - add k8s context tag by [@​YakirOren](https://redirect.github.com/YakirOren) in [#​785](https://redirect.github.com/kubescape/helm-charts/pull/785) - run system tests from private repo by [@​bvolovat](https://redirect.github.com/bvolovat) in [#​786](https://redirect.github.com/kubescape/helm-charts/pull/786) - add stream logs and wait for tests finish by [@​bvolovat](https://redirect.github.com/bvolovat) in [#​787](https://redirect.github.com/kubescape/helm-charts/pull/787) - fix attempt by [@​bvolovat](https://redirect.github.com/bvolovat) in [#​788](https://redirect.github.com/kubescape/helm-charts/pull/788) - Update 02-e2e-test.yaml by [@​armobot](https://redirect.github.com/armobot) in [#​789](https://redirect.github.com/kubescape/helm-charts/pull/789) - Run test from private repo by [@​bvolovat](https://redirect.github.com/bvolovat) in [#​791](https://redirect.github.com/kubescape/helm-charts/pull/791) - add workflow\_call by [@​bvolovat](https://redirect.github.com/bvolovat) in [#​792](https://redirect.github.com/kubescape/helm-charts/pull/792) - add startup probe by [@​YakirOren](https://redirect.github.com/YakirOren) in [#​793](https://redirect.github.com/kubescape/helm-charts/pull/793) - <kubescape/kubescape@v3.0.47...v3.0.48> - Fix typos in documentation by [@​oglok](https://redirect.github.com/oglok) in [kubescape/kubescape#1913](https://redirect.github.com/kubescape/kubescape/pull/1913) - fix: Kustomize directory analysis not working by [@​majiayu000](https://redirect.github.com/majiayu000) in [kubescape/kubescape#1914](https://redirect.github.com/kubescape/kubescape/pull/1914) - feat: Define labels to copy from workloads to reports by [@​majiayu000](https://redirect.github.com/majiayu000) in [kubescape/kubescape#1915](https://redirect.github.com/kubescape/kubescape/pull/1915) - Add SkipPersistence flag to MetricsQueryParams in metrics endpoint by [@​BroderPeters](https://redirect.github.com/BroderPeters) in [kubescape/kubescape#1917](https://redirect.github.com/kubescape/kubescape/pull/1917) - ci: update scorecard action version by [@​AndrewCharlesHay](https://redirect.github.com/AndrewCharlesHay) in [kubescape/kubescape#1918](https://redirect.github.com/kubescape/kubescape/pull/1918) - update test lists by [@​amirmalka](https://redirect.github.com/amirmalka) in [kubescape/kubescape#1919](https://redirect.github.com/kubescape/kubescape/pull/1919) - build(deps): Bump github.com/sigstore/cosign/v3 from 3.0.3-0.20251208232815-901b44d65952 to 3.0.4 by [@​dependabot](https://redirect.github.com/dependabot)\[bot] in [kubescape/kubescape#1920](https://redirect.github.com/kubescape/kubescape/pull/1920) - Update build number retrieval and permissions in workflow by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/kubescape#1921](https://redirect.github.com/kubescape/kubescape/pull/1921) - Fix workload scan to include allcontrols framework by [@​Copilot](https://redirect.github.com/Copilot) in [kubescape/kubescape#1922](https://redirect.github.com/kubescape/kubescape/pull/1922) - build(deps): Bump github.com/sigstore/fulcio from 1.8.4 to 1.8.5 by [@​dependabot](https://redirect.github.com/dependabot)\[bot] in [kubescape/kubescape#1923](https://redirect.github.com/kubescape/kubescape/pull/1923) - Fix panic on unsafe interface{} to string type assertions by [@​Copilot](https://redirect.github.com/Copilot) in [kubescape/kubescape#1926](https://redirect.github.com/kubescape/kubescape/pull/1926) - build(deps): Bump github.com/theupdateframework/go-tuf/v2 from 2.3.0 to 2.3.1 by [@​dependabot](https://redirect.github.com/dependabot)\[bot] in [kubescape/kubescape#1927](https://redirect.github.com/kubescape/kubescape/pull/1927) - build(deps): Bump github.com/sigstore/rekor from 1.4.3 to 1.5.0 by [@​dependabot](https://redirect.github.com/dependabot)\[bot] in [kubescape/kubescape#1928](https://redirect.github.com/kubescape/kubescape/pull/1928) - <kubescape/operator@v0.2.121...v0.2.126> - bump version by [@​jnathangreeg](https://redirect.github.com/jnathangreeg) in [kubescape/operator#349](https://redirect.github.com/kubescape/operator/pull/349) - Fix comment typo in checkECRRegistry function to clarify \_catalog end… by [@​jnathangreeg](https://redirect.github.com/jnathangreeg) in [kubescape/operator#351](https://redirect.github.com/kubescape/operator/pull/351) - add permissions by [@​bvolovat](https://redirect.github.com/bvolovat) in [kubescape/operator#352](https://redirect.github.com/kubescape/operator/pull/352) - bump github.com/armosec/armoapi-go v0.0.673 by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/operator#353](https://redirect.github.com/kubescape/operator/pull/353) - bump github.com/kubescape/go-logger v0.0.26 by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/operator#354](https://redirect.github.com/kubescape/operator/pull/354) - bump github.com/goradd/maps v1.3.0 by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/operator#355](https://redirect.github.com/kubescape/operator/pull/355) - <kubescape/kubevuln@v0.3.98...v0.3.104> - replace debian 12 with debian 13 when building container images by [@​pfarikrispy](https://redirect.github.com/pfarikrispy) in [kubescape/kubevuln#317](https://redirect.github.com/kubescape/kubevuln/pull/317) - Add comprehensive documentation and governance by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/kubevuln#318](https://redirect.github.com/kubescape/kubevuln/pull/318) - Bump github.com/cilium/cilium from 1.16.9 to 1.16.17 by [@​dependabot](https://redirect.github.com/dependabot)\[bot] in [kubescape/kubevuln#319](https://redirect.github.com/kubescape/kubevuln/pull/319) - Add timeout to Grype DB update with graceful fallback to prevent indefinite readiness probe failures by [@​Copilot](https://redirect.github.com/Copilot) in [kubescape/kubevuln#320](https://redirect.github.com/kubescape/kubevuln/pull/320) - Prevent DB update cancellation on readiness probe by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/kubevuln#321](https://redirect.github.com/kubescape/kubevuln/pull/321) - <kubescape/storage@v0.0.237...v0.0.239> - feat: handle large object storage by clearing spec and updating annotations by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/storage#279](https://redirect.github.com/kubescape/storage/pull/279) - bump k8s version to v0.35.0 by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/storage#280](https://redirect.github.com/kubescape/storage/pull/280) - <kubescape/node-agent@v0.3.11...v0.3.36> - feat: propagate IsTriggerAlert field from rules to runtime alerts by [@​slashben](https://redirect.github.com/slashben) in [kubescape/node-agent#686](https://redirect.github.com/kubescape/node-agent/pull/686) - Generating release by [@​slashben](https://redirect.github.com/slashben) in [kubescape/node-agent#688](https://redirect.github.com/kubescape/node-agent/pull/688) - Feature/rule engine redesign by [@​YakirOren](https://redirect.github.com/YakirOren) in [kubescape/node-agent#685](https://redirect.github.com/kubescape/node-agent/pull/685) - refactor: update cloud metadata types to use armotypes package by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/node-agent#689](https://redirect.github.com/kubescape/node-agent/pull/689) - Replace host sensor with node agent sensing by [@​Bezbran](https://redirect.github.com/Bezbran) in [kubescape/node-agent#681](https://redirect.github.com/kubescape/node-agent/pull/681) - use k8s-interface by [@​Bezbran](https://redirect.github.com/Bezbran) in [kubescape/node-agent#691](https://redirect.github.com/kubescape/node-agent/pull/691) - optimize header parsing and add early return in ruleAppliesToContext by [@​YakirOren](https://redirect.github.com/YakirOren) in [kubescape/node-agent#692](https://redirect.github.com/kubescape/node-agent/pull/692) - improve field accessor retrieval with nil checks and type assertions by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/node-agent#694](https://redirect.github.com/kubescape/node-agent/pull/694) - Bump github.com/sigstore/sigstore from 1.9.5 to 1.10.4 by [@​dependabot](https://redirect.github.com/dependabot)\[bot] in [kubescape/node-agent#696](https://redirect.github.com/kubescape/node-agent/pull/696) - Add Azure ResourceGroup enrichment to CloudMetadata by [@​slashben](https://redirect.github.com/slashben) in [kubescape/node-agent#697](https://redirect.github.com/kubescape/node-agent/pull/697) - Add unit tests for Azure ResourceGroup parsing by [@​slashben](https://redirect.github.com/slashben) in [kubescape/node-agent#698](https://redirect.github.com/kubescape/node-agent/pull/698) - remove toMap function by [@​YakirOren](https://redirect.github.com/YakirOren) in [kubescape/node-agent#693](https://redirect.github.com/kubescape/node-agent/pull/693) - run system test from private repo by [@​bvolovat](https://redirect.github.com/bvolovat) in [kubescape/node-agent#700](https://redirect.github.com/kubescape/node-agent/pull/700) - bump: update golang-set dependency to v2.8.0 by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/node-agent#701](https://redirect.github.com/kubescape/node-agent/pull/701) - bump: update armoapi-go dependency to v0.0.671 by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/node-agent#702](https://redirect.github.com/kubescape/node-agent/pull/702) - update the tests\_groups by [@​bvolovat](https://redirect.github.com/bvolovat) in [kubescape/node-agent#703](https://redirect.github.com/kubescape/node-agent/pull/703) - bump: update dependencies for backend, storage, and OpenAPI packages by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/node-agent#704](https://redirect.github.com/kubescape/node-agent/pull/704) - update chart repo by [@​bvolovat](https://redirect.github.com/bvolovat) in [kubescape/node-agent#705](https://redirect.github.com/kubescape/node-agent/pull/705) - bump: update cel-go dependency to v0.26.1 by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/node-agent#706](https://redirect.github.com/kubescape/node-agent/pull/706) - Implement ClusterUID enrichment for runtime alerts by [@​slashben](https://redirect.github.com/slashben) in [kubescape/node-agent#708](https://redirect.github.com/kubescape/node-agent/pull/708) - fix a bug where failed expressions would recompile on every event by [@​YakirOren](https://redirect.github.com/YakirOren) in [kubescape/node-agent#690](https://redirect.github.com/kubescape/node-agent/pull/690) - fix container watcher error propagation by [@​YakirOren](https://redirect.github.com/YakirOren) in [kubescape/node-agent#709](https://redirect.github.com/kubescape/node-agent/pull/709) - add permissions by [@​bvolovat](https://redirect.github.com/bvolovat) in [kubescape/node-agent#710](https://redirect.github.com/kubescape/node-agent/pull/710) - upgrade to IG v0.48.1 by [@​matthyx](https://redirect.github.com/matthyx) in [kubescape/node-agent#695](https://redirect.github.com/kubescape/node-agent/pull/695) - <kubescape/synchronizer@v0.0.127...v0.0.128> - perf: optimize memory usage by avoiding string-to-byte conversions by [@​amirmalka](https://redirect.github.com/amirmalka) in [kubescape/synchronizer#135](https://redirect.github.com/kubescape/synchronizer/pull/135) #### New Contributors - [@​drew-viles](https://redirect.github.com/drew-viles) made their first contribution in [#​784](https://redirect.github.com/kubescape/helm-charts/pull/784) - [@​YakirOren](https://redirect.github.com/YakirOren) made their first contribution in [#​785](https://redirect.github.com/kubescape/helm-charts/pull/785) - [@​armobot](https://redirect.github.com/armobot) made their first contribution in [#​789](https://redirect.github.com/kubescape/helm-charts/pull/789) - [@​pfarikrispy](https://redirect.github.com/pfarikrispy) made their first contribution in [kubescape/kubevuln#317](https://redirect.github.com/kubescape/kubevuln/pull/317) - [@​bvolovat](https://redirect.github.com/bvolovat) made their first contribution in [kubescape/operator#352](https://redirect.github.com/kubescape/operator/pull/352) - [@​oglok](https://redirect.github.com/oglok) made their first contribution in [kubescape/kubescape#1913](https://redirect.github.com/kubescape/kubescape/pull/1913) - [@​majiayu000](https://redirect.github.com/majiayu000) made their first contribution in [kubescape/kubescape#1914](https://redirect.github.com/kubescape/kubescape/pull/1914) - [@​BroderPeters](https://redirect.github.com/BroderPeters) made their first contribution in [kubescape/kubescape#1917](https://redirect.github.com/kubescape/kubescape/pull/1917) - [@​AndrewCharlesHay](https://redirect.github.com/AndrewCharlesHay) made their first contribution in [kubescape/kubescape#1918](https://redirect.github.com/kubescape/kubescape/pull/1918) - [@​Bezbran](https://redirect.github.com/Bezbran) made their first contribution in [kubescape/node-agent#681](https://redirect.github.com/kubescape/node-agent/pull/681) - [@​bvolovat](https://redirect.github.com/bvolovat) made their first contribution in [kubescape/node-agent#700](https://redirect.github.com/kubescape/node-agent/pull/700) **Full Changelog**: <kubescape/helm-charts@kubescape-operator-1.30.2...kubescape-operator-1.30.3> </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/Darkflame72/home-ops). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0Mi45NS4yIiwidXBkYXRlZEluVmVyIjoiNDIuOTUuMiIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsicmVub3ZhdGUvaGVsbSIsInR5cGUvcGF0Y2giXX0=--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Overview
The
host-scanneris a K8s daemonset which sensing some basic stuff from a K8s node and expose them in a K8s YAML-like format via HTTP handlers and it runs by Kubescape only for the period of Kubescape scanning process.We want to merge host-scanner into node-agent and let the node-agent itself to sense the stuff and send it to K8s API server as new CRDs.
The motivation for this change is well explained in this slack thread
How to Test
As ususal
Related issues/PRs:
kubescape/helm-charts#773
kubescape/kubescape#1916
Summary by CodeRabbit
Release Notes
✏️ Tip: You can customize this high-level summary in your review settings.