Go Back   vb.org Archive > vBulletin Modifications > vBulletin 5.x Modifications > vBulletin 5.x Products & Extensions

Reply
 
Thread Tools
Duckways: Admin - Log in as Details »»
Duckways: Admin - Log in as
Version: 1.0.0, by Jorandh Jorandh is offline
Developer Last Online: Oct 2022 Show Printable Version Email this Page

Category: Add-On Releases - Version: 5.4.x Rating:
Released: 07-12-2018 Last Update: Never Installs: 44
Uses Plugins Auto-Templates
Additional Files Translations  
No support by the author.


Admin - Log in as



What is this mod all about?

Sometimes it comes in handy to access the account of one of your users. To fix issues, to debug or whatever. This plugin shows an "Log in as" button on the profile page for admins and super moderators. When clicked your session will be set to log in as the other user without filling in a password.


Button on profile page (only visible for admin and super moderator):





About Duckways

We're a company with a team of developers who have been working a lot on a vBulletin 4 system for two of our customers. The largest one with over 200,000 users and 4 million posts.
This one migrated to vBulletin 5 recently and we've faced quite some issues in vBulletin 5 which we'll fix by writing custom modifications. Some of those, which are worth sharing, will be added here on vBulletin.org. If you're missing a feature or add-on, please feel free to contact us.


How to install:

- Download the zip file below

- Upload the content of the upload folder to your vBulletin root.

- Install the XML by importing it as a new product.



Version history
  • 1.0.0 - Initial release



Support

Please use this thread to ask questions or to report bugs.

Download Now

File Type: zip Duckways - Admin login as.zip (14.4 KB, 231 views)

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
2 благодарности(ей) от:
Chris Tucker, ka99

Comments
  #22  
Old 10-02-2019, 05:03 PM
CQ2 CQ2 is offline
 
Join Date: Feb 2008
Posts: 14
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hi

Installed on vB5.5.4 and the hook was showing on all user groups. How can I fix this?

Thanks
Reply With Quote
  #23  
Old 10-14-2019, 11:27 AM
panzerscope panzerscope is offline
 
Join Date: Feb 2019
Posts: 2
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CQ2 View Post
Hi

Installed on vB5.5.4 and the hook was showing on all user groups. How can I fix this?

Thanks
I have sent a PM to the dev who made this. Hopefully we see a response.
Reply With Quote
  #24  
Old 12-05-2019, 04:42 PM
Artes_Marciales Artes_Marciales is offline
 
Join Date: Jun 2007
Posts: 278
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I love this MOD but I think it doesn't work in vB5.5.5

I hope they make it compatible with vb 5.5.5

Thanks!
Reply With Quote
  #25  
Old 04-04-2020, 11:56 AM
CQ2 CQ2 is offline
 
Join Date: Feb 2008
Posts: 14
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just too sad vBulletin makes it next to impossible to create useful tools and hooks.
I regret I was stupid enough to "upgrade" from vB3 and buy a vB5 license.

Lesson learnt and never ever again I will waste my money for another "great" upgrade.

It is obvious the coding has been set to prevent any third party to be applied as it used to when hardly any hooks works anymore yet new to come.

Thank you to all of you guys who have brought us all the fun over the years.

And to the vBulletin - You really suck in caring for your customers. Not even a default chatbox
available. :down:

CQ2
Reply With Quote
Благодарность от:
clauz
  #26  
Old 04-05-2020, 09:28 AM
clauz's Avatar
clauz clauz is offline
 
Join Date: Dec 2010
Posts: 81
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CQ2 View Post
Just too sad vBulletin makes it next to impossible to create useful tools and hooks.
I regret I was stupid enough to "upgrade" from vB3 and buy a vB5 license.

Lesson learnt and never ever again I will waste my money for another "great" upgrade.

It is obvious the coding has been set to prevent any third party to be applied as it used to when hardly any hooks works anymore yet new to come.

Thank you to all of you guys who have brought us all the fun over the years.

