# Can't use ansible with user/password if keyfile exists

**URL:** <https://forum.ansible.com/t/cant-use-ansible-with-user-password-if-keyfile-exists/23805>\
**Category:** Ansible Project\
**Created:** [February 24, 2017, 10:24am UTC](https://forum.ansible.com/t/cant-use-ansible-with-user-password-if-keyfile-exists/23805 "2017-02-24T10:24:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Andreas\_Goetz](https://avatars.discourse-cdn.com/v4/letter/a/5f8ce5/32.png) [@Andreas\_Goetz](https://forum.ansible.com/u/Andreas_Goetz)\
**Post date:** [February 24, 2017, 10:24am UTC](https://forum.ansible.com/t/cant-use-ansible-with-user-password-if-keyfile-exists/23805/1 "2017-02-24T10:24:22Z")

</div>

In [https://github.com/ansible/ansible/issues/21867](https://github.com/ansible/ansible/issues/21867) I’ve noticed that ansible ignores the -u user -k parameters if a keyfile exists (in my case an unusable 1023bits key) and still insists on using that key.

I anybody able to confirm this bug or am I doing something completely wrong (being a newbie)?

Thanks,  
Andreas
