Hi
Im getting this error from the web interface when trying to review reports.
It happens for part of the reports and not to all
the HTTP respons is 500 305067
`
NoReverseMatch at /analysis/40/
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'_VLMCS._TCP'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9-.]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
Request Method: GET
Request URL: http://192.168.4.129:8000/analysis/40/
Django Version: 1.8.4
Exception Type: NoReverseMatch
Exception Value:
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'_VLMCS._TCP'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9-.]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
Exception Location: /usr/local/lib/python2.7/dist-packages/django/core/urlresolvers.py in _reverse_with_prefix, line 496
Python Executable: /usr/bin/python
Python Version: 2.7.10
Python Path:
['/opt/cuckoo/web',
'/usr/local/lib/python2.7/dist-packages/volatility-2.5-py2.7.egg',
'/usr/lib/python2.7',
'/usr/lib/python2.7/plat-x86_64-linux-gnu',
'/usr/lib/python2.7/lib-tk',
'/usr/lib/python2.7/lib-old',
'/usr/lib/python2.7/lib-dynload',
'/usr/local/lib/python2.7/dist-packages',
'/usr/lib/python2.7/dist-packages',
'/usr/lib/python2.7/dist-packages/PILcompat',
'/usr/lib/python2.7/dist-packages/ubuntu-sso-client',
'/opt/cuckoo/web/..',
'/opt/cuckoo/',
'/opt/cuckoo/',
'/opt/cuckoo/',
'/opt/cuckoo/',
'/opt/cuckoo/']
Server time: Wed, 17 Feb 2016 17:00:36 +0200
Error during template rendering
In template /opt/cuckoo/web/templates/analysis/network/_dns.html, error at line 14
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'_VLMCS._TCP'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9-.]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
4 {% if analysis.network.dns %}
5
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'_VLMCS._TCP'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d\.]+)?/(?P[a-zA-Z0-9-\.]+)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P\d+)?']
The reporting module "ReportHTML" returned the following error: Failed to generate HTML report: 'ascii' codec can't decode byte 0xe2 in position 4: ordinal not in range(128)
And following error as -
NoReverseMatch at /analysis/18/
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user\u2019s MacBook Pro._ssh.tcp.local'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9-.]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user\u2019s MacBook Pro._ssh.tcp.local'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9-.]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
Exception Location: /usr/local/lib/python2.7/dist-packages/django/core/urlresolvers.py in _reverse_with_prefix, line 496
Python Executable: /usr/bin/python
Python Version: 2.7.6
Python Path:
Your traceback shows that you didn't apply the commit, see also the (?P[a-zA-Z0-9-\.]+)? part.
Not sure if just that will do the trick for you though, as you you have some Unicode character in the host as well (\u2019http://unicode.org/cldr/utility/character.jsp?a=2019).
The ReportHTML bug is probably a different error which I can only resolve if you share the entire analysis.
Tried to analyze a pdf file, 2 packages gave 2 different errors (pdf, app):
ERROR: Analysis failed: Unable to import package "pdf": it does not exist.
2016-06-26 07:13:56,127 [root] DEBUG: Starting analyzer from /private/var/root/fohmswrq
2016-06-26 07:13:56,127 [root] DEBUG: Storing results at: /tmp/oghYuckEx
2016-06-26 07:13:56,135 [root] ERROR: Traceback (most recent call last):
File "/var/root/fohmswrq/analyzer.py", line 150, in
success = analyzer.run()
File "/var/root/fohmswrq/analyzer.py", line 48, in run
package = self._setup_analysis_package()
File "/var/root/fohmswrq/analyzer.py", line 82, in _setup_analysis_package
self.config.file_name, _kwargs)
File "/private/var/root/fohmswrq/lib/core/packages.py", line 31, in choose_package_class
"exist.".format(name))
Exception: Unable to import package "pdf": it does not exist.
Traceback (most recent call last):
File "/var/root/fohmswrq/analyzer.py", line 150, in
success = analyzer.run()
File "/var/root/fohmswrq/analyzer.py", line 48, in run
package = self._setup_analysis_package()
File "/var/root/fohmswrq/analyzer.py", line 82, in _setup_analysis_package
self.config.file_name, _kwargs)
File "/private/var/root/fohmswrq/lib/core/packages.py", line 31, in choose_package_class
"exist.".format(name))
Exception: Unable to import package "pdf": it does not exist.
ERROR: Analysis failed: [Errno 20] Not a directory: '/tmp/0a3ad66e274bdeca2398db94cd5b869bc0934982e93e6d6e3090c17f5ed3a37a.pdf/Contents/Info.plist'
2016-06-26 07:13:56,281 [root] DEBUG: Starting analyzer from /private/var/root/gjtcosnwf
2016-06-26 07:13:56,282 [root] DEBUG: Storing results at: /tmp/nBfhFKjUvs
2016-06-28 14:06:28,521 [root] ERROR: Traceback (most recent call last):
File "/var/root/gjtcosnwf/analyzer.py", line 150, in
success = analyzer.run()
File "/var/root/gjtcosnwf/analyzer.py", line 52, in run
self._analysis(package)
File "/var/root/gjtcosnwf/analyzer.py", line 93, in _analysis
package.start()
File "/private/var/root/gjtcosnwf/lib/core/packages.py", line 92, in start
self.prepare()
File "/private/var/root/gjtcosnwf/modules/packages/app.py", line 16, in prepare
info = readPlist(path.join(self.target, "Contents", "Info.plist"))
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 75, in readPlist
pathOrFile = open(pathOrFile)
IOError: [Errno 20] Not a directory: '/tmp/0a3ad66e274bdeca2398db94cd5b869bc0934982e93e6d6e3090c17f5ed3a37a.pdf/Contents/Info.plist'
Traceback (most recent call last):
File "/var/root/gjtcosnwf/analyzer.py", line 150, in
success = analyzer.run()
File "/var/root/gjtcosnwf/analyzer.py", line 52, in run
self._analysis(package)
File "/var/root/gjtcosnwf/analyzer.py", line 93, in _analysis
package.start()
File "/private/var/root/gjtcosnwf/lib/core/packages.py", line 92, in start
self.prepare()
File "/private/var/root/gjtcosnwf/modules/packages/app.py", line 16, in prepare
info = readPlist(path.join(self.target, "Contents", "Info.plist"))
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 75, in readPlist
pathOrFile = open(pathOrFile)
IOError: [Errno 20] Not a directory: '/tmp/0a3ad66e274bdeca2398db94cd5b869bc0934982e93e6d6e3090c17f5ed3a37a.pdf/Contents/Info.plist'
In template /home/cuckoo/cuckoo/web/templates/dashboard/index.html, error at line 0
Reverse for 'dashboard.views.index' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
1 {% extends "base.html" %}
2 {% load staticfiles %}
3 {% block content %}
4
5 Estimating ~{{report.estimate_hour}} analysis per hour, {{report.estimate_day}} per day.
6
7
8
9
10
Traceback Switch to copy-and-paste view
/usr/local/lib/python2.7/dist-packages/django/core/handlers/exception.py in inner
response = get_response(request)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py in _legacy_get_response
response = self._get_response(request)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py in _get_response
response = self.process_exception_by_middleware(e, request)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/views/decorators/http.py in inner
return func(request, *args, **kwargs)
...
▶ Local vars
/home/cuckoo/cuckoo/web/dashboard/views.py in index
"report": report,
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/shortcuts.py in render
content = loader.render_to_string(template_name, context, request, using=using)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/loader.py in render_to_string
return template.render(context, request)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/backends/django.py in render
return self.template.render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render
return self._render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in _render
return self.nodelist.render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render
bit = node.render_annotated(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render_annotated
return self.render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/loader_tags.py in render
return compiled_parent._render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in _render
return self.nodelist.render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render
bit = node.render_annotated(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render_annotated
return self.render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/loader_tags.py in render
return template.render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render
return self._render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in _render
return self.nodelist.render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render
bit = node.render_annotated(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/base.py in render_annotated
return self.render(context)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py in render
url = reverse(view_name, args=args, kwargs=kwargs, current_app=current_app)
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/urls/base.py in reverse
return force_text(iri_to_uri(resolver._reverse_with_prefix(view, prefix, *args, **kwargs)))
...
▶ Local vars
/usr/local/lib/python2.7/dist-packages/django/urls/resolvers.py in _reverse_with_prefix
(lookup_view_s, args, kwargs, len(patterns), patterns)
...
▶ Local vars
You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard page generated by the handler for this status code.
Template error:
In template /opt/cuckoo/web/templates/analysis/network/_dns.html, error at line 14
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user-VirtualBox [08:00:27:d7:67:46]._workstation.tcp.local'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d\.]+)?/(?P[ a-zA-Z0-9-\.]+)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P\d+)?']
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user-VirtualBox [08:00:27:d7:67:46]._workstation.tcp.local'}' not found. 2 pattern(s) tried: ['analysis/moloch/(?P[\d\.]+)?/(?P[ a-zA-Z0-9-\.]+)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P\d+)?', 'analysis/moloch']
What is a problem with string '{u'host': u'user-VirtualBox [08:00:27:d7:67:46]._workstation.tcp.local'} and regex match string (?P[\d\.]+)?/(?P[ a-zA-Z0-9-\.]+)?
@jbremer @alonlavian help needed, stuck here , is it problem with string match. I also see folloing error message in cuckoo log
2017-04-10 19:36:08,840 [lib.cuckoo.core.guest] INFO: Starting analysis on guest (id=ubuntu1504-64, ip=192.168.56.101)
2017-04-10 19:38:16,518 [lib.cuckoo.core.guest] INFO: ubuntu1504-64: analysis completed successfully
2017-04-10 19:38:16,631 [lib.cuckoo.core.plugins] WARNING: Unable to stop auxiliary module: Potential error while running tcpdump, did not expect the following standard error output: 'dropped privs to root'.
2017-04-10 19:38:27,280 [modules.machinery.virtualbox] INFO: Successfully generated memory dump for virtual machine with label ubuntu1504-64 to path /opt/cuckoo/storage/analyses/5/memory.dmp
2017-04-10 19:38:42,189 [lib.cuckoo.core.scheduler] INFO: Task #5: reports generation completed (path=/opt/cuckoo/storage/analyses/5)
2017-04-10 19:38:43,736 [lib.cuckoo.core.scheduler] INFO: Task #5: analysis procedure completed
Hi Im getting this error from the web interface when trying to review reports. It happens for part of the reports and not to all
the HTTP respons is 500 305067
`
NoReverseMatch at /analysis/40/ Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'_VLMCS._TCP'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9-.]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
Request Method: GET
Request URL: http://192.168.4.129:8000/analysis/40/
Django Version: 1.8.4
Exception Type: NoReverseMatch
Exception Value:[\d.]+)?/(?P[a-zA-Z0-9-.]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
Exception Location: /usr/local/lib/python2.7/dist-packages/django/core/urlresolvers.py in _reverse_with_prefix, line 496
Python Executable: /usr/bin/python
Python Version: 2.7.10
Python Path:
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'_VLMCS._TCP'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P
['/opt/cuckoo/web', '/usr/local/lib/python2.7/dist-packages/volatility-2.5-py2.7.egg', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages/PILcompat', '/usr/lib/python2.7/dist-packages/ubuntu-sso-client', '/opt/cuckoo/web/..', '/opt/cuckoo/', '/opt/cuckoo/', '/opt/cuckoo/', '/opt/cuckoo/', '/opt/cuckoo/'] Server time: Wed, 17 Feb 2016 17:00:36 +0200 Error during template rendering
In template /opt/cuckoo/web/templates/analysis/network/_dns.html, error at line 14 Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'_VLMCS._TCP'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9-.]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
4 {% if analysis.network.dns %}
5
6
7 Name
8 Response
9 Post-Analysis Lookup
10
11 {% for p in analysis.network.dns %}
12
13
14
16
17 {% for a in p.answers %}
18 {% if a.type == "A" %}
19 <a target="_blank" href="{% url "analysis.views.moloch" ip=a.data %}">
20 {{a.type}} {{a.data|linebreaksbr}}
21
22 {% if not forloop.last %}
jbremer
commented
8 years ago
gadd1
commented
8 years ago
jbremer
commented
8 years ago
gadd1
commented
8 years ago
jbremer
commented
8 years ago
anandmpandit
commented
8 years ago
jbremer
commented
8 years ago
alonlavian
commented
8 years ago
jbremer
commented
8 years ago
jbremer
commented
8 years ago
alonlavian
commented
8 years ago
jbremer
commented
8 years ago
alonlavian
commented
8 years ago
jbremer
commented
8 years ago
alonlavian
commented
8 years ago
jbremer
commented
8 years ago
russiancoder
commented
8 years ago
5 Estimating ~{{report.estimate_hour}} analysis per hour, {{report.estimate_day}} per day.
6
7
9
10
Traceback Switch to copy-and-paste view
doomedraven
commented
8 years ago
jbremer
commented
8 years ago
anandmpandit
commented
7 years ago
Name
Response
Post-Analysis Lookup
- response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/views/decorators/http.py" in inner
- return func(request, *args, **kwargs)
File "/opt/cuckoo/web/analysis/views.py" in report
- "latest_version": LATEST_HTTPREPLAY,
File "/usr/local/lib/python2.7/dist-packages/django/shortcuts.py" in render
- template_name, context, request=request, using=using)
File "/usr/local/lib/python2.7/dist-packages/django/template/loader.py" in render_to_string
- return template.render(context, request)
File "/usr/local/lib/python2.7/dist-packages/django/template/backends/django.py" in render
- return self.template.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- return self._render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in _render
- return self.nodelist.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- bit = self.render_node(node, context)
File "/usr/local/lib/python2.7/dist-packages/django/template/debug.py" in render_node
- return node.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/loader_tags.py" in render
- return compiled_parent._render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in _render
- return self.nodelist.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- bit = self.render_node(node, context)
File "/usr/local/lib/python2.7/dist-packages/django/template/debug.py" in render_node
- return node.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py" in render
- output = self.nodelist.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- bit = self.render_node(node, context)
File "/usr/local/lib/python2.7/dist-packages/django/template/debug.py" in render_node
- return node.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/loader_tags.py" in render
- result = block.nodelist.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- bit = self.render_node(node, context)
File "/usr/local/lib/python2.7/dist-packages/django/template/debug.py" in render_node
- return node.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/loader_tags.py" in render
- return template.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- return self._render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in _render
- return self.nodelist.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- bit = self.render_node(node, context)
File "/usr/local/lib/python2.7/dist-packages/django/template/debug.py" in render_node
- return node.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/loader_tags.py" in render
- return template.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- return self._render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in _render
- return self.nodelist.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- bit = self.render_node(node, context)
File "/usr/local/lib/python2.7/dist-packages/django/template/debug.py" in render_node
- return node.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py" in render
- return nodelist.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/base.py" in render
- bit = self.render_node(node, context)
File "/usr/local/lib/python2.7/dist-packages/django/template/debug.py" in render_node
- return node.render(context)
File "/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py" in render
- nodelist.append(node.render(context))
File "/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py" in render
- six.reraise(*exc_info)
File "/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py" in render
- url = reverse(view_name, args=args, kwargs=kwargs, current_app=current_app)
File "/usr/local/lib/python2.7/dist-packages/django/core/urlresolvers.py" in reverse
- return force_text(iri_to_uri(resolver._reverse_with_prefix(view, prefix, *args, **kwargs)))
File "/usr/local/lib/python2.7/dist-packages/django/core/urlresolvers.py" in _reverse_with_prefix
- (lookup_view_s, args, kwargs, len(patterns), patterns))
anandmpandit
commented
7 years ago
anandmpandit
commented
7 years ago
anandmpandit
commented
7 years ago
- © Githubissues.
- Githubissues is a development platform for aggregating issues.
<a target="_blank" href=" {% url "analysis.views.moloch" host=p.request %} ">{{p.request}}
15
{% endif %} 23 {% elif a.type == "CNAME" %} 24 <a target="_blank" href="{% url "analysis.views.moloch" host=a.data %}"> `
Please upgrade to the latest development version. This has been fixed since the
2.0-rc1
release ;-)this is the version im using installed it yesterday :)
Your exception mentions
The patch added the underscore to the
(?P[a-zA-Z0-9-\.]+)?
part, see also #748. You can manually apply this commit (https://github.com/cuckoosandbox/cuckoo/commit/9c704f50e70227ed21ae1b79ba90540c3087fc57) or upgrade to the latest version :-)cool, it worked! thanks for the very quick help :) sorry for my confusion
You're welcome ;-)
I am getting error message as below in cuckoo log
The reporting module "ReportHTML" returned the following error: Failed to generate HTML report: 'ascii' codec can't decode byte 0xe2 in position 4: ordinal not in range(128)
And following error as -
NoReverseMatch at /analysis/18/
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user\u2019s MacBook Pro._ssh.tcp.local'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9- .]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
Request Method: GET Request URL: http://localhost:8000/analysis/18/ Django Version: 1.8.4 Exception Type: NoReverseMatch Exception Value:
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user\u2019s MacBook Pro._ssh.tcp.local'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9- .]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
Exception Location: /usr/local/lib/python2.7/dist-packages/django/core/urlresolvers.py in _reverse_with_prefix, line 496 Python Executable: /usr/bin/python Python Version: 2.7.6 Python Path:
['/opt/cuckoo/cuckoo/web', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages/PILcompat', '/usr/lib/python2.7/dist-packages/gtk-2.0', '/usr/lib/pymodules/python2.7', '/usr/lib/python2.7/dist-packages/ubuntu-sso-client', '/opt/cuckoo/cuckoo/web/..', '/opt/cuckoo/cuckoo/', '/opt/cuckoo/cuckoo/', '/opt/cuckoo/cuckoo/', '/opt/cuckoo/cuckoo/', '/opt/cuckoo/cuckoo/']
Server time: Wed, 18 May 2016 20:41:20 +0530
I have added your changes suggested in the commit https://github.com/cuckoosandbox/cuckoo/commit/9c704f50e70227ed21ae1b79ba90540c3087fc57 , but still i am encountering the errors while generating report.
Your traceback shows that you didn't apply the commit, see also the
(?P[a-zA-Z0-9-\.]+)?
part. Not sure if just that will do the trick for you though, as you you have some Unicode character in thehost
as well (\u2019
http://unicode.org/cldr/utility/character.jsp?a=2019). TheReportHTML
bug is probably a different error which I can only resolve if you share the entire analysis.Hi,
I have the patch but still getting the same error:
File "/usr/local/lib/python2.7/dist-packages/django/template/defaulttags.py", line 493, in render url = reverse(view_name, args=args, kwargs=kwargs, current_app=current_app) File "/usr/local/lib/python2.7/dist-packages/django/core/urlresolvers.py", line 579, in reverse return force_text(iri_to_uri(resolver._reverse_with_prefix(view, prefix, _args, *_kwargs))) File "/usr/local/lib/python2.7/dist-packages/django/core/urlresolvers.py", line 496, in _reverse_with_prefix (lookup_view_s, args, kwargs, len(patterns), patterns)) NoReverseMatch: Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'iMac 5495837449197396002._device-info.tcp.local'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d.]+)?/(?P[a-zA-Z0-9- .]+)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?/(?P\d+)?']
[28/Jun/2016 12:45:02] "GET /analysis/7/ HTTP/1.1" 500 503187
A whitespace, interesting.. will add it right away - thanks.
@alonlavian could you please verify that the following patch works for you?
Thanks, that solved it.
BTW I'm trying to run with OS X guest and getting: "Analysis failed: Could not find an appropriate analysis package"
Should I open an issue on this? I see that you support osx but maybe it's my setup can you advise?
Thanks. For OS X it might be best to pass along a package, i.e.,
app
,bash
,macho
, orzip
. Let me know if that works :)Tried to analyze a pdf file, 2 packages gave 2 different errors (pdf, app):
ERROR: Analysis failed: Unable to import package "pdf": it does not exist.
2016-06-26 07:13:56,127 [root] DEBUG: Starting analyzer from /private/var/root/fohmswrq 2016-06-26 07:13:56,127 [root] DEBUG: Storing results at: /tmp/oghYuckEx 2016-06-26 07:13:56,135 [root] ERROR: Traceback (most recent call last): File "/var/root/fohmswrq/analyzer.py", line 150, in
success = analyzer.run()
File "/var/root/fohmswrq/analyzer.py", line 48, in run
package = self._setup_analysis_package()
File "/var/root/fohmswrq/analyzer.py", line 82, in _setup_analysis_package
self.config.file_name, _kwargs)
File "/private/var/root/fohmswrq/lib/core/packages.py", line 31, in choose_package_class
"exist.".format(name))
Exception: Unable to import package "pdf": it does not exist.
Traceback (most recent call last):
File "/var/root/fohmswrq/analyzer.py", line 150, in
success = analyzer.run()
File "/var/root/fohmswrq/analyzer.py", line 48, in run
package = self._setup_analysis_package()
File "/var/root/fohmswrq/analyzer.py", line 82, in _setup_analysis_package
self.config.file_name, _kwargs)
File "/private/var/root/fohmswrq/lib/core/packages.py", line 31, in choose_package_class
"exist.".format(name))
Exception: Unable to import package "pdf": it does not exist.
ERROR: Analysis failed: [Errno 20] Not a directory: '/tmp/0a3ad66e274bdeca2398db94cd5b869bc0934982e93e6d6e3090c17f5ed3a37a.pdf/Contents/Info.plist'
2016-06-26 07:13:56,281 [root] DEBUG: Starting analyzer from /private/var/root/gjtcosnwf 2016-06-26 07:13:56,282 [root] DEBUG: Storing results at: /tmp/nBfhFKjUvs 2016-06-28 14:06:28,521 [root] ERROR: Traceback (most recent call last): File "/var/root/gjtcosnwf/analyzer.py", line 150, in
success = analyzer.run()
File "/var/root/gjtcosnwf/analyzer.py", line 52, in run
self._analysis(package)
File "/var/root/gjtcosnwf/analyzer.py", line 93, in _analysis
package.start()
File "/private/var/root/gjtcosnwf/lib/core/packages.py", line 92, in start
self.prepare()
File "/private/var/root/gjtcosnwf/modules/packages/app.py", line 16, in prepare
info = readPlist(path.join(self.target, "Contents", "Info.plist"))
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 75, in readPlist
pathOrFile = open(pathOrFile)
IOError: [Errno 20] Not a directory: '/tmp/0a3ad66e274bdeca2398db94cd5b869bc0934982e93e6d6e3090c17f5ed3a37a.pdf/Contents/Info.plist'
Traceback (most recent call last):
File "/var/root/gjtcosnwf/analyzer.py", line 150, in
success = analyzer.run()
File "/var/root/gjtcosnwf/analyzer.py", line 52, in run
self._analysis(package)
File "/var/root/gjtcosnwf/analyzer.py", line 93, in _analysis
package.start()
File "/private/var/root/gjtcosnwf/lib/core/packages.py", line 92, in start
self.prepare()
File "/private/var/root/gjtcosnwf/modules/packages/app.py", line 16, in prepare
info = readPlist(path.join(self.target, "Contents", "Info.plist"))
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plistlib.py", line 75, in readPlist
pathOrFile = open(pathOrFile)
IOError: [Errno 20] Not a directory: '/tmp/0a3ad66e274bdeca2398db94cd5b869bc0934982e93e6d6e3090c17f5ed3a37a.pdf/Contents/Info.plist'
Well, it's not an App, and there's currently no PDF analysis package for OS X. Feel free to add one ;-)
I sure will try. Can you give me direction to documentation, etc. on how to make packages?
Just take a look in the following directory https://github.com/cuckoosandbox/cuckoo/tree/master/analyzer/darwin/modules/packages ;-)
Hello. I am getting similar erros to the ones mentioned above.
NoReverseMatch at /
Reverse for 'dashboard.views.index' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
Request Method: GET Request URL: http://localhost:8080/ Django Version: 1.10 Exception Type: NoReverseMatch Exception Value:
Reverse for 'dashboard.views.index' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
Exception Location: /usr/local/lib/python2.7/dist-packages/django/urls/resolvers.py in _reverse_with_prefix, line 389 Python Executable: /usr/bin/python Python Version: 2.7.12 Python Path:
['/home/cuckoo/cuckoo/web/..', '/home/cuckoo/cuckoo/web/..', '/home/cuckoo/cuckoo/web/..', '/home/cuckoo/cuckoo/web/..', '/home/cuckoo/cuckoo/web/..', '/home/cuckoo/cuckoo/web/..', '/home/cuckoo/cuckoo/web', '/usr/local/lib/python2.7/dist-packages/volatility-2.4-py2.7.egg', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages']
Server time: Mon, 22 Aug 2016 02:08:18 -0700
rror during template rendering
In template /home/cuckoo/cuckoo/web/templates/dashboard/index.html, error at line 0 Reverse for 'dashboard.views.index' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: [] 1 {% extends "base.html" %} 2 {% load staticfiles %} 3 {% block content %} 4
8
Request information USER
AnonymousUser GET
No GET data POST
No POST data FILES
No FILES data COOKIES
No cookie data META Variable Value CONTENT_LENGTH
''
CONTENT_TYPE
'text/plain'
DISPLAY
':0'
DJANGO_SETTINGS_MODULE
'web.settings'
GATEWAY_INTERFACE
'CGI/1.1'
HOME
'/root'
HTTP_ACCEPT
'text/html,application/xhtml+xml,application/xml;q=0.9,/;q=0.8'
HTTP_ACCEPT_ENCODING
'gzip, deflate'
HTTP_ACCEPT_LANGUAGE
'en-US,en;q=0.5'
HTTP_CACHE_CONTROL
'max-age=0'
HTTP_CONNECTION
'keep-alive'
HTTP_HOST
'localhost:8080'
HTTP_UPGRADE_INSECURE_REQUESTS
'1'
HTTP_USER_AGENT
'Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:48.0) Gecko/20100101 Firefox/48.0'
LANG
'en_US.UTF-8'
LANGUAGE
'en_US'
LESSCLOSE
'/usr/bin/lesspipe %s %s'
LESSOPEN
'| /usr/bin/lesspipe %s'
LOGNAME
'root'
LS_COLORS
'rs=0:di=01;34:ln=01;36:mh=00:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=00:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=34;42:st=37;44:ex=01;32:.tar=01;31:.tgz=01;31:.arc=01;31:.arj=01;31:.taz=01;31:.lha=01;31:.lz4=01;31:.lzh=01;31:.lzma=01;31:.tlz=01;31:.txz=01;31:.tzo=01;31:.t7z=01;31:.zip=01;31:.z=01;31:.Z=01;31:.dz=01;31:.gz=01;31:.lrz=01;31:.lz=01;31:.lzo=01;31:.xz=01;31:.bz2=01;31:.bz=01;31:.tbz=01;31:.tbz2=01;31:.tz=01;31:.deb=01;31:.rpm=01;31:.jar=01;31:.war=01;31:.ear=01;31:.sar=01;31:.rar=01;31:.alz=01;31:.ace=01;31:.zoo=01;31:.cpio=01;31:.7z=01;31:.rz=01;31:.cab=01;31:.jpg=01;35:.jpeg=01;35:.gif=01;35:.bmp=01;35:.pbm=01;35:.pgm=01;35:.ppm=01;35:.tga=01;35:.xbm=01;35:.xpm=01;35:.tif=01;35:.tiff=01;35:.png=01;35:.svg=01;35:.svgz=01;35:.mng=01;35:.pcx=01;35:.mov=01;35:.mpg=01;35:.mpeg=01;35:.m2v=01;35:.mkv=01;35:.webm=01;35:.ogm=01;35:.mp4=01;35:.m4v=01;35:.mp4v=01;35:.vob=01;35:.qt=01;35:.nuv=01;35:.wmv=01;35:.asf=01;35:.rm=01;35:.rmvb=01;35:.flc=01;35:.avi=01;35:.fli=01;35:.flv=01;35:.gl=01;35:.dl=01;35:.xcf=01;35:.xwd=01;35:.yuv=01;35:.cgm=01;35:.emf=01;35:.ogv=01;35:.ogx=01;35:.aac=00;36:.au=00;36:.flac=00;36:.m4a=00;36:.mid=00;36:.midi=00;36:.mka=00;36:.mp3=00;36:.mpc=00;36:.ogg=00;36:.ra=00;36:.wav=00;36:.oga=00;36:.opus=00;36:.spx=00;36:.xspf=00;36:'
MAIL
'/var/mail/root'
OLDPWD
'/home/cuckoo/cuckoo/web/web'
PATH
'/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games'
PATH_INFO
u'/'
PWD
'/home/cuckoo/cuckoo/web'
QUERY_STRING
''
REMOTE_ADDR
'127.0.0.1'
REMOTE_HOST
''
REQUEST_METHOD
'GET'
RUN_MAIN
'true'
SCRIPT_NAME
u''
SERVER_NAME
'ubuntu'
SERVER_PORT
'8080'
SERVER_PROTOCOL
'HTTP/1.1'
SERVER_SOFTWARE
'WSGIServer/0.1 Python/2.7.12'
SHELL
'/bin/bash'
SHLVL
'1'
SUDO_COMMAND
'/bin/su'
SUDO_GID
'1000'
SUDO_UID
'1000'
SUDO_USER
'dellsec'
TERM
'xterm-256color'
USER
'root'
USERNAME
'root'
XAUTHORITY
'/home/dellsec/.Xauthority'
_
'/usr/bin/python'
wsgi.errors
<open file '', mode 'w' at 0x7f8907e4b1e0>
wsgi.file_wrapper
''
wsgi.input
<socket._fileobject object at 0x7f88eda14f50>
wsgi.multiprocess
False
wsgi.multithread
True
wsgi.run_once
False
wsgi.url_scheme
'http'
wsgi.version
(1, 0)
Settings Using settings module web.settings Setting Value ABSOLUTE_URL_OVERRIDES
{}
ADMINS
()
ALLOWED_HOSTS
['*']
APPEND_SLASH
True
AUTHENTICATION_BACKENDS
[u'django.contrib.auth.backends.ModelBackend']
AUTH_PASSWORD_VALIDATORS
u'****'
AUTH_USER_MODEL
u'auth.User'
CACHES
{u'default': {u'BACKEND': u'django.core.cache.backends.locmem.LocMemCache'}}
CACHE_MIDDLEWARE_ALIAS
u'default'
CACHE_MIDDLEWARE_KEY_PREFIX
u'****'
CACHE_MIDDLEWARE_SECONDS
600
CSRF_COOKIE_AGE
31449600
CSRF_COOKIE_DOMAIN
None
CSRF_COOKIE_HTTPONLY
False
CSRF_COOKIE_NAME
u'csrftoken'
CSRF_COOKIE_PATH
u'/'
CSRF_COOKIE_SECURE
False
CSRF_FAILURE_VIEW
u'django.views.csrf.csrf_failure'
CSRF_HEADER_NAME
u'HTTP_X_CSRFTOKEN'
CSRF_TRUSTED_ORIGINS
[]
CUCKOO_PATH
'/home/cuckoo/cuckoo/web/..'
DATABASES
{}
DATABASE_ROUTERS
[]
DATA_UPLOAD_MAX_MEMORY_SIZE
2621440
DATA_UPLOAD_MAX_NUMBER_FIELDS
1000
DATETIME_FORMAT
u'N j, Y, P'
DATETIME_INPUT_FORMATS
[u'%Y-%m-%d %H:%M:%S', u'%Y-%m-%d %H:%M:%S.%f', u'%Y-%m-%d %H:%M', u'%Y-%m-%d', u'%m/%d/%Y %H:%M:%S', u'%m/%d/%Y %H:%M:%S.%f', u'%m/%d/%Y %H:%M', u'%m/%d/%Y', u'%m/%d/%y %H:%M:%S', u'%m/%d/%y %H:%M:%S.%f', u'%m/%d/%y %H:%M', u'%m/%d/%y']
DATE_FORMAT
u'N j, Y'
DATE_INPUT_FORMATS
[u'%Y-%m-%d', u'%m/%d/%Y', u'%m/%d/%y', u'%b %d %Y', u'%b %d, %Y', u'%d %b %Y', u'%d %b, %Y', u'%B %d %Y', u'%B %d, %Y', u'%d %B %Y', u'%d %B, %Y']
DEBUG
True
DEBUG_PROPAGATE_EXCEPTIONS
False
DECIMAL_SEPARATOR
u'.'
DEFAULT_CHARSET
u'utf-8'
DEFAULT_CONTENT_TYPE
u'text/html'
DEFAULT_EXCEPTION_REPORTER_FILTER
u'django.views.debug.SafeExceptionReporterFilter'
DEFAULT_FILE_STORAGE
u'django.core.files.storage.FileSystemStorage'
DEFAULT_FROM_EMAIL
u'webmaster@localhost'
DEFAULT_INDEX_TABLESPACE
u''
DEFAULT_TABLESPACE
u''
DISALLOWED_USER_AGENTS
[]
ELASTIC
None
EMAIL_BACKEND
u'django.core.mail.backends.smtp.EmailBackend'
EMAIL_HOST
u'localhost'
EMAIL_HOST_PASSWORD
u'****'
EMAIL_HOST_USER
u''
EMAIL_PORT
25
EMAIL_SSL_CERTFILE
None
EMAIL_SSL_KEYFILE
u'****'
EMAIL_SUBJECT_PREFIX
u'[Django] '
EMAIL_TIMEOUT
None
EMAIL_USE_SSL
False
EMAIL_USE_TLS
False
FILE_CHARSET
u'utf-8'
FILE_UPLOAD_DIRECTORY_PERMISSIONS
None
FILE_UPLOAD_HANDLERS
[u'django.core.files.uploadhandler.MemoryFileUploadHandler', u'django.core.files.uploadhandler.TemporaryFileUploadHandler']
FILE_UPLOAD_MAX_MEMORY_SIZE
2621440
FILE_UPLOAD_PERMISSIONS
None
FILE_UPLOAD_TEMP_DIR
None
FIRST_DAY_OF_WEEK
0
FIXTURE_DIRS
[]
FORCE_SCRIPT_NAME
None
FORMAT_MODULE_PATH
None
IGNORABLE_404_URLS
[]
INSTALLED_APPS
('django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.staticfiles', 'django.contrib.admin', 'analysis', 'compare')
INTERNAL_IPS
[]
LANGUAGES
[(u'af', u'Afrikaans'), (u'ar', u'Arabic'), (u'ast', u'Asturian'), (u'az', u'Azerbaijani'), (u'bg', u'Bulgarian'), (u'be', u'Belarusian'), (u'bn', u'Bengali'), (u'br', u'Breton'), (u'bs', u'Bosnian'), (u'ca', u'Catalan'), (u'cs', u'Czech'), (u'cy', u'Welsh'), (u'da', u'Danish'), (u'de', u'German'), (u'dsb', u'Lower Sorbian'), (u'el', u'Greek'), (u'en', u'English'), (u'en-au', u'Australian English'), (u'en-gb', u'British English'), (u'eo', u'Esperanto'), (u'es', u'Spanish'), (u'es-ar', u'Argentinian Spanish'), (u'es-co', u'Colombian Spanish'), (u'es-mx', u'Mexican Spanish'), (u'es-ni', u'Nicaraguan Spanish'), (u'es-ve', u'Venezuelan Spanish'), (u'et', u'Estonian'), (u'eu', u'Basque'), (u'fa', u'Persian'), (u'fi', u'Finnish'), (u'fr', u'French'), (u'fy', u'Frisian'), (u'ga', u'Irish'), (u'gd', u'Scottish Gaelic'), (u'gl', u'Galician'), (u'he', u'Hebrew'), (u'hi', u'Hindi'), (u'hr', u'Croatian'), (u'hsb', u'Upper Sorbian'), (u'hu', u'Hungarian'), (u'ia', u'Interlingua'), (u'id', u'Indonesian'), (u'io', u'Ido'), (u'is', u'Icelandic'), (u'it', u'Italian'), (u'ja', u'Japanese'), (u'ka', u'Georgian'), (u'kk', u'Kazakh'), (u'km', u'Khmer'), (u'kn', u'Kannada'), (u'ko', u'Korean'), (u'lb', u'Luxembourgish'), (u'lt', u'Lithuanian'), (u'lv', u'Latvian'), (u'mk', u'Macedonian'), (u'ml', u'Malayalam'), (u'mn', u'Mongolian'), (u'mr', u'Marathi'), (u'my', u'Burmese'), (u'nb', u'Norwegian Bokm\xe5l'), (u'ne', u'Nepali'), (u'nl', u'Dutch'), (u'nn', u'Norwegian Nynorsk'), (u'os', u'Ossetic'), (u'pa', u'Punjabi'), (u'pl', u'Polish'), (u'pt', u'Portuguese'), (u'pt-br', u'Brazilian Portuguese'), (u'ro', u'Romanian'), (u'ru', u'Russian'), (u'sk', u'Slovak'), (u'sl', u'Slovenian'), (u'sq', u'Albanian'), (u'sr', u'Serbian'), (u'sr-latn', u'Serbian Latin'), (u'sv', u'Swedish'), (u'sw', u'Swahili'), (u'ta', u'Tamil'), (u'te', u'Telugu'), (u'th', u'Thai'), (u'tr', u'Turkish'), (u'tt', u'Tatar'), (u'udm', u'Udmurt'), (u'uk', u'Ukrainian'), (u'ur', u'Urdu'), (u'vi', u'Vietnamese'), (u'zh-hans', u'Simplified Chinese'), (u'zh-hant', u'Traditional Chinese')]
LANGUAGES_BIDI
[u'he', u'ar', u'fa', u'ur']
LANGUAGE_CODE
'en-us'
LANGUAGE_COOKIE_AGE
None
LANGUAGE_COOKIE_DOMAIN
None
LANGUAGE_COOKIE_NAME
u'django_language'
LANGUAGE_COOKIE_PATH
u'/'
LOCALE_PATHS
[]
LOCAL_SETTINGS
True
LOGGING
{'disable_existing_loggers': False, 'filters': {'require_debug_false': {'()': 'django.utils.log.RequireDebugFalse'}}, 'handlers': {'mail_admins': {'class': 'django.utils.log.AdminEmailHandler', 'filters': ['require_debug_false'], 'level': 'ERROR'}}, 'loggers': {'django.request': {'handlers': ['mail_admins'], 'level': 'ERROR', 'propagate': True}}, 'version': 1}
LOGGING_CONFIG
u'logging.config.dictConfig'
LOGIN_REDIRECT_URL
'/'
LOGIN_URL
u'/accounts/login/'
LOGOUT_REDIRECT_URL
None
MANAGERS
()
MAX_UPLOAD_SIZE
26214400
MEDIA_ROOT
''
MEDIA_URL
''
MESSAGE_STORAGE
u'django.contrib.messages.storage.fallback.FallbackStorage'
MIDDLEWARE
None
MIDDLEWARE_CLASSES
('django.middleware.common.CommonMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'web.headers.CuckooHeaders')
MIGRATION_MODULES
{}
MOLOCH_ENABLED
False
MOLOCH_HOST
None
MONGO
Database(MongoClient(host=['127.0.0.1:27017'], document_class=dict, tz_aware=False, connect=True), u'cuckoo')
MONGO_DB
'cuckoo'
MONGO_HOST
'127.0.0.1'
MONGO_PORT
27017
MONTH_DAY_FORMAT
u'F j'
NUMBER_GROUPING
0
PASSWORD_HASHERS
u'****'
PASSWORD_RESET_TIMEOUT_DAYS
u'****'
PREPEND_WWW
False
ROOT_URLCONF
'web.urls'
SECRET_KEY
u'****'
SECURE_BROWSER_XSS_FILTER
False
SECURE_CONTENT_TYPE_NOSNIFF
False
SECURE_HSTS_INCLUDE_SUBDOMAINS
False
SECURE_HSTS_SECONDS
0
SECURE_PROXY_SSL_HEADER
None
SECURE_REDIRECT_EXEMPT
[]
SECURE_SSL_HOST
None
SECURE_SSL_REDIRECT
False
SERVER_EMAIL
u'root@localhost'
SESSION_CACHE_ALIAS
u'default'
SESSION_COOKIE_AGE
1209600
SESSION_COOKIE_DOMAIN
None
SESSION_COOKIE_HTTPONLY
True
SESSION_COOKIE_NAME
u'sessionid'
SESSION_COOKIE_PATH
u'/'
SESSION_COOKIE_SECURE
False
SESSION_ENGINE
u'django.contrib.sessions.backends.db'
SESSION_EXPIRE_AT_BROWSER_CLOSE
False
SESSION_FILE_PATH
None
SESSION_SAVE_EVERY_REQUEST
False
SESSION_SERIALIZER
u'django.contrib.sessions.serializers.JSONSerializer'
SETTINGS_MODULE
'web.settings'
SHORT_DATETIME_FORMAT
u'm/d/Y P'
SHORT_DATE_FORMAT
u'm/d/Y'
SIGNING_BACKEND
u'django.core.signing.TimestampSigner'
SILENCED_SYSTEM_CHECKS
[]
SITE_ID
1
STATICFILES_DIRS
('/home/cuckoo/cuckoo/web/static',)
STATICFILES_FINDERS
('django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder', 'django.contrib.staticfiles.finders.DefaultStorageFinder')
STATICFILES_STORAGE
u'django.contrib.staticfiles.storage.StaticFilesStorage'
STATIC_ROOT
''
STATIC_URL
'/static/'
TEMPLATES
[{'APP_DIRS': True, 'BACKEND': 'django.template.backends.django.DjangoTemplates', 'DIRS': ['/home/cuckoo/cuckoo/web/templates'], 'OPTIONS': {'context_processors': ['django.template.context_processors.debug', 'django.template.context_processors.request', 'django.contrib.auth.context_processors.auth', 'django.contrib.messages.context_processors.messages']}}]
TEST_NON_SERIALIZED_APPS
[]
TEST_RUNNER
'django.test.runner.DiscoverRunner'
THOUSAND_SEPARATOR
u','
TIME_FORMAT
u'P'
TIME_INPUT_FORMATS
[u'%H:%M:%S', u'%H:%M:%S.%f', u'%H:%M']
TIME_ZONE
None
USE_ETAGS
False
USE_I18N
True
USE_L10N
True
USE_THOUSAND_SEPARATOR
False
USE_TZ
False
USE_X_FORWARDED_HOST
False
USE_X_FORWARDED_PORT
False
WSGI_APPLICATION
'web.wsgi.application'
X_FRAME_OPTIONS
u'SAMEORIGIN'
YEAR_MONTH_FORMAT
u'F Y'
You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard page generated by the handler for this status code.
Help ?
downgrade django to 1.7-1.9, as that 1.10 generate this problem
What @doomedraven said, as per
requirements.txt
we currently focus on support for Django1.8.4
. For other versions we don't guarantee it works.Seeing same error again with latest cuckoo source downloaded today April 07,2017
My Environment: Host : Ubuntu 16.04-64 bit VirtualBox Guest: Ubuntu 15.04-64.
Environment:
Request Method: GET Request URL: http://0.0.0.0:8000/analysis/1/
Django Version: 1.8.4 Python Version: 2.7.12 Installed Applications: ('django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.staticfiles', 'django.contrib.admin', 'analysis', 'compare') Installed Middleware: ('django.middleware.common.CommonMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'web.headers.CuckooHeaders')
Template error: In template /opt/cuckoo/web/templates/analysis/network/_dns.html, error at line 14 Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user-VirtualBox [08:00:27:d7:67:46]._workstation.tcp.local'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d\.]+)?/(?P[ a-zA-Z0-9- \.]+)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P\d+)?']
4 : {% if analysis.network.dns %}
5 :
6 :
7 :
8 :
9 :
10 :
11 : {% for p in analysis.network.dns %}
12 :
13 :
14 : <a target="_blank" href=" {% url "analysis.views.moloch" host=p.request %} ">{{p.request}}
15 :
16 :
17 : {% for a in p.answers %}
18 : {% if a.type == "A" %}
19 : {% if ":" not in a.data %}
20 : <a target="_blank" href="{% url "analysis.views.moloch" ip=a.data %}">
21 : {{a.type}} {{a.data|linebreaksbr}}
22 :
23 : {% else %}
24 : {{a.type}} {{a.data|linebreaksbr}}
Traceback: File "/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py" in get_response
Exception Type: NoReverseMatch at /analysis/1/ Exception Value: Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user-VirtualBox [08:00:27:d7:67:46]._workstation.tcp.local'}' not found. 1 pattern(s) tried: ['analysis/moloch/(?P[\d\.]+)?/(?P[ a-zA-Z0-9- \.]+)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P\d+)?']
I have django version 1.8.4 on my system
Copyright (C) 2010-2013 Claudio Guarnieri.
Copyright (C) 2014-2016 Cuckoo Foundation.
This file is part of Cuckoo Sandbox - http://www.cuckoosandbox.org
See the file "docs/LICENSE" for copying permission.
from . import views from django.conf.urls import url
urlpatterns = [ url(r"^$", views.index), url(r"^(?P\d+)/$", views.report),
url(r"^latest/$", views.latest_report),
url(r"^remove/(?P\d+)/$", views.remove),
url(r"^chunk/(?P\d+)/(?P\d+)/(?P\d+)/$", views.chunk),
url(r"^filtered/(?P\d+)/(?P\d+)/(?P\w+)/$", views.filtered_chunk),
url(r"^search/(?P\d+)/$", views.search_behavior),
url(r"^search/$", views.search),
url(r"^pending/$", views.pending),
url(r"^(?P\d+)/pcapstream/(?P[.,\w]+)/$", views.pcapstream),
url(r"^moloch"
r"/(?P[\d.]+)?/(?P[ a-zA-Z0-9-_.]+)?"
r"/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?"
r"/(?P[a-zA-Z0-9.]+)?/(?P\d+|None)?"
r"/(?P\d+)?",
views.moloch),
url(r"^(?P\d+)/export/$", views.export_analysis),
url(r"^import/$", views.import_analysis),
url(r"^(?P\d+)/reboot/$", views.reboot_analysis),
Reverse for 'analysis.views.moloch' with arguments '()' and keyword arguments '{u'host': u'user-VirtualBox [08:00:27:d7:67:46]._workstation.tcp.local'}' not found. 2 pattern(s) tried: ['analysis/moloch/(?P[\d\.]+)?/(?P[ a-zA-Z0-9- \.]+)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P[a-zA-Z0-9\.]+)?/(?P\d+|None)?/(?P\d+)?', 'analysis/moloch']
What is a problem with string '{u'host': u'user-VirtualBox [08:00:27:d7:67:46]._workstation.tcp.local'} and regex match string (?P[\d\.]+)?/(?P[ a-zA-Z0-9- \.]+)?
@jbremer @alonlavian help needed, stuck here , is it problem with string match. I also see folloing error message in cuckoo log
2017-04-10 19:36:08,840 [lib.cuckoo.core.guest] INFO: Starting analysis on guest (id=ubuntu1504-64, ip=192.168.56.101) 2017-04-10 19:38:16,518 [lib.cuckoo.core.guest] INFO: ubuntu1504-64: analysis completed successfully 2017-04-10 19:38:16,631 [lib.cuckoo.core.plugins] WARNING: Unable to stop auxiliary module: Potential error while running tcpdump, did not expect the following standard error output: 'dropped privs to root'. 2017-04-10 19:38:27,280 [modules.machinery.virtualbox] INFO: Successfully generated memory dump for virtual machine with label ubuntu1504-64 to path /opt/cuckoo/storage/analyses/5/memory.dmp 2017-04-10 19:38:42,189 [lib.cuckoo.core.scheduler] INFO: Task #5: reports generation completed (path=/opt/cuckoo/storage/analyses/5) 2017-04-10 19:38:43,736 [lib.cuckoo.core.scheduler] INFO: Task #5: analysis procedure completed