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 using elisticsearch option #64

Open
sei-mwd opened this issue Jun 5, 2020 · 0 comments
Open

Bug using elisticsearch option #64

sei-mwd opened this issue Jun 5, 2020 · 0 comments
Labels

Comments

@sei-mwd
Copy link

sei-mwd commented Jun 5, 2020

There is a bug in zschema when using the elasticsearch option:

zschema --module zgrab2_schemas.zgrab2 elasticsearch zgrab2-ftp /mnt/hgfs/Shared/ftp_dod_cidr.json
Traceback (most recent call last):
  File "/usr/local/bin/zschema", line 11, in <module>
    load_entry_point('zschema==0.10.2', 'console_scripts', 'zschema')()
  File "/home/juser/.local/lib/python2.7/site-packages/zschema/__main__.py", line 87, in main
    print json.dumps(record.to_es(recname))
UnboundLocalError: local variable 'recname' referenced before assignment

Removing recname from the to_es() call seems to fix this bug. You should probably check the other to_X() calls, as using recname is not correct most of the time.

@zakird zakird added the bug label Jun 5, 2020
@sei-mwd sei-mwd mentioned this issue Jun 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants