Enforcing TOTP multi-factor authentication in MISP

A planning guide to making TOTP or HOTP multi-factor authentication mandatory in MISP, covering time sync, service account exemptions, token recovery and how MFA interacts with external SSO.

On this page

Why enforce MFA on a MISP instance that holds shared threat intelligence

A stolen password should not be enough to read, publish or export intelligence from your MISP instance. Enforcing TOTP or HOTP multi-factor authentication adds a second factor to every local login, so an attacker who obtains a username and password still cannot open a session without the user's authenticator device. This matters more on MISP than on many internal tools because an instance often holds unpublished events, sharing group definitions, organisation records and API keys that can pull or push data to partners. Each of those is a route to sensitive material, and a single weak credential can expose all of them.

Teams usually need enforcement when the instance connects to sector communities, when more than a handful of analysts or partner users log in directly, or when a compliance or security review asks how administrative and analyst access is protected. Enforcement is a policy decision on top of the user factor: the instance must be configured so that users without a second factor are prompted to enrol one, and so that the setting cannot be bypassed by ordinary users. Confirm with your MISP version's documentation exactly which settings control this behaviour, since the names and defaults are the authoritative source for your build.

This page covers the configuration itself, the time synchronisation that TOTP depends on, which accounts may be exempted (such as automation and sync users), how a lost token is recovered without weakening the control, whether email one-time codes are an option, and how MFA interacts with an external single sign-on provider. Read these decisions together. An MFA setting that is correct in isolation can still leave a gap if a service account is exempted without a compensating control, or if SSO already enforces a second factor and MISP's local login remains open beside it.

How a MISP login moves through password, token and recovery checks

The login starts in the user's browser and reaches MISP, which checks the password first. If the user has a second factor enrolled and the account is not exempt, MISP asks for a TOTP or HOTP code before granting a session. An external identity provider, if one is configured, sits behind its own boundary, so check which party enforces the second factor and where the recovery path goes through an administrator.

Login decision path with the trust boundary between browser, MISP and the identity provider.

Which MFA option fits which user group

Analysts who log in through the web interface to review events, add attributes and publish intelligence are the group most affected by a mandatory second factor. TOTP is the usual choice because it works offline with a standard authenticator app and does not depend on mail delivery. HOTP uses a counter instead of the clock, so it needs more care to keep counters in step and is rarely the better fit for people. Email OTP depends on the mail path being reliable and on the mailbox itself being protected.

  • TOTP in an authenticator app: the device generates codes locally, so sign-in does not depend on any outside service once enrolment is complete.
  • Clock dependence: the server and the phone must agree on time, so confirm NTP is running on the MISP host before rollout.
  • Email OTP fallback: useful only if the mail relay, its queue and the user's mailbox are all dependable and monitored.
  • Enrolment support: plan who helps users scan a QR code and who verifies identity before a new secret is issued.
  • Recovery path: agree how a user who loses the device regains access without sharing a colleague's account.

Confirm in your installed release which second-factor methods the login flow offers and how users enrol them.

How to turn on mandatory TOTP in MISP

