vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Disable password reset (https://vborg.vbsupport.ru/showthread.php?t=152587)

patrickb 07-18-2007 05:03 AM

Disable password reset
 
Is there a way to disable password resets?

I am managing my users thourgh a external CMS and I don't want users to change their password.

I've limited the password changing feature with the profile by using the hooks, but is there a way to achieve something similar with the password resets?

G0F0RBR0KE 07-18-2007 05:15 AM

The only way for them not to receive a password is to remove your e-mail from the vb options so it won't send an e-mail when clicking on "Forgotten Password."

patrickb 07-18-2007 06:11 AM

Do you mean the user's email or the webmaster's email (under Admin CP-> VB options->Site Name / URL / Contact Details->Webmaster's Email)?

G0F0RBR0KE 07-18-2007 06:38 AM

The webmaster e-mail.

Once you remove, try to test it your self.

patrickb 07-18-2007 07:08 AM

I'm posting this here in case anybody else needs it in the future.

I basically used the mail_send hook to check the subject. If it matches the one for the lost password recovery, I display an error message.

It might not be the best way to do it, but it works.

PHP Code:

if( $fromemail == $vbulletin->options['webmasteremail'] )
{    
    foreach (
$vbulletin->languagecache as $language)
    {
        eval(
'$' 'lostsubject = "' fetch_phrase('lostpw''emailsubject''emailsubject_'truetrue$language['languageid'], false) . '";' );
        if( 
$subject == $lostsubject )
        {
            eval(
standard_error(fetch_error('password_update_disabled')));
        }
    }



patrickb 08-15-2007 06:34 AM

Can anybody think of a better way to do this? This works...but has an obvious flaw that if there is high activity and notifications on the board, everytime an email is sent out this check will be made!

The only other option that I can think of is to modify the actual source code...


All times are GMT. The time now is 02:35 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.00990 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
  • (1)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)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