(IRequestInfo iRequestInfo,byte[] request)
| 141 | // } |
| 142 | |
| 143 | public static void c_sendToIntruder(IRequestInfo iRequestInfo,byte[] request) { |
| 144 | String host = null; |
| 145 | int port = 0; |
| 146 | List<String> headersList = iRequestInfo.getHeaders(); |
| 147 | // if (iRequestInfo.getUrl().getProtocol().contains("https")) |
| 148 | // BurpExtender.usehttps = true; |
| 149 | for (String header : headersList) { |
| 150 | String[] host_lists = header.split(":",2); |
| 151 | if (host_lists[0].toLowerCase().equals("host")) { |
| 152 | host = headersTohost(host_lists[1]).trim(); |
| 153 | port = headersToport(host_lists[1],BurpExtender.usehttps); |
| 154 | } |
| 155 | } |
| 156 | BurpExtender.callbacks.sendToIntruder( |
| 157 | host, |
| 158 | port, |
| 159 | BurpExtender.usehttps, |
| 160 | request ); |
| 161 | } |
| 162 | |
| 163 | public static String headersTohost(String hostport){ |
| 164 | String host = ""; |
no test coverage detected