Working with the security question#

For the Confirmation by answering a security question method to appear on the Second factor tab in the authentication methods, you must add the secQsn method to the blitz.prod.local.idp.login -> factors block:

"login" : {
    "factors" : [
        [
            …
        ],
        [
            {
                "enabled" : false,
                "method" : "secQsn"
            },
            …
        ]
    ],
    …
}

To create a dictionary of security questions, do the following:

  1. Create a /etc/blitz-config/custom_messages/dics directory on the server;

  2. Create a /etc/blitz-config/custom_messages/dics/securityQuestions file with the dictionary. File example:

    01=What is your mother's maiden name?
    02=What is your grandmother's maiden name?
    03=What was the first movie you saw in the cinema?
    04=What is your favorite literary work?
    05=What was the name of your third grade teacher
    06=The first dish you learned to cook
    07=What was the name of your first pet
    08=What did you want to become as a child?
    09=What was the name of the first school you went to?
    10=What was the name of the first street where you lived as a child?
    

    The number in the dictionary is used to sort out the security question list upon display.

  3. Check the owner of the dics directory and the dictionary files in it. The owner must be blitz:blitz.

    chown -R blitz:blitz /etc/blitz-config/custom_messages/dics
    
  4. In the blitz.conf configuration file, add the dics block to the blitz.prod.local.idp.messages block. In the names setting, specify the dictionary name securityQuestions. For example:

    "dics" : {
        "dir" : "custom_messages/dics",
        "names" : [
            "securityQuestions"
        ]
    }