Jump to content




[Solved] [Lua] [PHP] Matching hash Sha1


  • You cannot reply to this topic
1 reply to this topic

#1 darkrising

  • Members
  • 234 posts
  • LocationScotland

Posted 27 June 2013 - 03:20 PM

Hello, I've been playing with sha1 hashing and can't seem to generate a hash match with the same data:

Heres my code:
Lua:
Spoiler

PHP:
Spoiler

Most likely the salt would be stored somewhere on the PHP side, maybe a MySql database but for testing purposes this should work...

(The reason I'm doing this through PHP is a learning curve, I would very much like CC and PHP to play nice together as I have some cool ideas.)

#2 darkrising

  • Members
  • 234 posts
  • LocationScotland

Posted 28 June 2013 - 04:20 AM

I just realised what I did wrong:

Line 12 should be:
"t=" .. str .. "&" ..

Solved!





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users