# windows 2012 server SSL authentication

**URL:** <https://forum.ansible.com/t/windows-2012-server-ssl-authentication/24487>\
**Category:** Ansible Project\
**Tags:** windows\
**Created:** [May 15, 2017, 6:35pm UTC](https://forum.ansible.com/t/windows-2012-server-ssl-authentication/24487 "2017-05-15T18:35:55Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Hamdi\_Ben\_Zekri](https://avatars.discourse-cdn.com/v4/letter/h/3e96dc/32.png) [@Hamdi\_Ben\_Zekri](https://forum.ansible.com/u/Hamdi_Ben_Zekri)\
**Post date:** [May 15, 2017, 6:35pm UTC](https://forum.ansible.com/t/windows-2012-server-ssl-authentication/24487/1 "2017-05-15T18:35:55Z")

</div>

Hello,

I have followed all the steps in this tutorial: [http://www.hurryupandwait.io/blog/certificate-password-less-based-authentication-in-winrm](http://www.hurryupandwait.io/blog/certificate-password-less-based-authentication-in-winrm)  
to setup a passwordless ssl based authentication between a centos 7 local VM (where ansible is installed) and a Windows 10 VM and it works perfectly.  
The problem is when I tried to execute the same steps on a Windows 2012 server (the development server) it failed when executing the mapping command:

New-Item -Path WSMan:\localhost\ClientCertifcate -Subject \* -Issuer 7C8… -Credential (Get-Credential) -Force

the error indicated that it couldn’t do the mapping because it couldn’t find the certificate in the certificate store (I’m sure that the certificate is in the right place).

please any help, I have been stuck int this step for months now.

---

<div class="post-metadata">

**Author:** ![Trond\_Hindenes](https://avatars.discourse-cdn.com/v4/letter/t/96bed5/32.png) [@Trond\_Hindenes](https://forum.ansible.com/u/Trond_Hindenes)\
**Post date:** [May 16, 2017, 10:23pm UTC](https://forum.ansible.com/t/windows-2012-server-ssl-authentication/24487/2 "2017-05-16T22:23:04Z")

</div>

Did you make sure the certificate on your Windows 2012 box contains the private key (In Windows it should say something along the lines of “You have a private key for this certificate” or similar).

---

<div class="post-metadata">

**Author:** ![Hamdi\_Ben\_Zekri](https://avatars.discourse-cdn.com/v4/letter/h/3e96dc/32.png) [@Hamdi\_Ben\_Zekri](https://forum.ansible.com/u/Hamdi_Ben_Zekri)\
**Post date:** [May 31, 2017, 8:06pm UTC](https://forum.ansible.com/t/windows-2012-server-ssl-authentication/24487/3 "2017-05-31T20:06:49Z")

</div>

Thank you for the response,  
It was not the issue but It’s fixed now

---

<div class="post-metadata">

**Author:** ![Dick\_Visser](https://avatars.discourse-cdn.com/v4/letter/d/d9b06d/32.png) [@Dick\_Visser](https://forum.ansible.com/u/Dick_Visser)\
**Post date:** [June 1, 2017, 9:56am UTC](https://forum.ansible.com/t/windows-2012-server-ssl-authentication/24487/4 "2017-06-01T09:56:11Z")

</div>

Great news!  
Can you please share what was the problem and how you fixed it - so other people can benefit from it?

Thanks

---

<div class="post-metadata">

**Author:** ![Hamdi\_Ben\_Zekri](https://avatars.discourse-cdn.com/v4/letter/h/3e96dc/32.png) [@Hamdi\_Ben\_Zekri](https://forum.ansible.com/u/Hamdi_Ben_Zekri)\
**Post date:** [June 1, 2017, 1:50pm UTC](https://forum.ansible.com/t/windows-2012-server-ssl-authentication/24487/5 "2017-06-01T13:50:47Z")

</div>

Sure, It’s kind of stupid,  
Windows couldn’t execute the mapping because the current user (the one that generated and installed the self signed cert) does not have the privelege to find the other users certificates.  
It was fixed by installing the certificate (the ansible user certificate) globally.
