-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
ejabberd_http crash when listening on unix socket #3894
Comments
Thanks for reporting! As you noticed, it seems the problem was introduced when support for unix socket was added in that function in e937ff6, but this case was not considered.
I don't think so, as |
Doesn’t |
Oops, you're right! 🤦♂️ I'll simplify it |
Environment
Configuration (only if needed): grep -Ev '^$|^\s*#' ejabberd.yml
Errors from error.log/crash.log
Bug description
It looks like
analyze_ip_xff
expects the first argument to be of the form{IPAdress, Port}
(which is the case for TCP connections), but it’s wrong for Unix connections : the first argument is{local, <<>>}
. Adding aip_to_list(local) -> <<"unix">>;
clause to misc.erl seems to fix the issue (and can probably replace theip_to_list({local, _})
clause).The text was updated successfully, but these errors were encountered: