From 2e69dc6c54da708a5ea45763eca0cf65785fb7dc Mon Sep 17 00:00:00 2001 From: garciadeblas Date: Tue, 5 Jul 2022 18:05:04 +0200 Subject: [PATCH] Use of yaml.SafeLoader instead of yaml.Loader Change-Id: I11a4775ac657275d14b3d7a76abbefdca5d556f4 Signed-off-by: garciadeblas --- n2vc/n2vc_conn.py | 2 +- n2vc/utils.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/n2vc/n2vc_conn.py b/n2vc/n2vc_conn.py index 68e8c14..d38bcad 100644 --- a/n2vc/n2vc_conn.py +++ b/n2vc/n2vc_conn.py @@ -524,4 +524,4 @@ def obj_to_dict(obj: object) -> dict: # convert obj to yaml yaml_text = obj_to_yaml(obj) # parse to dict - return yaml.load(yaml_text, Loader=yaml.Loader) + return yaml.load(yaml_text, Loader=yaml.SafeLoader) diff --git a/n2vc/utils.py b/n2vc/utils.py index 286f0fc..a4a6a23 100644 --- a/n2vc/utils.py +++ b/n2vc/utils.py @@ -149,7 +149,7 @@ def obj_to_dict(obj: object) -> dict: # convert obj to yaml yaml_text = obj_to_yaml(obj) # parse to dict - return yaml.load(yaml_text, Loader=yaml.Loader) + return yaml.load(yaml_text, Loader=yaml.SafeLoader) def get_ee_id_components(ee_id: str) -> Tuple[str, str, str]: -- 2.25.1