apple / ccs-pykerberos

Python Kerberos library used by CalendarServer
https://www.calendarserver.org
Apache License 2.0
117 stars 65 forks source link

windows authentication giving error "kerberos: Bad HTTP response returned from server. Code 500" in new virtual environment | Ansible #84

Open aayj opened 4 years ago

aayj commented 4 years ago

We are creating new virtual environment but experiencing failure on windows host with kerberos error while the same playbook works in older virtual environment with same ansible version. All the required packages and dependencies have been installed in both environments.

Error -> fatal: [w096440.cgftdev.com]: UNREACHABLE! => { "changed": false, "msg": "kerberos: Bad HTTP response returned from server. Code 500", "unreachable": true }

Expected output -> [w096440.cgftdev.com] => { "changed": false, "invocation": { "module_args": { "data": "pong" } }, "ping": "pong"

alehaa commented 3 years ago

Same error on macOS 10.15.7 with kerberos 1.3.1 when connecting via HTTP. However, the module states it has no support for message encryption, which should be available since version 1.2.1?

~:$ python -c "import kerberos; print(hasattr(kerberos, 'authGSSWinRMEncryptMessage'))"
False
tricon commented 2 years ago

This library does not support authGSSWinRMEncryptMessage. The following library is needed for Ansible + WinRM: https://pypi.org/project/pykerberos (pykerberos as opposed to kerberos, in which the latter is represented by this code base).

Felix-neko commented 2 years ago

@aayj , how did you install kerberos python package under windows?