diff options
author | Waqas Hussain <waqas20@gmail.com> | 2008-11-28 01:13:34 +0500 |
---|---|---|
committer | Waqas Hussain <waqas20@gmail.com> | 2008-11-28 01:13:34 +0500 |
commit | 85a3bc344309ecd4c1db4dfa5a86c115f7d28cbd (patch) | |
tree | 47c8dc35744a72cd20ee0efc975822e0ac76ecef /core/s2smanager.lua | |
parent | 15153c947cc646c81963f0a319a73e49eab8920f (diff) | |
download | prosody-85a3bc344309ecd4c1db4dfa5a86c115f7d28cbd.tar.gz prosody-85a3bc344309ecd4c1db4dfa5a86c115f7d28cbd.zip |
Switched from md5 to sha256 for dialback key generation
Diffstat (limited to 'core/s2smanager.lua')
-rw-r--r-- | core/s2smanager.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/s2smanager.lua b/core/s2smanager.lua index c584e78b..1cd40aa8 100644 --- a/core/s2smanager.lua +++ b/core/s2smanager.lua @@ -21,7 +21,7 @@ local logger_init = require "util.logger".init; local log = logger_init("s2smanager"); -local md5_hash = require "util.hashes".md5; +local sha256_hash = require "util.hashes".sha256; local dialback_secret = "This is very secret!!! Ha!"; @@ -210,7 +210,7 @@ function initiate_dialback(session) end function generate_dialback(id, to, from) - return md5_hash(id..to..from..dialback_secret); -- FIXME: See XEP-185 and XEP-220 + return sha256_hash(id..to..from..dialback_secret, true); end function verify_dialback(id, to, from, key) |