Re: [j-nsp] PyEZ list SRX firewall policies

2019-07-22 Thread Floris Termorshuizen
Janiszewski Sent: maandag 22 juli 2019 13:35 To: Floris Termorshuizen Cc: juniper-nsp@puck.nether.net Subject: Re: [j-nsp] PyEZ list SRX firewall policies Hi Floris, I'm not Python programmer, but it seems that "secpol.app" (or "src" or "dst") is sometimes

Re: [j-nsp] PyEZ list SRX firewall policies

2019-07-22 Thread Wojciech Janiszewski
Hi Floris, I'm not Python programmer, but it seems that "secpol.app" (or "src" or "dst") is sometimes string and sometimes it's a list of strings. If it's a single string, then it's being split into characters by [] operator. If's it's a list, then [] gives you a string (which is what you're looki

[j-nsp] PyEZ list SRX firewall policies

2019-07-21 Thread Floris Termorshuizen
Hello! Currently playing around with PyEZ to retrieve the firewall policies from a SRX, and I have some issues with formatting/printing the source/dest/app names. I've created a custom YAML in Python for the Table/View combination and can run it against a SRX: === CODE === myYAML = ''' --- Sec