Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xcauth not working in Docker container #83

Closed
krzysztofgal opened this issue Sep 18, 2019 · 4 comments
Closed

xcauth not working in Docker container #83

krzysztofgal opened this issue Sep 18, 2019 · 4 comments

Comments

@krzysztofgal
Copy link

Hi, I tried to run this service with debian:latest and ubuntu:19.04 based docker containers.
ejabberd log Failed to start external authentication program 'xcauth'.
I get following error on cmd: xcauth -i

2019-09-18 17:18:08,601 DEBUG: Opening database connections main=/var/lib/xcauth/xcauth.sqlite3, cache=none Traceback (most recent call last): File "/usr/sbin/xcauth", line 17, in <module> perform(args) File "/usr/lib/python3/dist-packages/xclib/authops.py", line 104, in perform s = socket.socket(fileno=stdinfd) File "/usr/lib/python3.7/socket.py", line 151, in __init__ _socket.socket.__init__(self, family, type, proto, fileno) OSError: [Errno 88] Socket operation on non-socket: 'family'

installing xcauth with deb package by apt.

@MarcelWaldvogel
Copy link
Contributor

This seems like it mistakenly believes to be started from systemd with socket activation.

Could you please tell more about the configuration? /etc/xcauth.conf, environment variables, (log) output with debug enabled (debug in /etc/xcauth.conf or --debug on the command line)?

@krzysztofgal
Copy link
Author

/etc/xcauth.conf
type=ejabberd secret=xxx url=xxx log=/var/log/xcauth debug

# xcauth -i --debug
2019-09-19 08:47:26,994 DEBUG: Start external auth script 2.0.3+ for ejabberd with endpoint: https://xx.xx/index.php/apps/ojsxc/ajax/externalApi.php
2019-09-19 08:47:26,994 DEBUG: Opening database connections main=/var/lib/xcauth/xcauth.sqlite3, cache=none
2019-09-19 08:47:26,994 INFO: Initializing /var/lib/xcauth/xcauth.sqlite3 from None, None, and None
2019-09-19 08:47:26,994 DEBUG: Upgrading domain from None
2019-09-19 08:47:27,011 DEBUG: Creating cache table in <xclib.db.sq3c_debugger object at 0x7f4466496678>
2019-09-19 08:47:27,028 DEBUG: Upgrading cache from None
2019-09-19 08:47:27,028 DEBUG: Upgrading roster from None
Traceback (most recent call last): File "/usr/sbin/xcauth", line 17, in <module> perform(args) File "/usr/lib/python3/dist-packages/xclib/authops.py", line 104, in perform s = socket.socket(fileno=stdinfd) File "/usr/lib/python3.7/socket.py", line 151, in __init__ _socket.socket.__init__(self, family, type, proto, fileno) OSError: [Errno 88] Socket operation on non-socket: 'family'

# env
HOSTNAME=16dba53cf913 PWD=/ HOME=/root TERM=xterm SHLVL=1 PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin DEBIAN_FRONTEND=noninteractive _=/usr/bin/env

No log file created for xcauth.

@MarcelWaldvogel
Copy link
Contributor

Thanks! I can reproduce the problem and am looking into it. Stay tuned ;-)

@MarcelWaldvogel
Copy link
Contributor

Fixed in 4f77d65; released 2.0.4. You should be able to apt update/upgrade in a few minutes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants