Adds an Api Token controller

This commit is contained in:
erwanlr
2019-07-18 17:40:27 +01:00
parent 3f70ddaffa
commit d05ad0f8f4
4 changed files with 45 additions and 0 deletions

View File

@@ -1,6 +1,7 @@
# frozen_string_literal: true
require_relative 'controllers/core'
require_relative 'controllers/api_token'
require_relative 'controllers/custom_directories'
require_relative 'controllers/wp_version'
require_relative 'controllers/main_theme'

View File

@@ -0,0 +1,19 @@
# frozen_string_literal: true
module WPScan
module Controller
# Controller to handle the API token
class ApiToken < CMSScanner::Controller::Base
def cli_options
[
OptString.new(['--api-token TOKEN', 'The API Token to display vulnerability data'])
]
end
def before_scan(opts = {})
# TODO, validate the token
# res = browser.get()
end
end
end
end