Error During User Import: "MFA import error: String does not match pattern ^[A-Z2-7]+$: MFA_CODE_SUPPLIED"

Problem statement

While most users have been able to import successfully, a few users are getting this error when attempting to import:

MFA import error: String does not match pattern ^[A-Z2-7]+$: MFA_CODE_SUPPLIED

What is the reason for this error and how can it be resolved for these users?


This regex ^[A-Z2-7]+$ doesn’t have a-z in the range, only A-Z (capitalized). For MFA secrets being migrated that are in all lower-case this will cause the error message to be thrown.


Before importing these users, capitalize the MFA secret to pass this regex validation.

previous example secret:


expected format for secret during import: