aboutsummaryrefslogtreecommitdiff
path: root/src/cyrsasl_digest.erl
diff options
context:
space:
mode:
Diffstat (limited to 'src/cyrsasl_digest.erl')
-rw-r--r--src/cyrsasl_digest.erl10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/cyrsasl_digest.erl b/src/cyrsasl_digest.erl
index 12e5555a1..e58cb3035 100644
--- a/src/cyrsasl_digest.erl
+++ b/src/cyrsasl_digest.erl
@@ -5,7 +5,7 @@
%%% Created : 11 Mar 2003 by Alexey Shchepin <alexey@sevcom.net>
%%%
%%%
-%%% ejabberd, Copyright (C) 2002-2015 ProcessOne
+%%% ejabberd, Copyright (C) 2002-2016 ProcessOne
%%%
%%% This program is free software; you can redistribute it and/or
%%% modify it under the terms of the GNU General Public License as
@@ -25,9 +25,12 @@
-module(cyrsasl_digest).
+-behaviour(ejabberd_config).
+
-author('alexey@sevcom.net').
--export([start/1, stop/0, mech_new/4, mech_step/2, parse/1]).
+-export([start/1, stop/0, mech_new/4, mech_step/2,
+ parse/1, opt_type/1]).
-include("ejabberd.hrl").
-include("logger.hrl").
@@ -256,3 +259,6 @@ response(KeyVals, User, Passwd, Nonce, AuthzId,
":", NC/binary, ":", CNonce/binary, ":", QOP/binary,
":", (hex((erlang:md5(A2))))/binary>>,
hex((erlang:md5(T))).
+
+opt_type(fqdn) -> fun iolist_to_binary/1;
+opt_type(_) -> [fqdn].