Comment by wslh
Yes, a non-secure way of sandboxing is/was to hook OS functions. Hooking is used still today to modify the behaviour of existing apps and testing apps under custom virtual environments.
We develop on of this that it us used in this Microsoft product[1].
[1] https://learn.microsoft.com/en-us/fslogix/overview-what-is-f...