Add Msf endpoint API doc

GSoC/Meterpreter_Web_Console
James Barnett 2018-05-03 17:16:04 -05:00
parent 40c978e040
commit a5b9cc8cb8
No known key found for this signature in database
GPG Key ID: 647983861A4EC5EA
3 changed files with 23 additions and 0 deletions

View File

@ -0,0 +1,20 @@
require 'swagger/blocks'
module MsfApiDoc
include Swagger::Blocks
swagger_path '/api/v1/msf' do
# Swagger documentation for /api/v1/msf GET
operation :get do
key :description, 'Return the current version of the running Metasploit Framework.'
key :tags, [ 'msf' ]
response 200 do
key :description, 'Returns the Metasploit Framework version.'
schema do
property :metasploit_version, type: :string
end
end
end
end
end

View File

@ -28,6 +28,7 @@ module RootApiDoc
tag name: 'exploit', description: 'Exploit operations.'
tag name: 'host', description: 'Host operations.'
tag name: 'loot', description: 'Loot operations.'
tag name: 'msf', description: 'Utility operations around Metasploit Framework.'
tag name: 'nmap', description: 'Nmap operations.'
tag name: 'note', description: 'Note operations.'
tag name: 'service', description: 'Service operations.'

View File

@ -6,6 +6,7 @@ load 'documentation/api/v1/event_api_doc.rb'
load 'documentation/api/v1/exploit_api_doc.rb'
load 'documentation/api/v1/host_api_doc.rb'
load 'documentation/api/v1/loot_api_doc.rb'
load 'documentation/api/v1/msf_api_doc.rb'
load 'documentation/api/v1/nmap_api_doc.rb'
load 'documentation/api/v1/note_api_doc.rb'
load 'documentation/api/v1/service_api_doc.rb'
@ -46,6 +47,7 @@ module ApiDocsServlet
ExploitApiDoc,
HostApiDoc,
LootApiDoc,
MsfApiDoc,
NmapApiDoc,
NoteApiDoc,
ServiceApiDoc,