vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   AminCP: Restrict other administrator's access to certain files (https://vborg.vbsupport.ru/showthread.php?t=45824)

rake 11-16-2002 10:00 PM

AminCP: Restrict other administrator's access to certain files
 
If you have members that you would like to give cp access to, but don't trust them with your templates, or vbhacker et cetera, this is the thing for you. You can restrict access to certain files, based on userid. They will still see the options in the menu, but will not be able to access them.

if((strchr($PHP_SELF,"admin/template.php") || strchr($PHP_SELF,"admin/style.php") || strchr($PHP_SELF,"admin/replacement.php") || strchr($PHP_SELF,"admin/backup.php") || strchr($PHP_SELF,"admin/misc.php") || strchr($PHP_SELF,"admin/vbhacker.php") || strchr($PHP_SELF,"admin/query.php") || strchr($PHP_SELF,"admin/pm.php")) && $bbuserinfo[userid]!="1") {
show_nopermission();
}

Add the code above at the end of your sessions.php file, just above the ?> line. Modify the code in any way you wish. It's just a quick & dirty way of removing certain administrator priviledges. Be careful! sessions.php is used for ALL vbulletin files.

Remi 11-17-2002 06:36 PM

Hi

Can I use something like this to include all files:

PHP_SELF,"admin/*.php

Thanks

rake 11-17-2002 06:46 PM

excluding all files wouldn't make sense. You would totally lock him out.

N!ck 11-17-2002 07:11 PM

this has already been done by hellsatan

suffeks 11-26-2002 05:33 PM

this hack was exactly what i was looking for, i didnt need that complex super mod hack, anyway, is it possible to make this more specific? i'm a newb at this, this is what i mean:

Code:

strchr($PHP_SELF,"admin/user.php?action=modify&s=$session")
i probably have it wrong because it doesnt work, but i'd like to break it down further as so.

help?!

thanks


All times are GMT. The time now is 08:39 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.00949 seconds
  • Memory Usage 1,711KB
  • 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_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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