Require 2FA for Group missing from API
Description
Its possible to require all members of a given group to set up 2 factor authentication. This is a Good Thing.
However there doesn't appear to be any way to configure (or even view) this setting via the API.
Proposal
Add "require_two_factor_authentication" and "two_factor_grace_period" to the groups API.
Overview
What is it?
Minor addition to the API to enable per-group two factor authentication settings to be accessed.
Why should someone use this feature?
So that the settings can be modified and verified by an automated process.
What is the underlying (business) problem?
We have a requirement to enforce 2fa for all administrators, but its extra overhead we don't require for general users. This seems like the simplest way that we could enforce this setting.
How do you use this feature?
curl -X POST --header 'PRIVATE-TOKEN: foo' --data 'require_two_factor_authentication=true' 'https://host/api/v4/groups/:id'
Feature checklist
Make sure these are completed before closing the issue, with a link to the relevant commit.
-
Feature assurance -
Documentation -
Added to features.yml