mediumMultiple ChoiceObjective-mapped
CCNP Practice Question: Is using Netmiko to connect to a Cisco IOS-XE…
A network engineer is using Netmiko to connect to a Cisco IOS-XE device that is managed by Cisco DNA Center. The script is:
from netmiko import ConnectHandler
device = { 'device_type': 'cisco_ios', 'host': '10.10.10.1', 'username': 'admin', 'password': 'cisco123', 'secret': 'enable123'
}
connection = ConnectHandler(**device) connection.enable() output = connection.send_command('show ip interface brief')
print(output)
connection.disconnect()
What is a potential security concern with this script in the context of DNA Center?
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
The enable secret is hardcoded in plain text, which is a security risk.
The script stores the enable secret in plain text. In a production environment, credentials should be stored securely, such as using environment variables or a vault. DNA Center itself stores credentials encrypted, but this script exposes them.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
The script does not handle authentication failures gracefully.
Why it's wrong here
While true, the main security concern is plain text credentials.
- ✓
The enable secret is hardcoded in plain text, which is a security risk.
Why this is correct
Correct. Hardcoding credentials is insecure. They should be stored in a secure manner.
- ✗
The device_type should be 'cisco_xe' for IOS-XE.
Why it's wrong here
'cisco_ios' works for IOS-XE devices as well.
- ✗
The script should use SSH keys instead of passwords.
Why it's wrong here
While SSH keys are more secure, the immediate issue is plain text storage.
About these practice questions
Courseiva writes every 350-401 question from scratch — 1,175 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This 350-401 practice question is part of Courseiva's free Cisco certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the 350-401 exam.