mirror of
https://github.com/processone/ejabberd.git
synced 2024-11-20 16:15:59 +01:00
Match ldap_uidattr_format case-insensitively (EJAB-1449)
This commit is contained in:
parent
6cc6c04c4a
commit
35644cf73c
@ -95,7 +95,14 @@ get_user_part(String, Pattern) ->
|
|||||||
{error, badmatch};
|
{error, badmatch};
|
||||||
Result ->
|
Result ->
|
||||||
case regexp:sub(Pattern, "%u", Result) of
|
case regexp:sub(Pattern, "%u", Result) of
|
||||||
{ok, String, _} -> {ok, Result};
|
{ok, StringRes, _} ->
|
||||||
|
case (string:to_lower(StringRes) ==
|
||||||
|
string:to_lower(String)) of
|
||||||
|
true ->
|
||||||
|
{ok, Result};
|
||||||
|
false ->
|
||||||
|
{error, badmatch}
|
||||||
|
end;
|
||||||
_ -> {error, badmatch}
|
_ -> {error, badmatch}
|
||||||
end
|
end
|
||||||
end.
|
end.
|
||||||
|
Loading…
Reference in New Issue
Block a user