~ubuntu-branches/ubuntu/trusty/ejabberd/trusty-proposed

« back to all changes in this revision

Viewing changes to src/cyrsasl.erl

  • Committer: Bazaar Package Importer
  • Author(s): Gerfried Fuchs, Konstantin Khomoutov, Gerfried Fuchs
  • Date: 2009-12-04 18:22:49 UTC
  • mfrom: (1.1.11 upstream)
  • Revision ID: james.westby@ubuntu.com-20091204182249-6jfmdz8878h7oaos
Tags: 2.1.0-1
[ Konstantin Khomoutov ]
* New upstream release (Closes: #519858).
  This also adds support for LDAPS upstream (Closes: #526145).
* Do not depend on cdbs anymore, port debian/rules to dh+quilt,
  remove build dependency on patchutils, use erlang-depends.
* Bump debhelper version to 7, standards base to 3.8.3
* Depend on erlang R13B.
* Recommend imagemagick (for captcha support).
* Remove deprecated patches (ssl.patch patch, dynamic_compile_loglevel.patch,
  ldaps.patch, update.patch, proxy.patch, caps.patch, convert.patch,
  s2s.patch).
* Replace mod_ctlextra with mod_admin_extra.
* Use upstream inetrc file.
* Bring debian/ejabberd.cfg and ejabberdctl in sync with upstream.
* Update ejabberdctl manual page.
* Provide NEWS file.
* Rework README.Debian:
  * Group all information into sections.
  * Describe issues with epam binary (Closes: #502791).
  * Discuss how to use DBMS backends (Closes: #540915, #507144).
  * Discuss upgrading from 2.0.x series.
* Implement PID file management (Closes: #519858).
* Make logrotate process all files matching "*.log".
* Improve init script:
  * Make init script LSB-compliant.
  * Implement "live" target which allows to run ejabberd in foreground.
* Make captcha.sh use bash explicitly.
* Rework node-generation for ejabberdctl to fix ejabberd's atom table
  overflows while preserving the possibility to run several versions
  of ejabberdctl concurrently as before.
* Add webadmin patch restoring compatibility with Erlang/OTP <= R12B-4.
* Integrate upstream patch for EJAB-1106.
* Add upstream patch for EJAB-1098.
* Add upstream patch for EJAB-1045.
* Add Konstantin Khomoutov to uploaders.
* Add Japanese debconf translation (thanks to Hideki Yamane)
  (Closes: #558071).

[ Gerfried Fuchs ]
* Build-Depend on po-debconf so po2debconf can be called.

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
-export([start/0,
31
31
         register_mechanism/3,
32
32
         listmech/1,
33
 
         server_new/6,
 
33
         server_new/7,
34
34
         server_start/3,
35
35
         server_step/2]).
36
36
 
37
37
-record(sasl_mechanism, {mechanism, module, require_plain_password}).
38
38
-record(sasl_state, {service, myname, realm,
39
 
                     get_password, check_password,
 
39
                     get_password, check_password, check_password_digest,
40
40
                     mech_mod, mech_state}).
41
41
 
42
42
-export([behaviour_info/1]).
43
43
 
44
44
behaviour_info(callbacks) ->
45
 
    [{mech_new, 3}, {mech_step, 2}];
 
45
    [{mech_new, 4}, {mech_step, 2}];
46
46
behaviour_info(_Other) ->
47
47
    undefined.
48
48
 
113
113
    filter_anonymous(Host, Mechs).
114
114
 
115
115
server_new(Service, ServerFQDN, UserRealm, _SecFlags,
116
 
           GetPassword, CheckPassword) ->
 
116
           GetPassword, CheckPassword, CheckPasswordDigest) ->
117
117
    #sasl_state{service = Service,
118
118
                myname = ServerFQDN,
119
119
                realm = UserRealm,
120
120
                get_password = GetPassword,
121
 
                check_password = CheckPassword}.
 
121
                check_password = CheckPassword,
 
122
                check_password_digest= CheckPasswordDigest}.
122
123
 
123
124
server_start(State, Mech, ClientIn) ->
124
125
    case lists:member(Mech, listmech(State#sasl_state.myname)) of
128
129
                    {ok, MechState} = Module:mech_new(
129
130
                                        State#sasl_state.myname,
130
131
                                        State#sasl_state.get_password,
131
 
                                        State#sasl_state.check_password),
 
132
                                        State#sasl_state.check_password,
 
133
                                        State#sasl_state.check_password_digest),
132
134
                    server_step(State#sasl_state{mech_mod = Module,
133
135
                                                 mech_state = MechState},
134
136
                                ClientIn);