What it does
An organisation owner or admin can require every member to hold an active second factor and can bound how old that proof may be. The policy is evaluated whenever a platform session is issued or renewed, so a member without a factor cannot hold a session until they enrol.
How it works
The policy is a versioned record for each organisation. GET /admin/v1/orgs/:id/security reads it and PUT on the same path changes it. A write names the version it read, and a stale write is refused with a conflict. The fields are require_mfa_for_all_members, max_mfa_age_secs and a list of JWKS endpoint URLs. The allowed age of an MFA proof is between 60 seconds and 24 hours and defaults to 12 hours. Organisation owners and admins can change the policy, and so can a super_admin.
When a platform account signs in with a password, a code or OAuth, the server loads the policy of each organisation the account belongs to. If one requires MFA and the account has no active factor, no tokens are issued and the response is an enrolment challenge flagged org_mfa_required. An account that has a factor completes the normal TOTP step, and the session records when MFA was verified.
A renewal re-evaluates every policy. It is refused when the policy version, the membership set or the factor state changed since the session was issued, or when the proof is older than the allowed age. The engine repository has tests for switching the mandate on or off, removing a member and disabling a factor while a renewal is in flight.
Where you reach it
- HTTP
GET /admin/v1/orgs/:id/security - HTTP
PUT /admin/v1/orgs/:id/security
Example
# Read the current policy first to learn its version
curl -s "$KYNETRA_URL/admin/v1/orgs/$ORG_ID/security" \
-H "Authorization: Bearer $ACCESS_TOKEN"
# Require a second factor, and accept an MFA proof for up to 12 hours
curl -s -X PUT "$KYNETRA_URL/admin/v1/orgs/$ORG_ID/security" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{"require_mfa_for_all_members": true, "max_mfa_age_secs": 43200, "expected_version": 0}'Limits
- The mandate applies to platform accounts that are members of the organisation. It does not apply to project end users, service keys, the global API key or managed tokens.
- The policy record also stores JWKS endpoint URLs and shows a single-sign-on status field. Both are configuration metadata. Nothing fetches the URLs, no single-sign-on provider can be configured through this route, and neither affects authentication. SAML and OpenID Connect single sign-on are not available.
- The audit entry for a policy change names a generic actor, not the individual administrator.
Evidence
- On this siteSecurity overview
- Tests39 control-plane tests in the server, including the mandate blocking sign-in until a factor is active, the MFA-age boundary, refresh fencing when policy, membership or factor state changes, and policy records that fail closed when corrupt
Test coverage is listed as present in the engine repository at this edition. This page does not report test results.
KynetraDB is in private preview
Request a preview to try this against your own workload.