You are here

function tfa_basic_menu in TFA Basic plugins 7

Implements hook_menu().

File

./tfa_basic.module, line 53

Code

function tfa_basic_menu() {
  $items = array();
  $items['user/%user/security/tfa'] = array(
    'title' => 'Security',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'tfa_basic_overview',
      1,
    ),
    'access callback' => 'tfa_basic_setup_access',
    'access arguments' => array(
      1,
      'setup own tfa',
    ),
    'type' => MENU_LOCAL_TASK,
    'file' => 'tfa_basic.pages.inc',
  );
  $items['user/%user/security/tfa/disable'] = array(
    'title' => 'TFA disable',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'tfa_basic_disable_form',
      1,
    ),
    'access callback' => 'tfa_basic_setup_access',
    'access arguments' => array(
      1,
      'setup own tfa',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'tfa_basic.pages.inc',
  );
  $items['user/%user/security/tfa/app-setup'] = array(
    'title' => 'TFA setup',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'tfa_basic_setup_form',
      1,
      'tfa_basic_totp',
    ),
    'access callback' => 'tfa_basic_setup_access',
    'access arguments' => array(
      1,
      'setup own tfa',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'tfa_basic.pages.inc',
  );
  $items['user/%user/security/tfa/trusted-browsers'] = array(
    'title' => 'TFA setup',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'tfa_basic_setup_form',
      1,
      'tfa_basic_trusted_browser',
    ),
    'access callback' => 'tfa_basic_setup_access',
    'access arguments' => array(
      1,
      'setup own tfa',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'tfa_basic.pages.inc',
  );
  $items['user/%user/security/tfa/recovery-codes'] = array(
    'title' => 'TFA setup',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'tfa_basic_setup_form',
      1,
      'tfa_basic_recovery_code',
    ),
    'access callback' => 'tfa_basic_setup_access',
    'access arguments' => array(
      1,
      'setup own tfa',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'tfa_basic.pages.inc',
  );
  $items['user/%user/security/tfa/recovery-codes-list'] = array(
    'title' => 'TFA - Unused recovery codes',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'tfa_basic_setup_form',
      1,
      'recovery_codes_list',
    ),
    'access callback' => 'tfa_basic_setup_access',
    'access arguments' => array(
      1,
      'setup own tfa',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'tfa_basic.pages.inc',
  );
  $items['user/%user/security/tfa/sms-setup'] = array(
    'title' => 'TFA setup',
    'page callback' => 'drupal_get_form',
    'page arguments' => array(
      'tfa_basic_setup_form',
      1,
      'tfa_basic_sms',
    ),
    'access callback' => 'tfa_basic_setup_access',
    'access arguments' => array(
      1,
      'setup own tfa',
    ),
    'type' => MENU_CALLBACK,
    'file' => 'tfa_basic.pages.inc',
  );
  return $items;
}