Getting XML Parsing Errors When Interacting to AWS Based Panoramas
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 30/100
Línea de trabajo
The traceback points to panos/base.py, from DeviceGroup.refreshall through refreshall_from_xml and parse_xml; start there and reproduce with the AWS Panorama XML configuration. Confirm how the “0-8” value is represented, then verify that the original security and NAT rulebase retrieval flow parses successfully without breaking existing Panorama cases.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Describe the bug
I have a script that uses the panos library and when used against Panorama in AWS I get a parsing error. Below is that error:
File "/Users/ncarabaj/Desktop/pre-post-rule-download/panorama-info-version-1.py", line 127, in
main()
File "/Users/ncarabaj/Desktop/pre-post-rule-download/panorama-info-version-1.py", line 117, in main
device_groups = DeviceGroup.refreshall(panorama)
File "/usr/local/lib/python3.9/site-packages/panos/base.py", line 1338, in refreshall
instances = class_instance.refreshall_from_xml(obj)
File "/usr/local/lib/python3.9/site-packages/panos/base.py", line 1404, in refreshall_from_xml
instance._refresh_children(xml=obj)
File "/usr/local/lib/python3.9/site-packages/panos/base.py", line 1038, in _refresh_children
l = child.refreshall_from_xml(childroot)
File "/usr/local/lib/python3.9/site-packages/panos/base.py", line 1389, in refreshall_from_xml
instance.parse_xml(obj)
File "/usr/local/lib/python3.9/site-packages/panos/base.py", line 2789, in parse_xml
var_path.parse_xml(xml, settings, possibilities)
File "/usr/local/lib/python3.9/site-packages/panos/base.py", line 3223, in parse_xml
self.parse_value_from_xml_last_tag(e, settings, attr)
File "/usr/local/lib/python3.9/site-packages/panos/base.py", line 3306, in parse_value_from_xml_last_tag
settings[self.param] = int(elm.text)
ValueError: invalid literal for int() with base 10: '0-8'
Expected behavior
Should authenticate and parse
Current behavior
Possible solution
Need to be able to ingest the xml config from AWS
Steps to reproduce
- Run the code in the link against AWS Panorama
Screenshots
N/A
Context
Trying to gather pre and post security and nat rulebase from Pano. It does work on others just not ones in AWS.
Your Environment
- Environment name and version (e.g. Chrome 59, node.js 5.4, python 3.7.3):
Python 3.11.3
- Operating System and version (desktop or mobile):
MacOS Catalina Version 10.15.7 - User laptop
Panorama version 10.1.9
aws-2.0.2
- Link to your project:
- Lenguaje dominante
- Python
- Estrellas
- 402
- Forks
- 198
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.
- Sin Dockerfile ni archivo de Docker Compose
- Sin plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de PaloAltoNetworks/pan-os-python
-
bug
Dificultad 1/5 Menos de una hora Aptitud para principiantes 68/100
PaloAltoNetworks/pan-os-python#624 · 1 comentario ·
-
Security: xml.etree.ElementTree used across 10 core modules — no XXE protectionPosiblemente ocupada Un pull request vinculado a esta issue está abierto o ya se fusionó. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
PaloAltoNetworks/pan-os-python#617 · 2 comentarios ·
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
-
documentation
Dificultad 2/5 1-3 horas Aptitud para principiantes 35/100
-
Feature/Zone Protection ProfilesAbiertoenhancement
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
Todos los issues de PaloAltoNetworks/pan-os-python
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
RunestoneInteractive/rs#1661 ·
Los mantenedores suelen responder en 2 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 64/100
streamlink/streamlink#7192 · 4 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 1/5 1-3 horas Aptitud para principiantes 75/100
Los mantenedores suelen responder en 2 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
aws-samples/sample-per-model-bedrock#795 ·
Los mantenedores suelen responder en 1 día