void sendToRepeater( String host, int port, boolean useHttps, byte[] request, String tabCaption);
(IRequestInfo iRequestInfo,byte[] request)
| 108 | * String tabCaption); |
| 109 | */ |
| 110 | public static void c_sendToRepeater(IRequestInfo iRequestInfo,byte[] request) { |
| 111 | String host = null; |
| 112 | int port = 0; |
| 113 | List<String> headersList = iRequestInfo.getHeaders(); |
| 114 | |
| 115 | // BurpCallbacks.getInstance().sendToRepeater(); |
| 116 | |
| 117 | // new StandaloneBurpRequestInfo(iRequestInfo.get); |
| 118 | |
| 119 | // if (iRequestInfo.getUrl().toString().contains("https")) |
| 120 | // BurpExtender.usehttps = true; |
| 121 | |
| 122 | for (String header : headersList) { |
| 123 | String[] host_lists = header.split(":",2); |
| 124 | if (host_lists[0].toLowerCase().equals("host")) { |
| 125 | host = headersTohost(host_lists[1]).trim(); |
| 126 | port = headersToport(host_lists[1],BurpExtender.usehttps); |
| 127 | } |
| 128 | } |
| 129 | |
| 130 | BurpExtender.stdout.println(BurpExtender.usehttps); |
| 131 | BurpExtender.callbacks.sendToRepeater( |
| 132 | host, |
| 133 | port, |
| 134 | BurpExtender.usehttps, |
| 135 | request , |
| 136 | "autoDecoder"); |
| 137 | } |
| 138 | |
| 139 | // public void cc_sendToRepeater() { |
| 140 | // BurpCallbacks.getInstance().sendToRepeater(httpMessage); |
no test coverage detected