(IHttpRequestResponse basePair, IScannerInsertionPoint insertionPoint, String payload, long sleeptime)
| 129 | } |
| 130 | |
| 131 | private Pair<Long, IHttpRequestResponse> _attack(IHttpRequestResponse basePair, IScannerInsertionPoint insertionPoint, String payload, long sleeptime) { |
| 132 | payload = payload.replace("$time", String.valueOf(sleeptime/1000)); |
| 133 | long timer = System.currentTimeMillis(); |
| 134 | IHttpRequestResponse attack = callbacks.makeHttpRequest(basePair.getHttpService(), insertionPoint.buildRequest(payload.getBytes())); |
| 135 | timer = (System.currentTimeMillis() - timer); |
| 136 | Utilities.log("Response time: " + timer + "| Payload: " + payload); |
| 137 | |
| 138 | List<int[]> requestHighlights = Collections.singletonList(insertionPoint.getPayloadOffsets(payload.getBytes())); |
| 139 | attack = callbacks.applyMarkers(attack, requestHighlights, null); |
| 140 | |
| 141 | return new ImmutablePair<>(timer, attack); |
| 142 | } |
| 143 | } |
no test coverage detected