And to the vBulletin - You really suck in caring for your customers. Not even a default chatbox
available. :down:

CQ2
I totally agree.
Since 8 years (I guess VB5 was released in 2012) VB5 is still an incomplete software.
No major improvements, not even 10% of VB4 options are available for VB5.
After 8 years!
Reply With Quote
Благодарность от:
yilmaz
  #27  
Old 09-04-2020, 02:59 AM
yilmaz's Avatar
yilmaz yilmaz is offline
 
Join Date: Sep 2004
Posts: 751
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

It will work if you do this in vB5.6.x

File to be edited reauth.php
file path
core/packages/duckwaysloginas/admin/reauth.php

Find

Code:
vB5_Auth::doLoginRedirect();
Replace it with
Code:
$referrer = $_SERVER['HTTP_REFERER'];
header('Location: '.$referrer.'');
done
Reply With Quote
  #28  
Old 09-09-2020, 11:28 AM
RUBE RUBE is offline
 
Join Date: Jun 2017
Posts: 5
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hello,

It works fine on VB Version 5.6.3 after doing the edit mentioned above on the reauth.php file.

Have a Nice Day!
RUBE
Reply With Quote
2 благодарности(ей) от:
DamasGate, yilmaz
  #29  
Old 03-08-2021, 09:51 AM
CQ2 CQ2 is offline
 
Join Date: Feb 2008
Posts: 14
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by yilmaz View Post
It will work if you do this in vB5.6.x

File to be edited reauth.php
file path
core/packages/duckwaysloginas/admin/reauth.php

Find

Code:
vB5_Auth::doLoginRedirect();
Replace it with
Code:
$referrer = $_SERVER['HTTP_REFERER'];
header('Location: '.$referrer.'');
done

Much obliged yilmaz

I will make another attempt and use the fix you have provided. However my over all impression of vB5 is I have been sold the "cat in the bag"

CQ2
Reply With Quote
Благодарность от:
Chicoynano
  #30  
Old 03-08-2021, 06:47 PM
yilmaz's Avatar
yilmaz yilmaz is offline
 
Join Date: Sep 2004
Posts: 751
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CQ2 View Post
Much obliged yilmaz

I will make another attempt and use the fix you have provided. However my over all impression of vB5 is I have been sold the "cat in the bag"

CQ2
This is more practical

PHP Code:
<?php

define
('CSRF_PROTECTION'false);

$currentSession vB_Api::instance('user')->fetchUserinfo();

// Let's log off and log in to a new account
if ( isset ( $_GET['userid'] )
    && 
can_administer()
    && 
is_member_of($currentSession, [ ] ) )
{
    
$user = (object)vB_Api::instance('user')->fetchUserinfo$_GET['userid'] );

    
vB::getDbAssertor()->delete('session', array('sessionhash' => vB::getCurrentSession()->get('dbsessionhash')));
    
$username vB_String::htmlSpecialCharsUni$user->username );
    
$userinfo vB::getDbAssertor()->getRow('user', array('userid' => $user->userid));
    
$auth array_intersect_key($userinfoarray_flip(['userid''lastvisit''lastactivity']));
    
$loginInfo vB_User::processNewLogin($auth'');
    
vB5_Auth::setLoginCookies($loginInfo''false);
    
$url unhtmlspecialchars($vbulletin->url);
            
print_cp_redirect_old($url);

    die();
}
Attached Files
File Type: php reauth.php (898 Bytes, 13 views)
Reply With Quote
Благодарность от:
Chicoynano
  #31  
Old 03-11-2021, 08:17 PM
migratoria migratoria is offline
 
Join Date: Oct 2011
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
This is more practical
Thank you
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:33 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.09145 seconds
  • Memory Usage 2,361KB
  • Queries Executed 28 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (4)bbcode_code
  • (1)bbcode_php
  • (5)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (8)post_thanks_box_bit
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (6)post_thanks_postbit
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (2)postbit_attachment
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete