docs: public static <T> T doAs(final Subject subject, final java.security.PrivilegedAction<T> action) {
        Stack<Subject> stack = SUBJECT.get();
        if (stack == null) {
           stack = new Stack<>();
           SUBJECT.set(stack);
        }
        stack.push(subject);
        try {
           return action.run();
        } finally {
           stack.pop();
           if (stack.isEmpty()) {
              SUBJECT.remove();
           }
        }
     }