PDA

View Full Version : EP-Dev CMS Forum Member Hack 1.20 BETA



Patrick
06-10-2006, 12:37 AM
After taking forever I have finally updated CMS Forum Member Hack. I stopped work on 2.x version of this a few weeks ago in plans to update 1.x version using existing framework.

Thus I have updated the hack to version 1.20 BETA. I still consider it a beta because I have not completed extensive testing on the new code (Never-the-less, I have done some basic testing with local installs).

If you wish to test this, I suggest making a backup of any files that this script tells you to chmod (with exception of script's own files). That way even if the uninstall fails for some reason, you are not screwed (where you then have to go and manually edit files). I also strongly recommend backing up your forum and cms database(s). If you do not, a botched merging of the users could leave you fairly angry.

What's New
- Restructured modules folder.
- Added support for IPB 2.1 and e107 0.7.5.
- Touched up install / uninstall displays and text. Also added database warning.
- Fixed search / replace text during install not properly converting html entities.
- Updated and added better detection of default configurations.
- Modified configuration to be class. Global no longer used.
- Updated MySQL access module to prevent sql injection attacks. Only e107 0.7.5 and IPB 2.1 have been updated to use safe access (other versions of CMS / Forum already suffer from multiple vulnerabilities).
- Renamed most general functions in CMS / Forum modules to be more programmer-friendly.

Things I need people to test
- Merging users for new modules.
- Forgot Password link (ensure that it updates password for both CMS and forum once password it is reset).

I have tested most of the other functionality and have had it working on local installs. However, each setup varies so who knows what could arise.

What about the planned redirection feature?
Many have asked for a redirection feature that would allow for redirection to previous e107 page after login (instead of redirecting to forum).

I decided I would provide separate hack code that you will be able to copy & paste rather than incorporate the feature into the script. The reason for this is that incorporating such a feature would require me to do even more research on older versions of software, edit all of the modules (each with varying search / replace points), and add additional functions into the script itself. That is a ton of work for such a small feature.

I will provide redirection code to be placed (most likely in index.php of forum and class2.php of e107) once the hack has been tested a bit and can be fully released.

EDIT:
Link updated (Beta 2) to include proper initializing of objects.

Amel
06-11-2006, 07:34 PM
today is a good day

thank you Patiek, thank you God

now finally I can start updating my website

thanks!

Raul_Fury
06-11-2006, 07:55 PM
WOW, I thank you a lot!!!!!!!!

I can finally integrate it!!

Raul_Fury
06-13-2006, 11:09 PM
wow, it didn't work for me at all. when I click the settings or profile in cms it shows internal error. and also, it deleted all my users in the cms(thank god I did a backup).

In conclusion it didnt really work at all......

Patrick
06-13-2006, 11:49 PM
wow, it didn't work for me at all. when I click the settings or profile in cms it shows internal error. and also, it deleted all my users in the cms(thank god I did a backup).

In conclusion it didnt really work at all......


I need more details (you didn't provide any really).

For example, this hack worked well for me on new (non-upgraded / non-modified installs) of IPB 2.1x and e107 0.7.5 .

a) What version of e107 are you using? Was that version originally installed or did you upgrade to that version? Have you made any modifications, particularly to the files that had to be chmod?
b) All of the same questions for (a) but instead of e107, answer them for IPB.
c) What was the output of the script when it started to combine members? Were there any errors? Did you see the various usernames of the members that were being removed?
d) Were there any errors during the install process? Were there any text errors in the hack itself?
e) Did you confirm that the script made changes to the files it asked to chmod (search for "ep-dev.com" in the files)?
f) Did you select the correct e107 version during the hack install process? Did you select the correct IPB version during the install process? Did you confirm that the details for the database(s) are correct?

This hack will never make it out of beta and I will never be able to fix any potential errors if I can't get that type of information.

As for specifics to your problems:
What is the setup that you are running (i.e. site.com => e107, site.com/forum => IPB)? Currently the hack will only work in similar setups to the above on some webservers due to php safe mode or directory restrictions, particularly when the forum exists on a separate subdomain site (i.e. forum absolute path is outside of e107 absolute path).

Also, the script's intent is to delete your CMS users. It deletes your CMS users (with the exception of administrator accounts). Then it creates new CMS user accounts for your forum members. This is the only way to ensure that overlapping CMS users are not a problem (especially for security).

Raul_Fury
06-14-2006, 12:54 AM
ok here are the answers, and I'm sorry for not explaining myself before..


