Skip to content

Commit

Permalink
FuzzerStopOnStatusCode200
Browse files Browse the repository at this point in the history
  • Loading branch information
jtommi authored Jun 1, 2020
1 parent a279a17 commit 201195b
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions httpfuzzerprocessor/FuzzerStopOnStatusCode200
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
/**
* Processes the fuzzed message (payloads already injected).
*
* Called before forwarding the message to the server.
*
* @param {HttpFuzzerTaskProcessorUtils} utils - A utility object that contains functions that ease common tasks.
* @param {HttpMessage} message - The fuzzed message, that will be forward to the server.
*/
function processMessage(utils, message) {
}

/**
* Processes the fuzz result.
*
* Called after receiving the fuzzed message from the server.
*
* @param {HttpFuzzerTaskProcessorUtils} utils - A utility object that contains functions that ease common tasks.
* @param {HttpFuzzResult} fuzzResult - The result of sending the fuzzed message.
* @return {boolean} Whether the result should be accepted, or discarded and not shown.
*/
function processResult(utils, fuzzResult){
if (fuzzResult.getHttpMessage().getResponseHeader().getStatusCode() == 200)
utils.stopFuzzer();
return true;
}

0 comments on commit 201195b

Please sign in to comment.