mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-19 15:33:06 +01:00
Merge pull request #7969 from Security-Onion-Solutions/fix/helpers-analyzers
Only import yaml module when config is loaded
This commit is contained in:
@@ -1,7 +1,6 @@
|
|||||||
import json
|
import json
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
import yaml
|
|
||||||
|
|
||||||
|
|
||||||
def checkSupportedType(meta, artifact_type):
|
def checkSupportedType(meta, artifact_type):
|
||||||
@@ -24,5 +23,6 @@ def loadMetadata(file):
|
|||||||
|
|
||||||
|
|
||||||
def loadConfig(path):
|
def loadConfig(path):
|
||||||
|
import yaml
|
||||||
with open(str(path), "r") as conffile:
|
with open(str(path), "r") as conffile:
|
||||||
return yaml.safe_load(conffile)
|
return yaml.safe_load(conffile)
|
||||||
|
|||||||
Reference in New Issue
Block a user