Packet tracer 8.0.0 available for download

Cisco Packet Tracer 8.0.0 build 8.0.0.212 has just been released for download on Netacad website.

Packet Tracer 8.0.0 main new features are :

  • A new SDN network controller device
  • API programming capabilities which can be accessed from the host PC using real world programming tools (curl, Python 3, VS code, ....).
  • New user interface appearance
  • New Packet Tracer splash screen.

Cisco Packet Tracer 8.0.0 new splash screen

 

New hardware - SDN Controller

The SDN controller embedded in Cisco Packet Tracer 8.0.0 similar to existing real-world SDN Controllers like Cisco DNA Center and APIC-EM.

Cisco Packet Tracer 8.0.0 SDN controller device

The Network Controller, managed using its Web GUI or using its APIs, provides a centralized dashboard to view the network’s state, allowing network administrtor to quickly identify & troubleshoot issues, and push configuration changes to all managed devices at once.

The Network Controller can be accessed from real -world applications running on the host computer, like a web browser, VScode, Python, curl,  Postman, to execute network automation scripts. External access to SDN controller has to be enabled in the Cisco Packet Tracer 8.0.0 preferences before beeing able to enable it in the SDN controller device configuration tabs.

 

Step 1 : Enable External Access for network Controller REST API global setting

Enable External Access for network Controller REST API Packet Tracer 8.0.0 global setting

 

Step 2 : Enable remote access and configure HTTP port in SDN Controller configuration tab

Enable remote access and configure HTTP port in Packet Tracer 8.0.0 SDN Controller configuration tab

 

SDN controller programming with Python, VSCode and WSL

WSL integration

The Cisco Packet Tracer 8.0 SDN Coontroller provides a REST API with enables network programmability using Python language. As the API can be accessed from the host, the network administrator can leverage the power of real worl development environment and program the Cisco Packet Tracer emulated network using Microsoft VScode IDE and Windows Subsystem Linux (WSL 1 supported for http://localhost:<port> access, access with WSL2 using http://<host ip>:<port> has not been tested yet and could encounter firewalling issues).

Cisco Packet Tracer 8.0 SDN controller API access from Windows Subsystem Linux (WSL)

The Microsoft VScode and it's WSL integration extension editor can also be used to ease SDN API programmability with Python 3, leverage code quality tools such as Pylint or Sonarqube, and collaborate inside your team using GIT SCM.

 

Programming the SDN controller

The Cisco Packet Tracer 8.0 SDN controller can be programmed using it's REST API which can be accessed using the programming language of your choice. As Cisco DevNet is actively promoting Python for network programmability and providing code samples on https://developer.cisco.com/site/python/, Python 3 will be used in the following exemples.

Warning : Python code provided in Cisco Packet Tracer sample PKT files fail when used in a real world Python environment as some HTTP libraries are missing.

The following Python3 code gathers security token and lists Packet Tracer 8.0 SDN Controller network devices from the host

import json
import requests
	
def main():
	
	#Get security token
	securityUrl = "http://localhost:58000/api/v1/ticket"
	securityData = json.dumps({"username": "test","password": "test"})
	securityHeader = {'Content-type': 'application/json'}
	r = requests.post(securityUrl, data=securityData, headers=securityHeader)
	token = r.json()["response"]["serviceTicket"]
	print("token: " + token)

	#Get hosts
	apiAccessHeader = {}
	apiAccessHeader['content-type'] = 'application/json'
	apiAccessHeader['x-auth-token'] = token
	r = requests.get('http://localhost:58000/api/v1/network-device', headers=apiAccessHeader);
	print(json.dumps(r.json(), indent=2))

if __name__ == "__main__":
	main()