[prosody-dev] How does internal_hashed auth backend work for new users?

2015-10-19 Thread Pa He
I'm having problems implementing the internal_hashed procedures in ruby. My setup is the following: I have a public-facing prosody 9.3 which does not allow inband registration. I'm writing a Ruby on Rails App which should insert the new users into the postgres DB I setup for prosody account sto

Re: [prosody-dev] How does internal_hashed auth backend work for new users?

2015-10-22 Thread Pa He
x85\xF5[\xB6\xBF\x1E\x8B\xCBm\x1C\x05+\xE3\xCE\xE8P\x06" > [15] pry(main)> Digest::SHA1.digest instance.hexdigest > => "_\xF6\xBB\v_\x88\xA9\x88\xD6\x06\xE7\xDD?\xE0c\xACz\xB9-X" > [16] pry(main)> Digest::SHA1.hexdigest instance2.hexdigest > => &qu

[prosody-dev] Re: How does internal_hashed auth backend work for new users?

2015-10-23 Thread Pa He
Hi Thijs Yes, this indeed helps: i got it working: key = OpenSSL::PKCS5.pbkdf2_hmac_sha1(pass, salt, iter, 20).unpack('H*')[0] > => "a71aacc618c164ccf3efd2ae23b0061919844909" > Gives me the correct saltedpass. Got some help from an old bugreport x) https://redmine.ruby-lang.org/issues/5063 s