# WinRM with Ansible 2.8 and Python 3.7

**URL:** <https://forum.ansible.com/t/winrm-with-ansible-2-8-and-python-3-7/31565>\
**Category:** Ansible Project\
**Created:** [October 29, 2019, 8:56pm UTC](https://forum.ansible.com/t/winrm-with-ansible-2-8-and-python-3-7/31565 "2019-10-29T20:56:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Subhi\_Andrews](https://avatars.discourse-cdn.com/v4/letter/s/bb73d2/32.png) [@Subhi\_Andrews](https://forum.ansible.com/u/Subhi_Andrews)\
**Post date:** [October 29, 2019, 8:56pm UTC](https://forum.ansible.com/t/winrm-with-ansible-2-8-and-python-3-7/31565/1 "2019-10-29T20:56:17Z")

</div>

We have been using Python 2.7 and Ansible 2.7 so far successfully. Just trying to test Ansible 2.8.6 with Python 3.7.5.

I am getting the following error:

pfny5devops03 | UNREACHABLE! =\> {  
“changed”: false,  
“msg”: “kerberos: message encryption is set to ‘always’ but the selected auth method kerberos does not support it”,  
“unreachable”: true  
}

This works fine with an ansible controller that has Python 2.7 and Ansible 2.7 installed.

These are some of our winrm configuration:

ansible\_port: 5986  
ansible\_connection: winrm  
ansible\_winrm\_transport: kerberos  
ansible\_winrm\_server\_cert\_validation: ignore  
**ansible\_winrm\_message\_encryption: always**  
ansible\_winrm\_kerberos\_delegation: true  
ansible\_winrm\_operation\_timeout\_sec: 60  
ansible\_winrm\_read\_timeout\_sec: 90

Does anyone know what’s missing?

Thanks,  
Subhi.

---

<div class="post-metadata">

**Author:** ![Subhi\_Andrews](https://avatars.discourse-cdn.com/v4/letter/s/bb73d2/32.png) [@Subhi\_Andrews](https://forum.ansible.com/u/Subhi_Andrews)\
**Post date:** [October 30, 2019, 1:58pm UTC](https://forum.ansible.com/t/winrm-with-ansible-2-8-and-python-3-7/31565/2 "2019-10-30T13:58:58Z")

</div>

When _ansible\_winrm\_message\_encryption: auto_, it works. It used to work with Python 2.7 and Ansible 2.7 when _ansible\_winrm\_message\_encryption: always_ was the setting.

---

<div class="post-metadata">

**Author:** ![Vikrant](https://avatars.discourse-cdn.com/v4/letter/v/cc9497/32.png) [@Vikrant](https://forum.ansible.com/u/Vikrant)\
**Post date:** [October 30, 2019, 5:24pm UTC](https://forum.ansible.com/t/winrm-with-ansible-2-8-and-python-3-7/31565/3 "2019-10-30T17:24:05Z")

</div>

I’m using below setting and these are working as expected:

ansible\_port: “5985”  
ansible\_connection: “winrm”  
ansible\_winrm\_scheme: “http”  
ansible\_winrm\_transport: “kerberos”  
ansible\_winrm\_server\_cert\_validation: “ignore”  
ansible\_winrm\_operation\_timeout\_sec: 20  
ansible\_winrm\_read\_timeout\_sec: 30
