We are running untrusted user code in a JVM with a security manager installed. That untrusted code should be able to use the Jackson libraries, and some operations in those libraries require the accessDeclaredMembers runtime permission.
I don't want to grant that permission to the untrusted code directly. If all access to Jackson was through wrapper classes we provide, I could use a doPrivileged block... but I am trying to avoid creating such wrappers.
Is there a good design that would allow the untrusted code to (indirectly) execute an operation that requires the privilege if and only if the operation is called from a Jackson class?
Thanks! Franck