Announcement

Collapse
No announcement yet.

Enabling google login for vbulletin 5.4.2

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    I did verify everything. However you are right that there are no external connections for the admin - me - for Google or Twitter but that just means that this user - me - has not logged in via Google yet.

    But I'm not trying to login for myself - I am just trying to login to my forum via a gmail of mine, not a gmail that is linked to me on my forum, and it doesn't work.

    I think the way it is supposed to work is that if someone tries to login via a gmail that is new to the forum, it should take him to the Registration page, if the options are set to Enable Registration with Google, which is the way I have it set at my forum, and instead, nothing happens.


    Here are the screenshots:
    I am not sure why there is no API key but I don't think there is supposed to be one:


    The client ID and client secret do match the figures inputted in the forum:


    I did notice under this tab that no domain is authorized for this app, but I don't recall ever having to address that anyway:


    The reason it even occurred to me to test this, is because I created a new Google app for a different vb5 forum of mine where I was doing some testing, and this is where I noticed that the Google login no longer works. And then when I went to look at this app, I noticed this:

    so I sent in the request for verification even though I had never changed a thing, not the logo, not anything, and Google wrote back and said that I do not need to proceed with verification, so I left it alone.



    Comment


    • #17
      To recap: what happens is that when I click on the google logo I get the login screen, get all the way to login, it appears to be logging in, says One moment please... and then the window collapses and nothing happens, no login to the forum or movement to the registration screen.

      I just tested the same forum with twitter login, and when it fails to find a linked account it takes you to the Registration screen where it has your Twitter username already filled in as your UserName and the rest of the fields blank, to allow input for registration.

      Comment


      • #18
        If it's of any help, I have a social login app I use on my forum called OneAll
        https://github.com/oneall/social-log...cial_login.zip
        and within it there is this code in their toolbox.php which is located
        core/packages/oneallsociallogin/include/toolbox.php
        and included this code for the create_user() function:

        // Setup user
        do
        {
        $user = new vB_Datamanager_User (vB_DataManager_Constants::ERRTYPE_ARRAY_UNPROCESSED);
        $user->set ('email', $vbulletin->db->escape_string ($user_data ['user_email']));
        $user->set ('ipaddress', vB::getRequest ()->getIpAddress ());
        $user->set ('username', $vbulletin->db->escape_string ($username));
        $user->set ('usergroupid', ($vbulletin->options ['moderatenewmembers'] ? 4 : 2));
        $user->set ('usertitle', vB_Api::instanceInternal ('user')->getUsertitleFromPosts (0));
        $user->set ('customtitle', 0);
        $user->set ('passworddate', date ('Y-m-d', vB::getRequest ()->getTimeNow ()));
        $user->set ('secret', vB_Library::instance ('user')->generateUserSecret ());
        $user->set ('joindate', time ());
        $user->set ('posts', 0);
        $user->set ('logintype', 'fb');
        $user->pre_save ();

        When I removed the line
        $user->set ('logintype', 'fb');

        their Google login stopped experiencing a redirect error and allowed Gmail to be used for registration of a NEW member.

        Like your plugin, until I removed that line their login too was working only for Gmail logins of users who already had their gmail associated with their username, not for users who had never before registered at the forum. Now it works for both, although - when a new user logs in with his gmail right now the OneAll app bypasses the registration and registers him instantly with his gmail username.

        Comment


        • #19
          A design decision was made to redirect users to registration if they don't have an account. This is so vBulletin can comply with many different laws around the world. Simply registering them blindly probably does not comply with either the GDPR or the CCPA.
          Translations provided by Google.

          Wayne Luke
          The Rabid Badger - a vBulletin Cloud demonstration site.
          vBulletin 5 API - Full / Mobile
          Vote for your favorite feature requests and the bugs you want to see fixed.

          Comment


          • #20
            I am fine with that, but as noted, the vbulletin Google/Gmail does not work at all right now unless it it used for login by someone who has already linked his gmail to his vbulletin forum membership...which is impossible currently as your gmail login is not allowing non-registered members to even use the gmail login.

            Comment


            • #21
              When you fix the Google/Gmail login, you should address this as well:



              otherwise, eventually the app / gmail login is going to be disallowed.

              Comment


              • #22
                vBulletin ships with a privacy policy (/privacy) page accessible from the footer on a default install or 3/4 upgrade.

                To edit the text of the Privacy Policy:
                1. Enter the AdminCP
                2. Go to Languages & Phrases -> Search in Phrases.
                3. Search for the "privacy_policy_page_text" phrase.
                4. Edit this phrase to contain the HTML of your personal privacy policy.
                5. This should show on the /privacy page on your vBulletin site.

                If for some reason you do not have /privacy on your site:
                1. Go to the front-end of your site.
                2. Click "Edit Site" if Site Builder is not enabled.
                3. Clicking "New Page" in Site Builder
                4. Add the Display Template Module
                5. Tell it to display the privacy_policy_page template.
                6. Add any other modules you want.
                7. Save the Page. Remember its name and url.
                8. Click on Footer in Site Builder.
                9. Add a link to your new page.
                We are not allowed to provide boilerplate text for the privacy policy. You will need to consult with your legal advisors to know what is required for your particular jurisdiction.
                Last edited by Wayne Luke; Sat 16th May '20, 8:48am.
                Translations provided by Google.

                Wayne Luke
                The Rabid Badger - a vBulletin Cloud demonstration site.
                vBulletin 5 API - Full / Mobile
                Vote for your favorite feature requests and the bugs you want to see fixed.

                Comment


                • #23
                  That was a mistake.

                  When I copy/pasted the long Privacy policy I created into
                  privacy_policy_page_text
                  it pretty much froze up my forum now I can't even navigate ACP to delete it.

                  Comment


                  • #24
                    All right I deleted it. I'll have to figure out how to get it in there without jamming up the whole forum.

                    Comment


                    • #25
                      It should be plain HTML without the <html>, <head>, <title>, <meta> or <body> tags.

                      This query will reset it to the default in all languages.

                      UPDATE phrase SET text='<p><em>Edit the "privacy_policy_page_text" phrase to specify your Privacy Policy.</em></p>' WHERE varname='privacy_policy_page_text';
                      Translations provided by Google.

                      Wayne Luke
                      The Rabid Badger - a vBulletin Cloud demonstration site.
                      vBulletin 5 API - Full / Mobile
                      Vote for your favorite feature requests and the bugs you want to see fixed.

                      Comment


                      • #26
                        I went in and reverted privacy_policy_page_text to default. Do I also need to run that command because when I ran it I got

                        [[email protected] public_html]# UPDATE phrase SET text='<p><em>Edit the "privacy_policy_page_text" phrase to specify your Privacy Policy.</em></p>' WHERE varname='privacy_policy_page_text';
                        -bash: UPDATE: command not found


                        If I see this

                        do I need to do anything more to revert to default? I use only English on my site --- because the site is still not loading right somehow the mySQL got jammed up ever since I tried to enter that long privacy policy in there, it's hard to enter the ACP, or load PMs.

                        Comment


                        • #27
                          I posted a MySQL Query, not a bash command. You must log into MySQL to run queries.
                          Translations provided by Google.

                          Wayne Luke
                          The Rabid Badger - a vBulletin Cloud demonstration site.
                          vBulletin 5 API - Full / Mobile
                          Vote for your favorite feature requests and the bugs you want to see fixed.

                          Comment


                          • #28
                            Originally posted by Wayne Luke View Post
                            I posted a MySQL Query, not a bash command. You must log into MySQL to run queries.
                            do I need to do anything more to revert to default? I use only English on my site --- because the site is still not loading right somehow the mySQL got jammed up ever since I tried to enter that long privacy policy in there, it's hard to enter the ACP, or load PMs.
                            It is a simple query. It should take milliseconds to complete and has nothing to do with private messages. I don't know what you tried to enter as your privacy policy but that shouldn't cause issues with MySQL either.
                            Translations provided by Google.

                            Wayne Luke
                            The Rabid Badger - a vBulletin Cloud demonstration site.
                            vBulletin 5 API - Full / Mobile
                            Vote for your favorite feature requests and the bugs you want to see fixed.

                            Comment


                            • #29
                              I ran it in mySQL and it did whatever it was supposed to. But I'm not going to try to stick a huge thing into that privacy policy again! until I figure out why it crashed the system. Obviously it did something because merely trying to paste it initially caused an http500 error immediately, evidently because vbulletin couldn't handle the html code. But even then adding too much text with no html overburdened it somehow too.

                              Comment


                              • #30
                                The field can have up to 16 megabytes of data stored in. HTML in phrases is not parsed and just stored as raw HTML.

                                However, your server may be configured to allow much less in both the amount that can be submitted through PHP and how much each query in MySQL can handle. A 500 server error comes from the server, not vBulletin.
                                Translations provided by Google.

                                Wayne Luke
                                The Rabid Badger - a vBulletin Cloud demonstration site.
                                vBulletin 5 API - Full / Mobile
                                Vote for your favorite feature requests and the bugs you want to see fixed.

                                Comment

                                Related Topics

                                Collapse

                                Working...
                                X