Fix SecurityManager patch