diff --git a/slips_files/common/slips_utils.py b/slips_files/common/slips_utils.py index 84aceaeaa..bfc71f6a6 100644 --- a/slips_files/common/slips_utils.py +++ b/slips_files/common/slips_utils.py @@ -397,6 +397,9 @@ def is_port_in_use(self, port: int) -> bool: def is_private_ip( self, ip: Union[ipaddress.IPv4Address, ipaddress.IPv6Address, str] ) -> bool: + if self.detect_ioc_type(ip) != "ip": + return False + ip_classes = {ipaddress.IPv4Address, ipaddress.IPv6Address} for class_ in ip_classes: if isinstance(ip, class_):