how can ejabberd run external auth script on windows?
so far- i've modified file
c:\program files\ejabberd-15.06\lib\ejabberd-15.06\priv\cfg\ejabberd.yml
to comment out existing auth_method directive , instead added this:
auth_method: external extauth_program: "d:\\dropbox\\dropbox (personal)\\ejabberd\\auth\\ejabberd-auth.exe" however, when try connect server- see nothing in logs indicating attempt run script. i've tried changing non-existant file see if log error of sort, nothing.
all "accepted connection" type of logs.
in case matters- upon start several "unknown option" errors, including "ejabberd_config:validate_opts:752 unknown option 'auth_method' ignored" - seems known, cosmetic-only error (see: https://github.com/processone/ejabberd/issues/630)
i not use windows, but, should try playing erlang open_port command:
open_port({spawn, "yourcommand"}, [{packet, 2}]). note open_port erlang documentation says:
for external programs, path searched (or equivalent method used find programs, depending on operating system). done invoking shell on platforms. first space separated token of command considered name of executable (or driver). (among other things) makes option unsuitable running programs having spaces in file or directory names.
i see path has spaces. alone should indeed make impossible call command.
that said, external_auth command has never been tested on windows. may need patch ejabberd command make authentication through external process work. surprised if works is.
Comments
Post a Comment