vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Question about password hash (https://vborg.vbsupport.ru/showthread.php?t=150352)

monster64 06-22-2007 03:35 AM

Question about password hash
 
Before I switched to vbulletin, I was using phpbb. I had coded a login system in C++ where the user could enter their forum username and password, and then if they were in a paid subscription group, they could use the software. It used mysql apis to retrieve information from the database. Now phpbb encoded their passwords with an md5 algorithm. Since the algorithm generates the same hash on any programming language, I hashed the password the user typed in from C++, then compared it with the already hashed password stored on the server, and if they matched, the user could log in and continue with the authentication process. Now when I switched to VB, I made some minor changes for the new tables etc, however I can't log in. Looking at the database and then around this forum, I realize that VB doesn't use just an md5 hash to encrypt the password. Does anyone know what algorithm VB uses in addition to md5, and if its available to the public?

If I can't obtain the algorithm they use, could I just make VB encrypt the password with md5 only?

Dismounted 06-22-2007 05:15 AM

If you only looked around for it......
PHP Code:

md5(md5($password) . $salt


Mac_Cross 06-22-2007 07:59 AM

is it possible that vb generate the password in the 3.6.7 version different?

--- my fault, you can delete it - sorry

monster64 06-22-2007 01:43 PM

So it md5s the password, uses the salt function on it, then md5s the whole thing? I got that, but where is the salt function itself?

Dismounted 06-23-2007 02:15 AM

Look in the user table, there's a field called salt.

monster64 06-23-2007 01:49 PM

Got it working again, thanks. The salt function vbulletin uses concats the salt to the end of the md5 hashed password, then md5 hashes it again, if anyone is curious.

Dismounted 06-24-2007 05:07 AM

Which is exactly what I posted a few posts up.
PHP Code:

md5(md5($password) . $salt


monster64 06-26-2007 08:01 PM

Didn?t know exactly what .$salt did :o

Dismounted 06-27-2007 08:34 AM

. (dot) is the concatenation character in PHP.


All times are GMT. The time now is 06:32 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01427 seconds
  • Memory Usage 1,721KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (9)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete