/ISE_API_scripts

Use API calls to gather informations from Cisco ISE (tested with v3.1)

Primary LanguagePythonMIT LicenseMIT

Python 3.6 Python 3.7 Python 3.8 Python 3.9

ISE_API_scripts

Use API calls to gather informations from Cisco ISE (tested with v3.1)

Author: nouse4it github@schlueter-online.net

get_devices_ISE_API.py

Illustrate the following conecepts:

  • Get all network devices for from ISE and store them in csv format

Use Case Description

The scripts is used to gather all Network Devices from Cisco ISE by Rest API. It then saves alle the informations into a csv file. The script leverages the Cisco ISE ERS API For more informations see ERS API Documentation

Installation

You will need the Python Module requests You can install it via pip install requests

Documentation for more informations regardings requests.

Python Version must be at least v3.6

Usage

When you run the script, you will asked to input the following informations:

  • IP of Cisco ISE
  • Username of ERS API user
  • Password of ERS API user

How it works

The script queries the API for the wanted informations (you can adjust this script to gather other informations aswell) When there are a lot of information, the API pages the returned Informations. Maximum a 100 results can be received at one page. So when you have more than 100 devices, the script checks for how many pages would be available and writes the results of every page into the csv.

check_MAC_EIG.py

Illustrate the following conecepts:

  • Check if given MAC-Address is in given Endpoint Group on ISE
  • Scripts intended for Users without Admin User on ISE

Use Case Description

The scripts is used to check if given MAC Address is in Endpoint Identity Grouop. The script leverages the Cisco ISE ERS API For more informations see ERS API Documentation

Installation

You will need the Python Module requests You can install it via pip install requests

Documentation for more informations regardings requests.

Python Version must be at least v3.6

Usage

When you run the script, you will asked to input the following informations:

  • IP of Cisco ISE
  • Username of ERS API user
  • Password of ERS API user
  • MAC Address to search for
  • Endpoint Identity Group to check against

How it works

The script queries the API for the wanted informations (you can adjust this script to gather other informations aswell) When there are a lot of information, the API pages the returned Informations. Maximum a 100 results can be received at one page.

get_guest_user_ISE_API.py

Illustrate the following conecepts:

  • Get detailled informations about active guest users

Use Case Description

The scripts is used to gather the following Informations for created Guest User:

  • username
  • firstname
  • lastname
  • company
  • enabled
  • validdays
  • fromdate
  • todate
  • location

Those information will then be written into a csv file

The script leverages the Cisco ISE ERS API For more informations see ERS API Documentation

Installation

You will need the Python Module requests You can install it via pip install requests

Documentation for more informations regardings requests.

Python Version must be at least v3.6

Usage

When you run the script, you will asked to input the following informations:

  • IP of Cisco ISE
  • Username of ERS API user
  • Password of ERS API user
  • MAC Address to search for
  • Endpoint Identity Group to check against

How it works

The script queries the API for the wanted informations (you can adjust this script to gather other informations aswell) When there are a lot of information, the API pages the returned Informations. Maximum a 100 results can be received at one page.