a) What version of e107 are you using? Was that version originally installed or did you upgrade to that version? Have you made any modifications, particularly to the files that had to be chmod?I'm using IPB version 1.3, and e107 is 0.7.5.
I freshly installed not upgraded. I have made no modifications to anyfile in e107 or in IPB. I did chmod all the files needed


b) All of the same questions for (a) but instead of e107, answer them for IPB.
All answered in A.

c) What was the output of the script when it started to combine members? Were there any errors? Did you see the various usernames of the members that were being removed?When I installed it told me no errors at all. Yes it told me the usernames erasing and my name skipped because I was Admin of course.

d) Were there any errors during the install process? Were there any text errors in the hack itself?no, nothing of that kind.

e) Did you confirm that the script made changes to the files it asked to chmod (search for "ep-dev.com" in the files)?Yes, it told me it modified it.

f) Did you select the correct e107 version during the hack install process? Did you select the correct IPB version during the install process? Did you confirm that the details for the database(s) are correct?Yes, I choose the correct software versions. Yes, I confirmed everything.

and to your last question there, I know what it was supposed to do, but it didnt do that, it DID erase my cms users but didnt put any users on the forums.

In conclusion-I'm sorry I didn't explain myself before.
And I hope you can fix this and I'll see if it was my fault.

Raul_Fury
06-14-2006, 12:57 AM
and I also forgot to mention, but when I uninstalled, I dont think it did it correctly, because I had to overwrite the files it modified with my original file, but I still can't logout.
I havent asked my member to see if they can logout but I'll see now.

Patrick
06-14-2006, 02:43 AM
and I also forgot to mention, but when I uninstalled, I dont think it did it correctly, because I had to overwrite the files it modified with my original file, but I still can't logout.
I havent asked my member to see if they can logout but I'll see now.


When the uninstall doesn't work that is a good sign that the modifications were not successful when originally installed. Please note that the script does not confirm modifications but rather just spits out its attempts during install process.

I will try with a fresh install of IPB 1.3x and see what happens. However, I think it is important to tell you that IPB 1.3x has many, many holes in it that will eventually lead to your forum being destroyed by a script kiddie.

Raul_Fury
06-14-2006, 02:49 AM
Well anywayz, I'm going to change to php-nuke, e107 doesnt seem to be popular anymore....and php-nuke has way more mods and themes.

well thanks a lot for your assistance and good luck on the script:D

Patrick
06-14-2006, 02:54 AM
Well anywayz, I'm going to change to php-nuke, e107 doesnt seem to be popular anymore....and php-nuke has way more mods and themes.

well thanks a lot for your assistance and good luck on the script:D


I am not going to try IPB 1.3x for several reasons. First it doesn't work with mysql 5.x and I do not feel like downgrading. Second, it has major security holes that allow total administrative access with readily available tools on the internet (some of them as simple as putting in the URL of a forum and the user id of an admin).

I think I will be officially dropping support for IPB 1.3x because of this, but I may consider picking up support of another forum script.

Raul_Fury
06-14-2006, 02:57 AM
Yea, IPB 1.3 is getting "TOO" old and even though many people still use it "such as me" it's getting to hard stayign with that old version.

Patrick
06-14-2006, 03:47 AM
Yea, IPB 1.3 is getting "TOO" old and even though many people still use it "such as me" it's getting to hard stayign with that old version.

There are several good forum scripts out there:
phpBB (http://www.phpbb.com)
SMF (http://www.simplemachines.org/) (this forum's software)
MyBB (http://www.mybboard.com/) (vb 2.x like)

Amel
06-17-2006, 10:01 AM
I will try this out today on my test site

IBP 2.0 and e107 version .700

Amel
06-17-2006, 10:07 AM
I also sent this to e107 so we can have more beta testers

Amel
06-17-2006, 05:51 PM
ok

I just run a test on my test website

I did not work correctly

before the hack-install, I created 2 more users on my e107 and they both got deleted after the install

install run perfect, no problems at all..but it did not transfer the users onto IBF

ok then I created a new user, no problems, went thru fine, user also created in e107, but, clicking on settings or profile gave me a internal server error in e107

here are some links, you can take a look at

Version 0.7.5
hgghghg

Invision Power Board(Trial) v2.0.0 PF 2
hghgh

you can register yourself and see what works what doesnt

Patrick
06-17-2006, 06:50 PM
Can you attach your user.php e107 file?

Patrick
06-17-2006, 07:30 PM
Well, I have tested and it worked for me with the following:

IPB 2.00
IPB 2.1x

<and>

e107 0.7.5

PHP: 5.x
MySQL: 5.x
Apache 2.x

I am simply not getting the same results as you are. I am going to try the script on a dev server under a domain with:
PHP 4.4x
MySQL 4.1x
Apache 1.x

Patrick
06-17-2006, 08:41 PM
I have tested on the development server and all is working as expected:

Install successful.
Users were copied from IPB to e107 (remember, users are never transfered from e107 to IPB).
All links work correctly (no errors, etc).
Login and logout works correctly.
New user creation works correctly.
Forgot password functionality works correctly.

I have tested all portions of this script that I can think of and they all appear to be functioning correctly.

Details:
e107 0.7.5 - default install
Invision Power Board 2.0.0 - default install
--------------------------
MySQL 4.1x
PHP 4.4x
Apache 1.x


That was all successful using the file I posted in this thread.

You may want to try using the following file as well (see attached), which is updated to include proper initializing of objects.

Amel
06-17-2006, 08:48 PM
I have tested on the development server and all is working as expected:

Install successful.
Users were copied from IPB to e107 (remember, users are never transfered from e107 to IPB).
All links work correctly (no errors, etc).
Login and logout works correctly.
New user creation works correctly.
Forgot password functionality works correctly.

I have tested all portions of this script that I can think of and they all appear to be functioning correctly.

Details:
e107 0.7.5 - default install
Invision Power Board 2.0.0 - default install
--------------------------
MySQL 4.1x
PHP 4.4x
Apache 1.x


That was all successful using the file I posted in this thread.

You may want to try using the following file as well (see attached), which is updated to include proper initializing of objects.


aha so IBF users get transferred

my mistake

I will test further and let you know if I get any problems

thanks

PALADIN
07-14-2006, 10:47 AM
sorry, I don't understand.
Will it work with e107 0.7.5 and ipb1.3?

Patrick
07-14-2006, 01:10 PM
I have only had one report of IPB 1.3 and that report can be found at the beginning of this thread. As far as I could see code-wise, the script *should* be working with IPB 1.3, but I would install it on any production site. You are welcome to setup a test site (with e107 0.7.5 and IPB 1.3) and see if it works. I may also setup a test site as well later, but I haven't tested it locally as IPB 1.3 does not work with MySQL 5.x (which I have installed locally).

lpxxfaintxx
07-18-2006, 03:07 PM
My viewprofile doesn't work.


Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/informed/public_html/activehacks/classes/mysql.php on line 166

Warning: Cannot modify header information - headers already sent by (output started at /home/informed/public_html/activehacks/classes/mysql.php:166) in /home/informed/public_html/activehacks/modules/cms/e107_0.7.5.php on line 197

Anyone know why?

http://activehacks.com/
http://activehacks.com/user.php?id.1

Patrick
07-18-2006, 03:33 PM
Probably incorrect database settings.

lpxxfaintxx
07-18-2006, 04:03 PM
I don't think so, everything works except for this... :\

Patrick
07-18-2006, 05:48 PM
Well you can debug it in a number of ways.

Try opening classes/mysql.php

and find:

$this->debug['sql'][] = $final_query;

And beneath it place:

echo "QUERY: " . $final_query . " <br>\n";

That will print all queries to any databases. You can then try running query manually via phpmyadmin or similar and investigate what is going wrong (or post queries here).

vat0r
07-19-2006, 12:46 AM
Can't believe I missed this thread. I'll be installing this locally right away. Thank you so much Patiek.
----------------------------------------------------

Tested on a live server as well with fresh copies of both the latest ipb and e107. Worked perfectly. I tested the forgot password link from both e107 and ipb and all seems to work as it should. Great work!

----------------------------------------------------
I did notice that if your logged in and on the e107 side this will happen. Say my e107 is at www.mysite.com/home and the forums are at www.mysite.com/forums. Well if im in e107 and I type the url www.mysite.com/forums then I am logged out of the forum. If I type www.mysite.com/forums/index.php then all works correctly. Not really a big deal just thought it was worth a mention.

Rolle
11-02-2006, 07:02 AM
I can't get this script working under Windows server. The absolute path for the script, forum and CMS doesn't seem to be working. While installing the script i get these errors at the top of the page:



Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in D:\root\hack\classes\mysql.php on line 166

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in D:\root\hack\classes\mysql.php on line 166


...but the install finishes anyway. Then, when i try to login or logout at the forums:



IPB WARNING [2] login::require_once(D: oot\hack/cms_forum_hack.php) [function.login-require-once]: failed to open stream: Invalid argument (Line: 627 of \sources\action_public\login.php)


You see that D:\root seems to be wrong there, so I opened the login.php file and looked there and it was OK. Maybe MySQL doesn't like "\r" ?

Patrick
11-02-2006, 10:25 AM
On a windows machine, you of course have to use either single forward slashes (c:/some/path/) or double back slashes (c:\\some\\path\\).

I am guessing you didn't use the double slashes while using backward slashes.

jstruijk
11-28-2006, 03:29 AM
Hi there, great work on this.

Atm i am using e107 0.7.6 together with IPB v2.1.7. Does anyone know if this is a working combination?

Further i am reading that during the installation process the users are transferred from IPB to e107 not the other way. But is it possible to transfer the other way, from e107 to IPB AFTER installation. Or is it IPB -> e107 only?
The problem is that all my users are registering at my e107 website first, that's why.

www.3pinter.nl

Grx,
Joris

Patrick
11-29-2006, 04:57 PM
This is currently not possible with this script.

DrJackal
12-15-2006, 01:26 PM
hi, i came across this website through google.
and i been looking for this hack for quite sometimes.

so i already installed CMS Forum Member Hack 1.20 BETA

somehow it doesnt work.

1. when i register as DrJackal at CMS it jump to FORUM webpage,
2. then i go CMS login as DrJackal it success,
3. after that i go to FORUM it show me that i didnt login,
4. so i login again as DrJackal and Failed because user doesn't exist.
5. and then i click register as member on top of the page show as following


IPB WARNING [2] mysql_num_rows(): supplied argument is not a valid MySQL result resource (Line: 152 of /home/crezione/domains/crezione.com/public_html/testrun/cmsforum/classes/mysql.php)
IPB WARNING [2] Cannot modify header information - headers already sent by (output started at /home/crezione/domains/crezione.com/public_html/testrun/IPB/init.php:269) (Line: 167 of /home/crezione/domains/crezione.com/public_html/testrun/cmsforum/modules/cms/PHP-Nuke_7.3.php)

kindly pls advice. thanks ^^

spec info.
PHPNuke 8.0
IPB 2.1.7

Patrick
12-15-2006, 01:45 PM
The 1.20 Beta does not include an updated PHP-Nuke module... mostly because I didn't have access to PHP-Nuke at the time.

However, I did recently obtain a copy of PHP-Nuke 8.x and I may try to fix up the PHP-Nuke module for integration in the near future. Until that time, I would recommend uninstalling the script following the uninstall instructions.

DrJackal
12-19-2006, 09:54 PM
oh~ that will be very nice.
but may i know usually took you how long to came out with it?

^^ hehe.. coz i'm coming out with the website on january ... LoLz

Slipped
01-28-2007, 08:29 PM
Hi,

I'm running e107 .7.7 and IPB 2.1.7. I finally got this script to install after a few errors and quick fixes in some files. Everything seems work fine except for when it comes to logging out/in on e107. If I login to a forum account via the forum, everything works fine. I can go to the e107 site and I'm logged in as that user, however, if I try to logout on either the site or the forum, I run into some problems. It'll log out on the forum just fine, but when I go back to the e107 site expecting to be logged out, I am not. I'm logged back in as a head admin. I created an account on the forums to match that head admin account on e107, but I still have the same problem. Should this be happening? Any solutions?

Apparently it doesn't let anyone login via the site, they have to do it through the forum.

Amel
01-29-2007, 01:56 PM
will it work with the current ibp version

2.2

thanks

Patrick
01-29-2007, 04:02 PM
will it work with the current ibp version

2.2

thanks


No idea. This script is currently dead as far as development goes. I am not actively working on it nor do I plan to work on it in the future. It is released under gnu gpl license so anyone is free to pickup the script and its development.

The interest that I had in this project has died since I started working on my own CMS (I know... not as if there are not enough of those out there on the internet) that has this script's abilities built in and is built on smarty template system with full template access to everything and a good locale (language/translations) framework. I got tired of messing with the complexities and difficulties of other CMS code so I came up with some code that makes making modulles easy while maintaining a strict programming structure / framework (i.e. not near the amount of messy code).

The General
02-21-2007, 06:25 AM
I got the hack installed on 1.3.1 Final and E107 0.7.5.

It works great! But i have still one problem:
If i get logged in on the E107 system. And i click on log out on the E107 system i wil redirect tot the forum. If i go to the e107 i'm stil logged in?

Who can help me?