path: root/pseudo.1
AgeCommit message (Collapse)AuthorFilesLines
2011-11-02Rework the clone wrapper to add an intermediate function to resolve a defect.Mark Hatle1-7/+0
Previously the clone(2) wrapper unconditionallity restored the system environment. It also invokes the checks to see if the user has requested pseudo to be disabled or unloaded. Due to the semantics of clone, this caused both the parent and child processes to be disabled or unloaded. The new code adds an intermediate function, wrap_clone_child, that only runs within the child context. This way we can be sure to only disable/unload pseudo from within the child process. In addition, we avoid mucking with the environment if CLONE_VM is set, since this will affect both parent and child. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
2011-11-02Implement PSEUDO_UNLOAD, replacing existing PSEUDO_RELOADED semantics.Mark Hatle1-11/+28
Change from internal PSEUDO_RELOADED to external PSEUDO_UNLOAD environment variable. Enable external programs to have a safe and reliable way to unload pseudo on the next exec*. PSEUDO_UNLOAD also will disable pseudo if we're in a fork/clone situation in the same way PSEUDO_DISABLED=1 would. Rename the PSEUDO_DISABLED tests, and create a similar set for the new PSEUDO_UNLOAD. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
2011-03-25Merge in ports workPeter Seebach1-2/+9
This is a spiffied-up rebase of a bunch of intermediate changes, presented as a whole because it is, surprisingly, less confusing that way. The basic idea is to separate the guts code into categories ranging from generic stuff that can be the same everywhere and specific variants. The big scary one is the Darwin support, which actually seems to run okay on 64-bit OS X 10.6. (No other variants were tested.) The other example given is support for the old clone() syscall on RHEL 4, which affects some wrlinux use cases. There's a few minor cleanup bits here, such as a function with inconsistent calling conventions, but nothing really exciting.
2010-12-07This is a merge of several commits from a tree which turned out toPeter Seebach1-0/+10
be out of sync in a very inconvenient way. Changes include: * Some whitespace fixes, also move the pseudo_variables definition into pseudo_util.c since it's not used anywhere else. * Further improvements in the fork() support: We now recognize both positive and negative forms of PSEUDO_DISABLED, so we can distinguish between "it was removed from the environment by env -i" (restore the old value) and "it was intentionally turned off" (the new value wins). * clone(2) support. This is a little primitive, and programs might still fail horribly due to clone's semantics, but at least it's there and passes easy test cases. Plus a big patch from Mark Hatle: Cleanup fork/clone and PSEUDO_DISABLED guts/fork.c: * cleanup function and make it more robust * be sure to call pseudo_setupenv prior to pseudo_client_reset to match exec behavior pseudo_wrappers.c: * fix mismatched type in execl_to_v call via typecast * Simplify fork call via single call to wrap_fork() * be sure to save pseudo_disabled * be sure to call pseudo_setupenv prior to pseudo_client_reset to match exec behavior tests: * Add a test of whether pseudo can be disabled/enabled on a fork. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
2010-11-17First pass of some cleanups -- support moving a tracked directory fromPeter Seebach1-1/+84
one device to another, for instance.
2010-08-11Document new variables.Peter Seebach1-0/+27
2010-06-21Add mkstemp64(). Also, check in the man page for the NOSYMLINKEXPPeter Seebach1-0/+12
2010-04-30Improve PSEUDO_DEBUG_FILE.Peter Seebach1-4/+13
The PSEUDO_DEBUG_FILE feature is enhanced, and is now also used by the pseudo server.
2010-04-30Miscellaneous cleanup.Peter Seebach1-1/+1
Address a couple of compiler warnings, add a couple of signals to the list of caught signals, etcetera.
2010-04-27Document PSEUDO_DEBUG_FILE.Peter Seebach1-0/+11
2010-04-26Add sanity checkPeter Seebach1-1/+13
It is possible for the database to get out of sync with the filesystem. Detecting this after the fact can be hard. Provide a hook for requesting a check. Also merge in some LD_LIBRARY_PATH fixes.
2010-03-29Add password/group call emulation.Peter Seebach1-0/+17
This is a first pass at handling password/group calls, allowing the use of custom password/group files. In particular, when chroot()ed to a particular directory, pseudo picks files in that directory by default, to improve support for the typical use case where pseudo uses chroot() only to jump into a virtual target filesystem.
2010-03-25initial chroot() supportPeter Seebach1-0/+26
Add chroot() and a large number of things needed to make it work. The list of intercepted calls is large but not exhaustive.
2010-03-17Add -h option to pseudo.Peter Seebach1-1/+10
Add the -h (help) option to pseudo, and document -h for both pseudo and pseudolog.
2010-03-16initial public releasePeter Seebach1-0/+353