Yet another fix for the makefile :)
[prosody.git] / util / sasl.lua
index f10fb934234d7887df3044c436029f0e27862f5d..f1d01aedd1b1cddf4bf956eaa2aee725783e0639 100644 (file)
@@ -11,7 +11,7 @@ local math = require "math"
 local type = type
 local error = error
 local print = print
-local idna_ascii = require "util.encodings".stringprep.saslprep.to_ascii
+local idna_ascii = require "util.encodings".idna.to_ascii
 
 module "sasl"
 
@@ -67,7 +67,7 @@ local function new_digest_md5(realm, password_handler)
        
        local function parse(data)
                message = {}
-               for k, v in gmatch(data, [[([%w%-]+)="?([%w%-%/%.%+=]+)"?,?]]) do
+               for k, v in gmatch(data, [[([%w%-]+)="?([^",]*)"?,?]]) do -- FIXME The hacky regex makes me shudder
                        message[k] = v
                end
                return message