public TOTPGenerator.Mode getMode() throws GuacamoleException {

        // Do not reveal TOTP mode unless enrollment is in progress
        if (key == null)
            return null;

        return confService.getMode();

    }
Returns the mode that TOTP code generation is operating in. This value
will be one of "SHA1", "SHA256", or "SHA512". If the user's key is not
being exposed to facilitate enrollment, this value will not be exposed
either.

@return
    The mode that TOTP code generation is operating in, such as "SHA1",
    "SHA256", or "SHA512", or null if the user's key is not being
    exposed to facilitate enrollment.

@throws GuacamoleException
    If the TOTP mode cannot be read from guacamole.properties.
extensions/guacamole-auth-totp/src/main/java/org/apache/guacamole/auth/totp/form/AuthenticationCodeField.java