From 3f16a2099238891b8cd59607e0fd3703677eeff7 Mon Sep 17 00:00:00 2001 From: Ophestra Date: Sat, 11 Oct 2025 20:15:53 +0900 Subject: [PATCH] internal/app/spcontainer: resolve path through dispatcher This prevents state from os tainting the test data. Signed-off-by: Ophestra --- internal/app/spcontainer.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/internal/app/spcontainer.go b/internal/app/spcontainer.go index 62c4f4f..247b798 100644 --- a/internal/app/spcontainer.go +++ b/internal/app/spcontainer.go @@ -139,7 +139,12 @@ func (s *spFilesystemOp) toSystem(state *outcomeStateSys) error { varRunNscd, } - _, systemBusAddr := dbus.Address() + // dbus.Address does not go through syscallDispatcher + systemBusAddr := dbus.FallbackSystemBusAddress + if addr, ok := state.k.lookupEnv(dbus.SystemBusAddress); ok { + systemBusAddr = addr + } + if entries, err := dbus.Parse([]byte(systemBusAddr)); err != nil { return &hst.AppError{Step: "parse dbus address", Err: err} } else {