Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 22 Feb 2024 08:06:45 +0000
From:      bugzilla-noreply@freebsd.org
To:        jail@FreeBSD.org
Subject:   [Bug 277210] jail(8): exec.clean retrieves PWD from user info (can cause services to crash on jail start-up)
Message-ID:  <bug-277210-29815-Sj5YtnJKiv@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-277210-29815@https.bugs.freebsd.org/bugzilla/>
References:  <bug-277210-29815@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D277210

--- Comment #7 from Michael Osipov <michaelo@FreeBSD.org> ---
>From jail(8):


       exec.clean
               Run commands in a clean environment.  The environment  is  d=
is-
               carded  except  for HOME, SHELL, TERM and USER.  HOME and SH=
ELL
               are set to the target login's default values.  USER is  set =
 to
               the  target  login.  TERM is imported from the current envir=
on-
               ment.  The environment variables from the login class  capab=
il-
               ity database for the target login are also set.

I completely miss the chdir(2) here with PWD. That is the first one to be f=
ixed
even if it gets reverted because it is not documented.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-277210-29815-Sj5YtnJKiv>