pyjfuzz/core/pjf_server.py
def serve(self):
        """
        Serve fuzzed JSON object
        """
        try:
            fuzzed = self.json.fuzzed
            if self.config.fuzz_web:
                self.client_queue.put((request.environ.get('REMOTE_ADDR'), fuzzed))
            response.headers.append("Access-Control-Allow-Origin", "*")
            response.headers.append("Accept-Encoding", "identity")
            response.headers.append("Content-Type", self.config.content_type)
            if self.config.notify:
                PJFTestcaseServer.send_testcase(fuzzed, '127.0.0.1', self.config.ports["servers"]["TCASE_PORT"])
            yield fuzzed
        except Exception as e:
            raise PJFBaseException(e.message if hasattr(e, "message") else str(e))
def serve(self):
        """
        Serve fuzzed JSON object
        """
        try:
            fuzzed = self.json.fuzzed
            if self.config.fuzz_web:
                self.client_queue.put((request.environ.get('REMOTE_ADDR'), fuzzed))
            response.headers.append("Access-Control-Allow-Origin", "*")
            response.headers.append("Accept-Encoding", "identity")
            response.headers.append("Content-Type", self.config.content_type)
            if self.config.notify:
                PJFTestcaseServer.send_testcase(fuzzed, '127.0.0.1', self.config.ports["servers"]["TCASE_PORT"])
            yield fuzzed
        except Exception as e:
            raise PJFBaseException(e.message if hasattr(e, "message") else str(e))
Serve fuzzed JSON object