nopasaran 0.2.91__tar.gz → 0.2.92__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {nopasaran-0.2.91 → nopasaran-0.2.92}/PKG-INFO +1 -1
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/dns_primitives.py +10 -12
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran.egg-info/PKG-INFO +1 -1
- {nopasaran-0.2.91 → nopasaran-0.2.92}/setup.py +1 -1
- {nopasaran-0.2.91 → nopasaran-0.2.92}/LICENSE +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/README.md +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/__main__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/controllers/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/controllers/controller.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/controllers/factory.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/controllers/protocol.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/decorators.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/definitions/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/definitions/commands.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/definitions/control_channel.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/definitions/events.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/definitions/transitions.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/errors/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/errors/parsing_error.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/http_2_utils.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/interpreters/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/interpreters/action_interpreter.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/interpreters/condition_interpreter.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/interpreters/interpreter.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/interpreters/transition_interpreter.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/machines/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/machines/action_queue.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/machines/state_machine.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/parsers/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/parsers/interpreter_parser.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/parsers/state_machine_parser.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/action_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/certificate_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/client_echo_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/control_channel_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/data_channel_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/data_manipulation.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/event_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/http_1_request_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/http_1_response_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/http_2_client_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/http_2_server_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/http_simple_client_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/https_1_request_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/https_1_response_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/icmp_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/io_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/ip_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/nested_machine_utils.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/probing_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/replay_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/server_echo_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/signaling_primitive.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/tcp_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/timing_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/tls_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/udp_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/condition_primitives/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/condition_primitives/condition_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/condition_primitives/variable_comparisons.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/transition_primitives/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/transition_primitives/assignment_transitions.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/transition_primitives/transition_primitives.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/sniffers/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/sniffers/sniffer.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/__init__.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/checks.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/echo_socket_server.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/http_1_socket_server.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/http_2_overwrite.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/http_2_socket_base.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/http_2_socket_client.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/http_2_socket_server.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/tools/https_1_socket_server.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/utils.py +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran.egg-info/SOURCES.txt +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran.egg-info/dependency_links.txt +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran.egg-info/entry_points.txt +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran.egg-info/requires.txt +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran.egg-info/top_level.txt +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/setup.cfg +0 -0
- {nopasaran-0.2.91 → nopasaran-0.2.92}/tests/__init__.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: nopasaran
|
3
|
-
Version: 0.2.
|
3
|
+
Version: 0.2.92
|
4
4
|
Summary: NoPASARAN is an advanced network tool designed to detect, fingerprint, and locate network middleboxes in a unified framework.
|
5
5
|
Home-page: https://github.com/BenIlies/NoPASARAN
|
6
6
|
Author: Ilies Benhabbour
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/dns_primitives.py
RENAMED
@@ -837,15 +837,10 @@ class DNSPrimitives:
|
|
837
837
|
48: "DNSKEY", 255: "ANY"
|
838
838
|
}
|
839
839
|
|
840
|
-
dnsqtypes = dnsatypes # if you meant dnsatypes to cover both
|
841
|
-
|
842
840
|
dns_layer = None
|
843
841
|
|
844
|
-
# Try to get DNS layer from packet
|
845
842
|
if hasattr(packet, 'haslayer') and packet.haslayer(DNS):
|
846
843
|
dns_layer = packet.getlayer(DNS)
|
847
|
-
|
848
|
-
# Try to parse DNS from Raw if not directly available
|
849
844
|
elif hasattr(packet, 'haslayer') and packet.haslayer('Raw'):
|
850
845
|
try:
|
851
846
|
dns_layer = DNS(packet['Raw'].load)
|
@@ -869,33 +864,36 @@ class DNSPrimitives:
|
|
869
864
|
"answers": []
|
870
865
|
}
|
871
866
|
|
872
|
-
# Handle DNS
|
867
|
+
# Handle DNS questions
|
873
868
|
if getattr(dns_layer, "qdcount", 0) > 0 and getattr(dns_layer, "qd", None):
|
874
869
|
try:
|
875
870
|
question = dns_layer.qd
|
876
871
|
formatted_response["questions"].append({
|
877
872
|
"qname": question.qname.decode() if isinstance(question.qname, bytes) else question.qname,
|
878
873
|
"qtype": question.qtype,
|
879
|
-
"qtype_name":
|
874
|
+
"qtype_name": dnsatypes.get(question.qtype, f"Unknown({question.qtype})"),
|
880
875
|
"qclass": question.qclass
|
881
876
|
})
|
882
877
|
except Exception as e:
|
883
878
|
logging.error(f"[Parsing] Failed to parse DNS question: {e}")
|
884
879
|
|
885
|
-
# Handle DNS answers
|
880
|
+
# Handle DNS answers (support for lists and chained payloads)
|
886
881
|
try:
|
887
|
-
ans = dns_layer.an
|
888
|
-
|
882
|
+
ans = dns_layer.an
|
883
|
+
for _ in range(getattr(dns_layer, "ancount", 0)):
|
884
|
+
if not isinstance(ans, DNSRR):
|
885
|
+
break
|
889
886
|
answer_info = {
|
890
887
|
"rrname": ans.rrname.decode() if isinstance(ans.rrname, bytes) else ans.rrname,
|
891
888
|
"type": ans.type,
|
892
889
|
"type_name": dnsatypes.get(ans.type, f"Unknown({ans.type})"),
|
893
890
|
"rclass": ans.rclass,
|
894
891
|
"ttl": ans.ttl,
|
895
|
-
"rdata": str(ans.rdata),
|
892
|
+
"rdata": ans.rdata.decode() if isinstance(ans.rdata, bytes) else str(ans.rdata),
|
893
|
+
"rdlen": getattr(ans, "rdlen", None)
|
896
894
|
}
|
897
895
|
formatted_response["answers"].append(answer_info)
|
898
|
-
ans = ans.payload
|
896
|
+
ans = ans.payload
|
899
897
|
except Exception as e:
|
900
898
|
logging.error(f"[Parsing] Failed to parse DNS answers: {e}")
|
901
899
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: nopasaran
|
3
|
-
Version: 0.2.
|
3
|
+
Version: 0.2.92
|
4
4
|
Summary: NoPASARAN is an advanced network tool designed to detect, fingerprint, and locate network middleboxes in a unified framework.
|
5
5
|
Home-page: https://github.com/BenIlies/NoPASARAN
|
6
6
|
Author: Ilies Benhabbour
|
@@ -13,7 +13,7 @@ with open(requirements_file, "r") as f:
|
|
13
13
|
# Version will automatically be updated when pushed on the main branch
|
14
14
|
setup(
|
15
15
|
name="nopasaran",
|
16
|
-
version='0.2.
|
16
|
+
version='0.2.92',
|
17
17
|
author="Ilies Benhabbour",
|
18
18
|
author_email="ilies.benhabbour@kaust.edu.sa",
|
19
19
|
description="NoPASARAN is an advanced network tool designed to detect, fingerprint, and locate network middleboxes in a unified framework.",
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/action_primitives.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/data_manipulation.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/event_primitives.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/icmp_primitives.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/io_primitives.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/ip_primitives.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/nested_machine_utils.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/probing_primitives.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/replay_primitives.py
RENAMED
File without changes
|
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/signaling_primitive.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/tcp_primitives.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/timing_primitives.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/tls_primitives.py
RENAMED
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/action_primitives/udp_primitives.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{nopasaran-0.2.91 → nopasaran-0.2.92}/nopasaran/primitives/transition_primitives/__init__.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|