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

[Help Wanted] First Analyser #449

Closed
Idriel opened this issue Apr 1, 2019 · 1 comment
Closed

[Help Wanted] First Analyser #449

Idriel opened this issue Apr 1, 2019 · 1 comment
Labels
category:invalid Issue is related to an invalid request

Comments

@Idriel
Copy link

Idriel commented Apr 1, 2019

Hi,

Can I get some help with first analyser. I cannot get it to work even with code like this. :(

Can somebody point me what I am doint wrong? Thanks...

#!/usr/bin/env python3
from cortexutils.analyzer import Analyzer

class Test(Analyzer):
  def __init__(self):
    Analyzer.__init__(self)

  def summary(self, raw):
    taxonomies = []
    level = "info"
    namespace = "Logon"
    predicate = "Search"
    value = "{'results':'test'}"
    taxonomies.append(self.build_taxonomy(level, namespace, predicate, value))
    return {"taxonomies": taxonomies}

  def run(self):
     return self.report({'results': 'test'})

if __name__ == '__main__':
  Test().run()

What I got is

{
  "input": null,
  "success": false,
  "errorMessage": "Invalid output\n",
  "artifacts": []
}
@Idriel Idriel added the category:feature-request Issue is related to a feature request label Apr 1, 2019
@Idriel
Copy link
Author

Idriel commented Apr 1, 2019

Oh my. :D
I didnt make script executable. :)

@Idriel Idriel closed this as completed Apr 1, 2019
@nadouani nadouani added category:invalid Issue is related to an invalid request and removed category:feature-request Issue is related to a feature request labels Apr 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:invalid Issue is related to an invalid request
Projects
None yet
Development

No branches or pull requests

2 participants