# Handling password prompt -- IOS\_command module

**URL:** <https://forum.ansible.com/t/handling-password-prompt-ios-command-module/32995>\
**Category:** Ansible Project\
**Created:** [May 21, 2020, 8:06am UTC](https://forum.ansible.com/t/handling-password-prompt-ios-command-module/32995 "2020-05-21T08:06:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pushparaj\_Gothandam](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/pushparaj_gothandam/32/5538_2.png) [@Pushparaj\_Gothandam](https://forum.ansible.com/u/Pushparaj_Gothandam)\
**Post date:** [May 21, 2020, 8:06am UTC](https://forum.ansible.com/t/handling-password-prompt-ios-command-module/32995/1 "2020-05-21T08:06:15Z")

</div>

Hi Team,

How to handle password prompt when doing scp file transfer. Actually server is generating banner message along with password prompt. Please help how to resolve the issue.

- name: transfer the image  
ios\_command:  
commands:
- command: ‘copy scp://{{ ansible\_user }}@{{ ip\_address }}/{{ new\_system\_image }} flash:’  
prompt:
- ‘Destination filename [{{ new\_system\_image }}]’
- ‘Password’  
answer:
- “\r”
- “{{ password }}”

---

<div class="post-metadata">

**Author:** ![Pushparaj\_Gothandam](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/pushparaj_gothandam/32/5538_2.png) [@Pushparaj\_Gothandam](https://forum.ansible.com/u/Pushparaj_Gothandam)\
**Post date:** [May 21, 2020, 6:23pm UTC](https://forum.ansible.com/t/handling-password-prompt-ios-command-module/32995/2 "2020-05-21T18:23:09Z")

</div>

Any help would be appreciated.
