Skip to content

Commit

Permalink
fabtests/scripts: use yaml safe_load
Browse files Browse the repository at this point in the history
Follow security best practice.

Signed-off-by: Wenduo Wang <wenduwan@amazon.com>
  • Loading branch information
wenduwan committed Sep 15, 2023
1 parent a80b724 commit cccf66a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion fabtests/scripts/parseyaml.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ def read():
else:
fd = open(args[0], 'r')

yi = yaml.load_all(fd.read())
yi = yaml.safe_load_all(fd.read())

if options.d:
perfprint(difference(yi))
Expand Down
2 changes: 1 addition & 1 deletion fabtests/scripts/toCSV.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def main(argv=None):
else:
fd = open(args[0], 'r')

yi = yaml.load(fd.read())
yi = yaml.safe_load(fd.read())

csv_fd = csv.writer(sys.stdout, delimiter=",", quotechar='"', quoting=csv.QUOTE_NONNUMERIC)
csv_fd.writerow(["Test name", "Status"])
Expand Down

0 comments on commit cccf66a

Please sign in to comment.