Skip to content

Commit 89dc117

Browse files
committed
switch to safe XML parsing
1 parent b49be87 commit 89dc117

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ requires-python = ">=3.7"
2424
dependencies = [
2525
"numpy", # for vector math
2626
"jsonschema", # for spec validation
27+
"defusedxml", # for safe XML parsing (XXE protection)
2728
]
2829
[project.urls]
2930
repository = "https://github.com/sigmf/sigmf-python"

sigmf/convert/signalhound.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
import io
1111
import logging
1212
import tempfile
13-
import xml.etree.ElementTree as ET
13+
import defusedxml.ElementTree as ET
1414
from datetime import datetime, timedelta, timezone
1515
from pathlib import Path
1616
from typing import List, Optional, Tuple

0 commit comments

Comments
 (0)