Guest User

Untitled

a guest
Dec 24th, 2018
138
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. #This is a practice script to detect if pan-python works
  2. from pan import xapi
  3. def main():
  4. def __init__(self, arg1=None):
  5. self.arg1 = arg1
  6. xapi.PanXapi(api_username='admin', api_password='admin', hostname='192.168.1.2',
  7. api_key='LUFRPT14MW5xOEo1R09KVlBZNnpnemh0VHRBOWl6TGM9bXcwM3JHUGVhRlNiY0dCR0srNERUQT09')
  8. xapi.PanXapi.cmd_xml(self, cmd='<show><system><info></info></system></show>')
  9. print(xapi.PanXapi.cmd_xml(self, cmd='<show><system><info></info></system></show>'))
  10. #Call main
  11. if __name__ == '__main__':
  12. main()
Add Comment
Please, Sign In to add comment