This sequence moves a MISP instance from optional to enforced time-based one-time passwords in controlled stages, so that every interactive user has a working second factor before enforcement reaches the whole user base. Each step ends with a check you can record as evidence.

  1. Confirm release and authentication settings

    Start by confirming which MISP release and branch your instance runs, and that it is on a version the project still supports. The project recommends MISP 2.5 for new deployments and lists MISP 2.4 as end of life with security fixes only, so an instance on 2.4 should be scheduled for upgrade before MFA work begins. Then review the authentication configuration in the administration settings and record the current login method, any external authentication plugin in use, and which accounts exist locally. Done when you have a written inventory of the release, the authentication backend and the local user count, and the change owner has signed off on it.

  2. Verify server time synchronization

    TOTP codes depend on clocks that agree within the tolerance your authenticator app and MISP accept, so the MISP host and any proxy or container host must sync to a trusted time source. Confirm that the operating system time service is running and reports a synchronized state on the MISP web host, worker hosts and the database host, and check that the time zone is set consistently. Also verify that users' phones can sync time automatically. Done when every host reports synchronized time and a test code generated from a known-good authenticator is accepted by a test account in a non-production instance.

  3. Enable the second factor and enforcement

    In the MISP administration interface, enable the TOTP option under the authentication settings, then turn on the setting that requires a second factor for users who have not yet enrolled. Confirm the exact setting names against the release you run, since they can change between versions, and check the release notes before editing production values. Keep an administrator session open and a break-glass administrator account that is documented and tested, so that a misconfiguration cannot lock everyone out. Done when a test user without a token is prompted to enroll and a test user with a token is prompted for a code at login.

  4. Pilot with a small group

    Choose a small group of users from different organizations or roles, including at least one publisher and one site or org administrator, and enable enforcement only for them if your configuration allows per-user or per-role scope. Ask the pilot group to enroll, log in from a fresh browser session, and perform normal actions such as viewing events and publishing an event in a test instance. Record any helpdesk requests, failed codes, clock drift issues and browser or app problems. Done when the pilot group has completed enrollment and login without help from the platform team, and each issue has either a fix or a documented workaround.

  5. Roll out to all users

    Announce the enforcement date to all users with instructions for choosing an authenticator app, scanning the enrollment code and storing recovery material. Enable enforcement for the full user base and monitor the authentication failure log for spikes that suggest enrollment problems, clock issues or misconfiguration. Keep the helpdesk process from the pilot in place and handle lost-token requests through the recovery procedure you have defined, not by disabling MFA for an account. Done when the monitoring shows login failures returning to the normal baseline and every active user has either enrolled or has an open, approved request.

  6. Test enrollment, login and recovery

    Close the rollout by running a written test script against the production configuration: enroll a new test user, log in with a valid code, attempt login with an invalid code, reset a test user's token through the approved recovery path, and confirm that the recovery action itself is recorded in the logs. Also test that service accounts and automation keys behave as your design intends, because API access and interactive MFA are separate paths in MISP. Confirm the audit trail for each test and save the results with the change record. Done when every test has a pass result, the recovery path is documented with its named approvers, and the test evidence is stored where your compliance team can retrieve it.

Why time synchronization decides whether TOTP codes work

A TOTP code is derived from the current time and a shared secret, so the MISP server and the user's authenticator app must agree on the time within the tolerance the verifier accepts. When the server clock drifts, codes it generates or checks no longer match what the phone shows, and the user is rejected at the second factor. The failure is easy to misread. The login form may report invalid credentials or a generic authentication failure, so the team starts resetting passwords and suspecting the user when the real fault is the host's clock.

Check time sync on the MISP host before enforcing MFA, not after the first lockout. On a Linux host, confirm that a time service is active and synchronized, for example by running timedatectl and checking that the system clock is synchronized and that NTP is enabled. Then confirm which source the host uses and that it is reachable from the MISP network segment. If the host runs in a virtual machine or a container platform, confirm with the platform team whether the guest clock is synced to the hypervisor or to NTP, and whether a snapshot restore or live migration could step the clock. Ask the same questions of the database and Redis hosts if they are separate machines, since MISP's own logs and session handling depend on consistent timestamps across the stack.

Also confirm what your users' devices do. Authenticator apps usually sync automatically, but a phone with manual time or a badly configured desktop client can drift on its own. Test enrollment and a login with several real devices from different networks, and record the clock state of each. Keep the time service monitored, so an unsynchronized server raises an alert before users report that codes stopped working. The exact tolerance window and how MISP's TOTP check handles it should be confirmed against the MISP release you run, using the MISP GitHub repository and its documentation.

Handling service accounts, sync users and automation keys under MFA

Enforcing TOTP on interactive logins does not reach API keys, sync users or scheduled jobs, which authenticate without a person present. Each exemption needs a deliberate owner, a narrow permission set and controls that replace the second factor. The cards below cover the decisions that determine whether an exemption stays contained.

Decide which accounts are truly exempt

Separate human accounts from service accounts before enabling enforcement. A service account is one that no person logs into interactively, such as a sync user for a partner or a PyMISP script. List each exempt account with its owner, purpose and the integration that uses it. Anything a person can sign into through the browser should stay under MFA, even if it is shared by a team. Confirm the exemption list against the user table in your instance, not against memory.

Treat API keys as the credential, not the password

An API key authenticates every request without a second factor, so MFA on the account does not protect the key itself. Keys should be scoped to one integration, carry an expiry date and be restricted to the source addresses that legitimately call MISP. Read-only keys suit SIEM pulls and feeds, while write-capable keys need stricter review. Pair this card with the API key security topic before relying on any exemption.

Keep exempt accounts out of admin roles

A service account that can publish events, change organisation settings or manage users turns a leaked key into a platform compromise. Give exempt accounts the narrowest role that the integration needs, and confirm that no exempt account holds site admin or other high-impact permission flags. Review role assignments after each new integration is added. If a sync user must publish, document why and who approved it.

Restrict network paths for automation

Automation accounts should reach MISP only from known hosts, such as the sync server, the SIEM collector or a scheduled job runner. Enforce this with an IP allowlist on the key, a firewall rule on the MISP web tier, or both. Block the same accounts from logging in through the web interface where your configuration allows it, so a key cannot be used as a browser session. Verify the allowlist with a test call from an address outside the list.

Log and review automation activity

Without a second factor, the audit trail is the main evidence of misuse. Ship authentication and access logs for service accounts to your SIEM, and alert on logins from unexpected addresses, bursts of reads, or any write from an account that normally only reads. Record who owns each exempt account so that alerts reach someone who can act on them. Check that log retention meets your internal policy before you rely on it.

Rotate and retire keys on a schedule

Set a rotation procedure for every exempt key and for the partner keys used in sync, with a named owner for each. When an integration is retired, remove its key the same day rather than leaving it dormant. Rotation requires coordination with the partner on the other end of a sync, so plan the change window in advance. Keep a register of keys with owner, scope, expiry and last rotation date.

How MFA behaves when MISP sits behind an external SSO provider

When MISP authenticates users through the OidcAuth plugin, the identity provider, not MISP, is usually the place where MFA should be enforced. The plugin hands the login to an OpenID Connect provider and then maps the identity it receives to a local MISP user. Before turning on TOTP inside MISP, confirm which system owns the second factor for interactive logins. If both systems prompt for a code, users will hit two conflicting challenges, lock themselves out, and file support requests that look like a MISP fault when the cause sits in the provider's policy.

Role mapping deserves the same attention as the factor itself. The OidcAuth plugin maps identity provider roles to MISP roles and assigns the first matching role by priority, so a user who is granted a broader role in the provider receives that MISP role on next login. Review the claim names, the priority order and the default role in the plugin configuration, and test with one account per role. Also decide what happens to local fallback accounts. An emergency admin login that bypasses the provider is useful during an outage, but it must have its own strong factor, be excluded from routine use and be audited, or it becomes the easiest path around the controls you just built.

Ask the provider team a short set of questions before go-live: whether MFA is enforced for every client application or only for MISP, which authentication methods satisfy the policy, how long a session stays valid before a second factor is required again, and what happens to API traffic that does not use an interactive login. Confirm how the provider handles lost devices and who can reset them, because that decision sits outside MISP's own token reset process. Record the answers in the MISP access design so the auditor and the on-call administrator see the same picture.

Security and operational risks to control after enforcement

Turning on mandatory second factors closes one gap and opens others. Fallback logins, recovery paths, shared secrets, incident lockouts and failed-attempt visibility each decide whether MFA holds in practice, so each risk below is paired with a check you can run on your own instance.

Fallback local logins

If MISP still accepts local username and password logins alongside SSO, an attacker or a careless user can sign in without the second factor. Check every enabled authentication path, including any plugin or legacy login route, and confirm that each one enforces the same second factor. Test it with a standard account that has no OTP enrolled and confirm the login is refused. Record the result as evidence for the change.

Weak token recovery

A user who loses an authenticator will ask an administrator to reset it, and that reset is a common route for social engineering. Define who may reset a token, how the requester is verified, and whether the reset is logged and reviewed. Confirm that a reset clears the old secret and forces re-enrollment before the next login.

Shared authenticator secrets

When several people use one account, one authenticator secret is shared among them, so MFA no longer ties an action to a person. Find accounts used by more than one human and by automation, and replace them with named accounts. Service accounts that cannot answer a prompt need a documented exemption path, scoped keys and a separate owner.

Lockouts during incidents

Strict enforcement can block the people who need MISP most during an incident, such as a lost phone during an on-call shift. Agree on a break-glass procedure before go-live, covering who holds it, where it is stored, how it is used and how it is revoked. Test the procedure once in a non-production instance so the first use is not during an incident.

Failed second-factor attempts

Failed OTP attempts are an early signal of password theft or token guessing, and they are only useful if they reach your monitoring. Confirm which authentication failures MISP writes to its logs and whether the entries record the account and source address. Forward them to your SIEM and set an alert threshold that your SOC has agreed to act on.

Time drift on the server

TOTP codes depend on the server clock, so drift can make valid codes fail and push users toward workarounds. Confirm that the MISP host and its supporting services synchronize time from a trusted source and that the drift is monitored. Check that a lockout caused by clock drift is distinguishable from a credential attack in your logs.

Questions teams ask before enforcing MFA in MISP

How much effort does enforcing TOTP in MISP take?

