Subsonic registration engine

A little external engine to register users in Subsonic

Moderator: moderators

Re: Subsonic registration engine

Postby SparkyRih » Wed Feb 15, 2012 8:49 pm

gurutech wrote:PM sent...

When you say to browse to the register.php file, do you mean from explorer, or in the browser itself, like http://mysite.subsonic.org/register.php ?


Yeah, just to see if it works there...

Edit: I've also takena lookat your phpinfo() info... and GD (and also CURL) appear to be fine...
But if you brows just to the captcha.php (example: http://api.schattorie.nl/gbuser/lib/captcha.php) what doest it display (in IE)? does it display totally nothing, some random characters, or does it display a red cross in a box (still, keep the // in frond of the header() lines)...
VMWare ESXi 5.5 > Ubuntu 16.04 > Subsonic 6.0 (Modded with PHP based registration feature)

Image
User avatar
SparkyRih
 
Posts: 216
Joined: Wed May 11, 2011 1:52 pm
Location: The Netherlands

Re: Subsonic registration engine

Postby gurutech » Thu Feb 16, 2012 2:55 am

SparkyRih wrote:
gurutech wrote:PM sent...

When you say to browse to the register.php file, do you mean from explorer, or in the browser itself, like http://mysite.subsonic.org/register.php ?


Yeah, just to see if it works there...

Edit: I've also takena lookat your phpinfo() info... and GD (and also CURL) appear to be fine...
But if you brows just to the captcha.php (example: http://api.schattorie.nl/gbuser/lib/captcha.php) what doest it display (in IE)? does it display totally nothing, some random characters, or does it display a red cross in a box (still, keep the // in frond of the header() lines)...


Just redirects to the login page. No errors. Could it be that I just have the reg engine installed in the wrong folder? Where should it be, in reference to the jetty/2585/ folder?
Image
gurutech
 
Posts: 492
Joined: Sun Jan 15, 2012 9:56 pm

Re: Subsonic registration engine

Postby SparkyRih » Thu Feb 16, 2012 8:21 am

everything in the subregendgine folder should run on an apache server, not on the jetty server....

tso it basically should be in the same place as the test.php you've send me in the PM... after that, make sure the login.jsp has all four URLs to the right doman...
VMWare ESXi 5.5 > Ubuntu 16.04 > Subsonic 6.0 (Modded with PHP based registration feature)

Image
User avatar
SparkyRih
 
Posts: 216
Joined: Wed May 11, 2011 1:52 pm
Location: The Netherlands

Re: Subsonic registration engine

Postby gurutech » Thu Feb 16, 2012 1:31 pm

So the files in "lib" would go to the "root" of the website, with the fonts and mail folders under that?

ie. http://mysite.whatever.com/captcha.php ?
Image
gurutech
 
Posts: 492
Joined: Sun Jan 15, 2012 9:56 pm

Re: Subsonic registration engine

Postby SparkyRih » Thu Feb 16, 2012 5:53 pm

gurutech wrote:So the files in "lib" would go to the "root" of the website, with the fonts and mail folders under that?

ie. http://mysite.whatever.com/captcha.php ?


No not tjust the lib... where did you read that?

Example in my situation:
I've created a subdomian: http://api.schattorie.nl on this subdomain I created a folder called gbuser, that's the fodler where ALL the contents of the subregendgine folder located...
The only thing you need to change in subsonic is the login.jsp... all 4 url's in my login.jsp point to http://api.schattorie.nl/gbuser/*******
VMWare ESXi 5.5 > Ubuntu 16.04 > Subsonic 6.0 (Modded with PHP based registration feature)

Image
User avatar
SparkyRih
 
Posts: 216
Joined: Wed May 11, 2011 1:52 pm
Location: The Netherlands

Re: Subsonic registration engine

Postby gurutech » Thu Feb 16, 2012 9:52 pm

SparkyRih wrote:
gurutech wrote:So the files in "lib" would go to the "root" of the website, with the fonts and mail folders under that?

ie. http://mysite.whatever.com/captcha.php ?


No not tjust the lib... where did you read that?

Example in my situation:
I've created a subdomian: http://api.schattorie.nl on this subdomain I created a folder called gbuser, that's the fodler where ALL the contents of the subregendgine folder located...
The only thing you need to change in subsonic is the login.jsp... all 4 url's in my login.jsp point to http://api.schattorie.nl/gbuser/*******


I mean on the server itself, not on the "web" side of things...

SubSonic installed itself under /var/subsonic, with a bunch of subfolders, namely ./jetty/2585/webapp/WEB-INF/jsp - which is where all of the .jsp files are. But the registration engine files are located in a subfolder of THAT folder, called lib.

Would it be possible for you to PM me a directory tree of your setup, so I can make sure all the files are in the right folders? I'm considering just removing and reinstalling SubSonic, and starting over again, but would like to try this first...
Image
gurutech
 
Posts: 492
Joined: Sun Jan 15, 2012 9:56 pm

Re: Subsonic registration engine

Postby SparkyRih » Thu Feb 16, 2012 10:45 pm

The left session shows the files on the webserver (/var/www/subdomains/api/gbuser), the right one shows the subsonic jsp dir...

Image
VMWare ESXi 5.5 > Ubuntu 16.04 > Subsonic 6.0 (Modded with PHP based registration feature)

Image
User avatar
SparkyRih
 
Posts: 216
Joined: Wed May 11, 2011 1:52 pm
Location: The Netherlands

Re: Subsonic registration engine

Postby gurutech » Fri Feb 17, 2012 5:17 pm

How do you match up the two sets of folders?

When I enter my site name, it auto-redirects to port 4040, which (I believe) is the web site located under /var/subsonic. It pulls files from the jetty/2585/webapp/WEB-INF/jsp folder (I overwrote the original index.php file in this folder with the register one, and also copied the php files and folders you have listed into this folder).

When I click "register" or "forgot pass", it will show me that section, but not get rid of the initial username/pass section (not sure if it was designed this way or not), but the captcha.php doesn't seem to run.

I know it's a longshot, but would it be possible to code a different captcha image, for example from another website completely (if I have their code) to generate the image, then show it on my page?
Image
gurutech
 
Posts: 492
Joined: Sun Jan 15, 2012 9:56 pm

Re: Subsonic registration engine

Postby SparkyRih » Fri Feb 17, 2012 5:30 pm

No, your problem is that you don't understand where the files should be located...

The only thing you have to replace/add in /var/subsonic/jetty/<version>/WEB-INF/jsp is the login.jsp... you only need to replace the login.JSP here... you don't need to add or replace any other files in here...

All the other files inside the subregengine go onto an apache web server...

I don't know how I can make this any more clear?
VMWare ESXi 5.5 > Ubuntu 16.04 > Subsonic 6.0 (Modded with PHP based registration feature)

Image
User avatar
SparkyRih
 
Posts: 216
Joined: Wed May 11, 2011 1:52 pm
Location: The Netherlands

Re: Subsonic registration engine

Postby gurutech » Fri Feb 17, 2012 8:38 pm

ok, I'm a little embarrassed... just checked your site again, as I had removed and reinstalled SubSonic....

Found you had a new version, which I had not tried. I was running 1.12. Just downloaded 2.0 for 4.5b1+ and will test this out (from a fresh install), and let you know how it goes...
Image
gurutech
 
Posts: 492
Joined: Sun Jan 15, 2012 9:56 pm

Re: Subsonic registration engine

Postby SparkyRih » Fri Feb 17, 2012 9:30 pm

gurutech wrote:ok, I'm a little embarrassed... just checked your site again, as I had removed and reinstalled SubSonic....

Found you had a new version, which I had not tried. I was running 1.12. Just downloaded 2.0 for 4.5b1+ and will test this out (from a fresh install), and let you know how it goes...


Version 1.1.2 should work fine, I didn't fix any bugs since that version...

But let me know, I hope you'll get it to work...
VMWare ESXi 5.5 > Ubuntu 16.04 > Subsonic 6.0 (Modded with PHP based registration feature)

Image
User avatar
SparkyRih
 
Posts: 216
Joined: Wed May 11, 2011 1:52 pm
Location: The Netherlands

Re: Subsonic registration engine

Postby gurutech » Sat Feb 18, 2012 12:10 am

Fixed it.... to a point...

I figured out the path problem as being an issue with my IP redirection service. I set up another "host" to go to the same IP on the regular web port I am using since my ISP blocks port 80. I adjusted the php files to point to this "site" now, and I can now see the captcha image.

I can register a new account, however it appears that when I go to approve it (I enabled the approval process), I go to http://mysite.subsonic.org/admin/approve.php and I get the login page, but I enter my admin credentials and it tells me that it's wrong, even though the same ID and password work to login to the regular site.

Also tested without approval requirement, but the ID is still not created in Subsonic. I exported both of the tables in the database, and the entries ARE appearing there.

One thing to note, is that in "non-approval" mode, after the ID is created and the screen comes up indicated it was created, I am redirected to YOUR page - http://www.schattorie.nl instead of my login page. (I just edited the register.php file to show my actual domain instead of the "$subsonicdomain" entry, will test that now...)
Image
gurutech
 
Posts: 492
Joined: Sun Jan 15, 2012 9:56 pm

Re: Subsonic registration engine

Postby SparkyRih » Sat Feb 18, 2012 11:09 am

Did you configure everything correctly?

$woaadmin = "A user that is present in the Database...";
$subsonicdomain = "subdomain.something.com:port"; (so if you use a port other than 80, don't forget it...)
Do you as an admin receive e-mail (first check if the mailconf.php sends it's mail to the right e-mail address)...

If you have any errors, please post the full errors here...
VMWare ESXi 5.5 > Ubuntu 16.04 > Subsonic 6.0 (Modded with PHP based registration feature)

Image
User avatar
SparkyRih
 
Posts: 216
Joined: Wed May 11, 2011 1:52 pm
Location: The Netherlands

Re: Subsonic registration engine

Postby gurutech » Sat Feb 18, 2012 8:29 pm

SparkyRih wrote:Did you configure everything correctly?

$woaadmin = "A user that is present in the Database...";
$subsonicdomain = "subdomain.something.com:port"; (so if you use a port other than 80, don't forget it...)
Do you as an admin receive e-mail (first check if the mailconf.php sends it's mail to the right e-mail address)...

If you have any errors, please post the full errors here...


ok, I have the admin approval bit disabled for now, as I don't have "sendmail" set up on this server yet, trying to do one thing at a time... I can register an account through the engine, but when I go to login to Subsonic, the user name does not exist (I get "wrong username or password" error).

I think I need to configure Subsonic to use the "users" table to check for ID/password, just not sure how to do this.
Image
gurutech
 
Posts: 492
Joined: Sun Jan 15, 2012 9:56 pm

Re: Subsonic registration engine

Postby SparkyRih » Sat Feb 18, 2012 11:31 pm

No... my system registers a user in the MySQL DB but ALSO a user in the DB of Subsonic...
Are you sure that your $subsonicdomain is correcy (subdomain.domain.ext:portifnot80) without http:// or any other /'s?

Edit: Are you using Sbusonic in httpS mode? I haven't thought of that in my code, that could be an issue....
VMWare ESXi 5.5 > Ubuntu 16.04 > Subsonic 6.0 (Modded with PHP based registration feature)

Image
User avatar
SparkyRih
 
Posts: 216
Joined: Wed May 11, 2011 1:52 pm
Location: The Netherlands

PreviousNext

Return to Subsonic Registration Engine

Who is online

Users browsing this forum: No registered users and 1 guest