• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
myBB and CI logins

#1
Hi,

I have a CI website with a login system, that recognises users and admin_users nicely. Admin users can access the admin pages as expected etc.

What I want is to add to the backend for admins only, a myBB forum for internal communication (specifically the exploring of ideas and issues, not chit chat). However I do not want the users to have to log in again.

On a post in the myBB forums it says something like

Quote:If you have an authentication system already in place and want MyBB to authenticate against that, probably the easiest method is to forge a cookie to trick MyBB into thinking a particular use is logged in, via cookies. (set $_COOKIES['mybbuser'] before the session is loaded, example:
PHP Code:
PHP Code:
// assume $uid contains the userid of the user
$user = get_user($uid);
$_COOKIES['mybbuser'] = $user['uid'].'_'.$user['loginkey'];  
Last post in https://community.mybb.com/post-231194.html

Has anyone done this with CI and myBB?

I think I should just install it and try it out. Just thought I would ask for any advice, code snippets or experiences of others before doing it.

Thanks in advance,

Paul

PS If it is too painful I might just do a simple thing myself, but if it is going to be used seriously, I thought why not use myBB as it seems to do an excellent job on the CI site.
Reply

#2
I would be looking at if there are any security issues with doing it that way Paul.
What did you Try? What did you Get? What did you Expect?

Joined CodeIgniter Community 2009.  ( Skype: insitfx )
Reply

#3
I am going to try it this weekend and see what happens. Will bear the security issue in mind of course, but I cannot see another way of doing it. Perhaps tomorrow I will research this again with other forum alternatives too to see if there is a better option.

Thanks for raising the concern though.

Paul.
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.