The core change is small: enabling the multi-factor setting and having each user enroll an authenticator app. The effort grows with the surrounding work: confirming how users log in today, deciding which accounts are exempt, testing enrollment and recovery, and telling users what changes. Effort is driven mainly by the number of user groups, the number of automation and sync accounts that need a different path, and whether logins already go through an identity provider. Ask any partner to split the quote into discovery, configuration, testing, user rollout and handover so you can see where the time goes.

What does my internal team need to provide?

Your team needs to supply a named owner who can approve the enforcement policy, access to the MISP admin account and server, a list of user groups and service accounts, and a decision on who can reset a lost token. Someone who understands your time synchronization and directory setup should also be available, because clock drift and identity sources cause most enrollment problems. Plan for a few people to test the flow before the change reaches all users, and keep a support contact for the first days after rollout.

Can we enforce MFA in MISP ourselves?

Yes, if your team already runs MISP, has administrative access, and is comfortable changing authentication settings and testing recovery paths. Most of the risk sits in the decisions rather than the clicks: which accounts stay exempt, how lockouts are handled, and whether the change affects sync or API users. A team that has not run MISP upgrades or configuration changes before may want an outside review of the plan. Either way, record the decisions in writing so the next administrator can follow them.

How does single sign-on change the MFA work?

If users sign in through an external identity provider, MFA is usually enforced there, and MISP's own TOTP setting may not apply to those sessions. Confirm with your identity team whether the provider already requires a second factor for every application, and whether MISP accounts that bypass SSO, such as local admin or break-glass accounts, still need TOTP. The OidcAuth plugin maps provider roles to MISP roles, so review that mapping at the same time. Time and cost rise when the provider, the MISP login paths and the exemptions must be designed together.

How do user count and account types affect cost and time?

More users mean more enrollment support, more recovery requests and more communication, but the configuration itself does not scale much with headcount. Service accounts, sync users and automation keys matter more than raw count, because each needs a decision about whether MFA applies and, if not, how it is protected instead. Ask a partner to state assumptions about user count, number of user groups, number of exempt accounts and whether a staged rollout is included. Quotes that cover those inputs are easier to compare.

Who should be allowed to reset a lost authenticator?

Only a small, named set of administrators should reset tokens, and each reset should follow a documented identity check so an attacker cannot simply ask for one. Decide whether help desk staff can start a reset or only site administrators can complete it, and log every reset. Avoid letting a reset path bypass MFA entirely for regular users. Test the procedure before enforcement, because a locked-out administrator is a common reason for rollout delays.

When does a partner help more than our own team would?

A partner is most useful when the MISP instance feeds a regulated or shared environment, when SSO, directory and sync accounts all interact, or when the internal team has no recent MISP administration experience. A partner can also prepare evidence that your MFA controls are in place for a compliance review, although an independent auditor makes the assessment. DeployOpen plans and implements MISP deployments in infrastructure you control and documents the controls, under a written, fixed scope agreed before work starts. Confirm with any provider exactly which parts of the work they perform and which remain yours.

How DeployOpen scopes and delivers MFA enforcement for MISP

DeployOpen scopes MFA enforcement in writing before any change is made to your MISP instance. The scope names the MISP version and deployment method in use, the authentication path (local accounts, OidcAuth or another external provider), the user groups that must enroll, the service accounts and sync users to be exempted, and the people allowed to reset a lost token. Each exemption is listed with a reason and an owner, so the boundary is reviewed rather than inherited from whoever last edited the configuration. The written scope also states what is out of scope, such as changes to your identity provider's own MFA policy, so both teams know where responsibility sits.

Testing covers the paths that most often fail in production. DeployOpen checks enrollment for a new user, login with a correct and an incorrect code, clock skew on the application server, the behavior of exempted automation accounts and API keys, and the recovery flow when a user loses a device. Where the instance uses an external identity provider through the OidcAuth plugin, testing also confirms which factor is enforced at which layer, so users are not asked for two prompts without a reason or, worse, for none. Any gap found is reported with the steps to reproduce it, the fix, and a retest. Confirm with your own team which exemptions your sync and automation workflows truly need, and which version of the MISP documentation applies to your release before the test plan is signed off.

The procedures delivered at handover are written for your administrators and help desk. They cover enrolling a user, resetting a token through the approved route, checking server time, rotating exempted credentials, and what to do when the enforcement itself locks out an administrator. DeployOpen also documents evidence you can show an auditor, such as the configuration snapshot, test results and change record. Ongoing work is available as a retainer, which can cover upgrades, re-testing after MISP releases and reviews of exemptions as users and integrations change. Ask any partner, including DeployOpen, for the written scope, the test plan, the handover documents and the retainer terms before you compare quotes, because those four items determine what you actually receive.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.