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

Country error #6

Open
CyberSecGuy opened this issue Apr 13, 2018 · 1 comment
Open

Country error #6

CyberSecGuy opened this issue Apr 13, 2018 · 1 comment

Comments

@CyberSecGuy
Copy link

CyberSecGuy commented Apr 13, 2018

[2018-04-13 15:42:56,128] ERROR in app: Exception on /stats/countries [GET]
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1982, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1614, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1517, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1612, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1598, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "./cowrie-logviewer.py", line 147, in show_stats_countries
    tmp = [ pycountry.countries.get(alpha_2=country[0]).name, country[0], country[1] ]
  File "/usr/local/lib/python2.7/dist-packages/pycountry/db.py", line 43, in load_if_needed
    return f(self, *args, **kw)
  File "/usr/local/lib/python2.7/dist-packages/pycountry/db.py", line 101, in get
    return self.indices[field][value]
KeyError: None
@SteveClement
Copy link

I fixed that in my fork too: https://github.com/SteveClement/cowrie-logviewer

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

2 participants