I’m using CiviCRM plugin, which requires a cron job set up, which gets a https page with the username and password appended on to it. Specifically, the cron job executes the following
php ~/www/www/wp-content/plugins/civicrm/civicrm/bin/cli.php -u username -p password -e Job -a execute
When the 2FA plugin is switched off, it works perfectly. When it’s switched on, I get the following (I’ve made some redactions for security):
Fatal error: Uncaught Error: Call to a member function get_option() on null in /***Path***/www/www/wp-content/plugins/two-factor-authentication/includes/class-simba-tfa.php:526
#0 /***Path***/www/www/wp-content/plugins/two-factor-authentication/includes/class-simba-tfa.php(350): Simba_TFA->isActivatedForUser(‘5’)
#1 /***Path***/www/www/wp-content/plugins/two-factor-authentication/two-factor-login.php(332): Simba_TFA->authUserFromLogin(Array, false)
#2 /***Path***/www/www/wp-includes/class-wp-hook.php(286): Simba_Two_Factor_Authentication->tfaVerifyCodeAndUser(Object(WP_User), ‘***Username***’, ‘***Password***’)
#3 /***Path***/www/www/wp-includes/plugin.php(208): WP_Hook->apply_filters(Object(WP_User), Array)
#4 /***Path***/www/www/wp-includes/pluggable.php(539): apply_filters(‘authenticate’, NULL, ‘***Username***’, ‘***Password***’)
#5 /***Path***/www/www/wp-content/plugins/civicrm/civicrm/CRM/Utils/System/WordPress.php(348): wp_authenticate(‘***Username***’, ‘***Password***’)
# in /***Path***/www/www/wp-content/plugins/two-factor-authentication/includes/class-simba-tfa.php on line 526
But 2FA is not a requirement of the WordPress user being invoked, nor it is a requirement for the role of that user.
Can anyone advise?
- The topic ‘Cron Job being blocked by 2FA’ is closed to new replies.