mirror of https://github.com/MISP/misp-modules
fix: [cleanup] Quick clean up on yaml load function
parent
57af98720d
commit
bb6002a3ff
|
@ -21,7 +21,7 @@ def handler(q=False):
|
||||||
return misperrors
|
return misperrors
|
||||||
config = SigmaConfiguration()
|
config = SigmaConfiguration()
|
||||||
try:
|
try:
|
||||||
parser = SigmaParser(yaml.load(request.get('sigma')), config)
|
parser = SigmaParser(yaml.safe_load(request.get('sigma')), config)
|
||||||
result = ("Syntax valid: {}".format(parser.values))
|
result = ("Syntax valid: {}".format(parser.values))
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
result = ("Syntax error: {}".format(str(e)))
|
result = ("Syntax error: {}".format(str(e)))
|
||||||
|
|
Loading…
Reference in New Issue