Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug Report: Unhandled exception "UnboundLocalError: cannot access local variable 'tmp_path' where it is not associated with a value" (#6d0944ad) #1001

Open
commixreporter opened this issue Mar 5, 2025 · 0 comments

Comments

@commixreporter
Copy link

Commix version: 4.0-dev#115
Python version: 3.13.2
Operating system: posix
Command line: commix.py --wizard

Traceback (most recent call last):
  File \"handler.py", line 557, in do_results_based_proccess
    response = checks.get_response(output)
  File \"checks.py", line 131, in get_response
    response = _urllib.request.urlopen(request, timeout=settings.TIMEOUT)
  File \"request.py", line 189, in urlopen
    return opener.open(url, data, timeout)
           ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^
  File \"request.py", line 495, in open
    response = meth(req, response)
  File \"request.py", line 604, in http_response
    response = self.parent.error(
        'http', request, response, code, msg, hdrs)
  File \"request.py", line 533, in error
    return self._call_chain(*args)
           ~~~~~~~~~~~~~~~~^^^^^^^
  File \"request.py", line 466, in _call_chain
    result = func(*args)
  File \"request.py", line 613, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 404: Not Found

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File \"commix.py", line 36, in <module>
    main()
    ~~~~^^
  File \"commix.py", line 31, in main
    import src.core.main
  File \"main.py", line 902, in <module>
    main(filename, url, http_request_method)
    ~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"main.py", line 560, in main
    controller.do_check(url, http_request_method, filename)
    ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"controller.py", line 743, in do_check
    perform_checks(url, http_request_method, filename)
    ~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"controller.py", line 706, in perform_checks
    data_checks(url, http_request_method, filename, timesec)
    ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"controller.py", line 623, in data_checks
    if post_request(url, http_request_method, filename, timesec) is None:
       ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"controller.py", line 613, in post_request
    do_injection(found_parameter, settings.HTTPMETHOD.POST, header_name, url, http_request_method, filename, timesec)
    ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"controller.py", line 576, in do_injection
    injection_proccess(url, check_parameter, http_request_method, filename, timesec)
    ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"controller.py", line 403, in injection_proccess
    filebased_command_injection_technique(url, timesec, filename, http_request_method, url_time_response)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"controller.py", line 272, in filebased_command_injection_technique
    if fb_handler.exploitation(url, timesec, filename, http_request_method, url_time_response, injection_type, technique) != False:
       ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"fb_handler.py", line 33, in exploitation
    return fb_injection_handler(url, timesec, filename, http_request_method, url_time_response, injection_type, technique)
  File \"fb_handler.py", line 26, in fb_injection_handler
    return handler.do_results_based_proccess(url, timesec, filename, http_request_method, injection_type, technique)
           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File \"handler.py", line 586, in do_results_based_proccess
    checks.use_temp_folder(no_result, url, timesec, filename, tmp_path, http_request_method, url_time_response)
                                                              ^^^^^^^^
UnboundLocalError: cannot access local variable 'tmp_path' where it is not associated with a value
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant