Server : Apache/2.4.18 (Ubuntu) System : Linux canvaswebdesign 3.13.0-71-generic #114-Ubuntu SMP Tue Dec 1 02:34:22 UTC 2015 x86_64 User : oppastar ( 1041) PHP Version : 7.0.33-0ubuntu0.16.04.15 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, Directory : /usr/share/nmap/scripts/ |
Upload File : |
local rtsp = require "rtsp" local shortport = require "shortport" local stdnse = require "stdnse" description = [[ Determines which methods are supported by the RTSP (real time streaming protocol) server. ]] --- -- @usage -- nmap -p 554 --script rtsp-methods <ip> -- -- @output -- PORT STATE SERVICE -- 554/tcp open rtsp -- | rtsp-methods: -- |_ DESCRIBE, SETUP, PLAY, TEARDOWN, OPTIONS -- -- @xmloutput -- <elem>DESCRIBE</elem> -- <elem>SETUP</elem> -- <elem>PLAY</elem> -- <elem>TEARDOWN</elem> -- <elem>OPTIONS</elem> -- -- @args rtsp-methods.path the path to query, defaults to "*" which queries -- the server itself, rather than a specific url. -- -- -- Version 0.1 -- Created 23/10/2011 - v0.1 - created by Patrik Karlsson <patrik@cqure.net> -- author = "Patrik Karlsson" license = "Same as Nmap--See https://nmap.org/book/man-legal.html" categories = {"default", "safe"} portrule = shortport.port_or_service(554, "rtsp", "tcp", "open") action = function(host, port) local path = stdnse.get_script_args('rtsp-methods.path') or '*' local helper = rtsp.Helper:new(host, port) local status = helper:connect() if ( not(status) ) then stdnse.debug2("ERROR: Failed to connect to RTSP server") return end local response status, response = helper:options(path) helper:close() if ( status ) then local opts = response.headers['Public'] return stdnse.strsplit(",%s*", opts), opts end end