`get_required_permissions` may be a better name for the function.