Module: Ronin::Vulns::URLScanner
- Defined in:
- lib/ronin/vulns/url_scanner.rb
Overview
Class Method Summary collapse
-
.scan(url, lfi: {}, rfi: {}, sqli: {}, ssti: {}, reflected_xss: {}, open_redirect: {}, command_injection: {}, **kwargs) {|vuln| ... } ⇒ Array<LFI, RFI, SQLI, SSTI, ReflectedXSS, OpenRedirect>
Scans a URL for web vulnerabilities.
-
.test(url, **kwargs) ⇒ LFI, ...
Tests the URL for a Web vulnerability and returns the first found vulnerability.
Class Method Details
.scan(url, lfi: {}, rfi: {}, sqli: {}, ssti: {}, reflected_xss: {}, open_redirect: {}, command_injection: {}, **kwargs) {|vuln| ... } ⇒ Array<LFI, RFI, SQLI, SSTI, ReflectedXSS, OpenRedirect>
Scans a URL for web vulnerabilities.
The HTTP request mehtod for each request.
175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 |
# File 'lib/ronin/vulns/url_scanner.rb', line 175 def self.scan(url, lfi: {}, rfi: {}, sqli: {}, ssti: {}, reflected_xss: {}, open_redirect: {}, command_injection: {}, **kwargs, &block) vulns = [] if lfi vulns.concat(LFI.scan(url,**kwargs,**lfi,&block)) end if rfi vulns.concat(RFI.scan(url,**kwargs,**rfi,&block)) end if sqli vulns.concat(SQLI.scan(url,**kwargs,**sqli,&block)) end if ssti vulns.concat(SSTI.scan(url,**kwargs,**ssti,&block)) end if reflected_xss vulns.concat(ReflectedXSS.scan(url,**kwargs,**reflected_xss,&block)) end if open_redirect vulns.concat(OpenRedirect.scan(url,**kwargs,**open_redirect,&block)) end if command_injection vulns.concat(CommandInjection.scan(url,**kwargs,**command_injection,&block)) end return vulns end |
.test(url, **kwargs) ⇒ LFI, ...
Tests the URL for a Web vulnerability and returns the first found vulnerability.
231 232 233 234 235 236 237 |
# File 'lib/ronin/vulns/url_scanner.rb', line 231 def self.test(url,**kwargs) scan(url,**kwargs) do |vuln| return vuln end return nil end |