HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Please upgrade here. These earlier versions are no longer being updated and have security issues.

Single Sign On PHP : "message":"The client_id parameter is missing

edited September 2012 in Vanilla 2.0 - 2.8

Hi guys,

I have no idea what I'm doing wrong. I used the search on the site and googled like a crazy madman for four hours before coming here.

I keep getting this error: {"error":"invalid_request","message":"The client_id parameter is missing."}

All I did was this:

1) Installed the functions.jsconnect.php and index.php files from the libraries (PHP)
2) Installed the plugin and got my settings okay (I have the client_id and secret key)
3) I tested the URL with "test url" and I get a long string which appears to be okay since I get my client_id and secret key in it
4) I integrated the index.php

require_once dirname(FILE).'/functions.jsconnect.php';

// 1. Get your client ID and secret here.
$clientID = "VALUE";
$secret = "VALUE";

// 2. Grab the current user from your session management system or database here.
$people = I GET MY DATA FROM DB HERE

while($people = ALL MY USERS ) {
$user['uniqueid'] = $people['token'];
$user['name'] = $people['name'];
$user['email'] = $people['email'];
}

// 4. Generate the jsConnect string.
$secure = true;
WriteJsConnect($user, $_GET, $clientID, $secret, $secure);

It keeps throwing me the error. COULD SOMEONE PLEASE HELP! I'm a desperate man. I swear that if I don't get any help soon I'm gonna jump out the freaking window!

Comments

  • Ok, I almost censored that last line. I'll let it in for now though.

    Here is some help. I've used the search button and searched for your exact error message:

    http://vanillaforums.org/search?Search=The+client_id+parameter+is+missing (also might want to use google search for your error message.

    I'm certain there are are a couple of threads with solutions to your problem. Good luck!

  • HalfCatHalfCat ✭✭
    edited September 2012

    I'm irritated by your while loop. Through which array are you looping here?

    I did a simple:

    $user = array();
    $user['uniqueid'] = $people['token'];
    $user['name'] = $people['name'];
    $user['email'] = $people['email'];
    $user['photourl'] = '';
    
  • edited September 2012

    @UnderDog said:
    Ok, I almost censored that last line. I'll let it in for now though.

    Here is some help. I've used the search button and searched for your exact error message:

    http://vanillaforums.org/search?Search=The+client_id+parameter+is+missing (also might want to use google search for your error message.

    I'm certain there are are a couple of threads with solutions to your problem. Good luck!

    Dude, it was a joke. Go ahead though, remove that last line if it hurts so much.

    Thanks for the help anyway. Used proxyconnect.

  • Hi, all. I am trying to implement SSO in an embedded forum. I suspect I'm running into similar issues. Have you been able to figure this out?

  • HalfCatHalfCat ✭✭
    edited October 2012

    @djcher said:
    Hi, all. I am trying to implement SSO in an embedded forum. I suspect I'm running into similar issues. Have you been able to figure this out?

    Please try it for yourself and when you run into problems come back and ask for help (in a new discussion). Even if he figured this is out, it wouldn't help you as you are most likely using a different method of verifying your data. Just be assured that jsConnect works perfectly as-is.

Sign In or Register to comment.