PLSysSec / rlbox

RLBox sandboxing framework
https://rlbox.dev
MIT License
287 stars 21 forks source link

don't unregister callbacks automatically #24

Open deian opened 4 years ago

deian commented 4 years ago

In prio, we ran into a really awkward thing to debug:

tainted_prio<PrioNSSCtx*> nss = sandbox.malloc_in_sandbox<PrioNSSCtx>()
...
nss->NSS_IsInitialized = sandbox.register_callback(t_NSS_IsInitialized);  

eneded up getting unregister at the end of the function call.

We probably want to just manually do the unregistering and have a separate type for automatically unregistering callbacks.