(self, url)
| 114 | await self.emit_event(new_event) |
| 115 | |
| 116 | def construct_command(self, url): |
| 117 | # base executable |
| 118 | command = ["wpscan", "--url", url] |
| 119 | # proxy |
| 120 | if self.proxy: |
| 121 | command += ["--proxy", str(self.proxy)] |
| 122 | # user agent |
| 123 | command += ["--user-agent", f"'{self.scan.useragent}'"] |
| 124 | # threads |
| 125 | command += ["--max-threads", str(self.threads)] |
| 126 | # request timeout |
| 127 | command += ["--request-timeout", str(self.request_timeout)] |
| 128 | # connection timeout |
| 129 | command += ["--connect-timeout", str(self.connection_timeout)] |
| 130 | # api key |
| 131 | if self.api_key: |
| 132 | command += ["--api-token", f"{self.api_key}"] |
| 133 | # enumerate |
| 134 | command += ["--enumerate", self.enumerate] |
| 135 | # disable tls checks |
| 136 | if self.disable_tls_checks: |
| 137 | command += ["--disable-tls-checks"] |
| 138 | # force |
| 139 | if self.force: |
| 140 | command += ["--force"] |
| 141 | # output format |
| 142 | command += ["--format", "json"] |
| 143 | return command |
| 144 | |
| 145 | def parse_wpscan_output(self, output, base_url, source_event): |
| 146 | json_output = json.loads(output) |
no outgoing calls
no test coverage detected