vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Best method of identifying users from the db? (https://vborg.vbsupport.ru/showthread.php?t=137170)

Sykoi 01-21-2007 08:30 PM

Best method of identifying users from the db?
 
I need to find a method to confirm a user is who they say they are from another site, by checking the vB_user table, from a site outside of vBulletin's architecture... Now I was going to have them enter their user id, and a hidden profile key they pick themselves, but I'm not sure if this is such a great idea... What would be a good idea?

Could I just confirm it with id, md5(md5(password,$salt)) or whatever password protection method vBulletin uses?

Attilitus 01-21-2007 09:25 PM

Well additional information would be useful. Such as the degree of access that you have to the external database.

Adrian Schneider 01-21-2007 09:28 PM

Check their username/password against the vB. database.

select userid
from user
where username = 'usetname sent' and password = md5(concat(md5('password sent'), salt));

Sykoi 01-21-2007 09:31 PM

So...
PHP Code:

SELECT from vb3_user WHERE userid=### AND password=md5(concat(md5(password),vb3_user.salt)) 

Is this correct? Or are you referring to php functions of md5/concat and not mysql (Is concat even in mysql...?)

And as for the extent at which I have access, I have complete access to the database but no access to the vB php files.

Also, while I have asked this before I'll ask again - is there any way to create a forum "blindly", as in outside the architecture? I looked at the forums table and its incredibly complex and requires some vB-only generated things.

Adrian Schneider 01-21-2007 09:33 PM

Do it in MySQL, it is simpler that way (my query should work). Get them to enter their username - not their userid. You can change my select userid to select *

Sykoi 01-22-2007 03:07 AM

Well my problem with entering a user's name is that ... Is, well - easy to screw up... A lot of my forum members have unicode in their name, spaces in their name, etc.... Things that are easy to mess up

Adrian Schneider 01-22-2007 03:09 AM

Well how do they sign-on in the first place? :)

Userid is easy too, simple enough to change that in the above query...

Sykoi 01-22-2007 03:12 AM

Good point... Guess userid is kind of hard for some people to get, although my concern was the people (Like myself) who click "Remember me"... I haven't logged in for almost a year :P

Anyways, on a related note - whats the best way to create a new forum blindly?:
Quote:

Also, while I have asked this before I'll ask again - is there any way to create a forum "blindly", as in outside the architecture? I looked at the forums table and its incredibly complex and requires some vB-only generated things.

Adrian Schneider 01-22-2007 03:16 AM

I don't have the time to go into much detail, but you could take the array that vBulletin generates and share that with your other site (save as .php file using var_export or serialized array). That would make it easier to process.

Sykoi 01-22-2007 03:18 AM

So basically get the function in the admin area to generate a new forum, use it to generate a dummy forum with the permissions I need, access the data inside that (Securely with a keycode or something) using readfile or fopen, unserialize the array, and simply replace the variables I need and commit that to the database...?


All times are GMT. The time now is 09:44 AM.

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.01843 seconds
  • Memory Usage 1,736KB
  • 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
  • (1)bbcode_php_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete