Docy

Single sign-on (SSO)

If your company has its own online exhibitor portal, you can link it to Visit Connect to create a single sign-on experience across all applications. This means your partners log in to your portal once and can then switch to Visit Connect and back again, without needing to separately log in to each application.

Setting up single sign-on requires a one-time setup on your portal server. You need to place a script on your server. This script must pass a shared key to our system whenever a partner logs in to your portal, authenticating them to our system.

Get your shared key and event code

  1. In Visit Create, open your event.
  2. Navigate to Event > Visit ConnectSettings.
  3. Copy the Event code and Pre shared key.

Sample PHP scripts

Below are two sample PHP scripts for setting up Visit Connect single sign-on. These scripts are examples and may not work as-is. If you have any questions regarding this implementation, the Visit development team can help you.

Example one

Basically create a form and make a POST.

<?php
$sharedKey = 'xxxxxx'; // shared key of organisation, see note below

// Make sure parameters are specified in alphabetical order for correct calculation of hash
$request = array(
    'contactref' => 'yyyy',     // reference to partner as set when importing them or via API
    'expo' => 'zzzzzzz',        // expo code from visit
    'time' => time()
);

// create a hash from decoded query string and sign with pre-shared-key
$hashSource = urldecode(http_build_query($request)) . $sharedKey;
echo "HASH is taken from SHA256('" .$hashSource . "')<br/>";

// checksum based on alphabetically ordered name/value pairs with appended sharedkey
$request['check'] = hash('sha256', $hashSource);
echo "<form action='https://visitconnect.gesevent.com/partner/loginauth' method='POST'>";
foreach ($request as $key => $value) {
    echo "<input type='text' name='". $key ."' value='" . $value ."'/>";
}
echo "<input type='submit' value='Submit'/></form>";

Example two

Use CURL to perform a post.

<?php
$sharedKey = 'xxxxxx'; // shared key of organisation, see note below

// Make sure parameters are specified in alphabetical order for correct calculation of hash
$request = array(
    'contactref' => 'yyyy',     // reference to partner as set when importing them or via API
    'expo' => 'zzzzzzz',        // expo code from visit
    'time' => time()
);

// create a hash from un-encoded query string and sign with pre-shared-key
$request['check'] = hash('sha256', urldecode(http_build_query($request)) . $sharedKey);

$ch = curl_init('https://visitconnect.gesevent.com/partner/loginauth');

curl_setopt_array($ch, array(
    CURLOPT_POST => true,
    CURLOPT_FOLLOWLOCATION => false,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_POSTFIELDS => http_build_query($request)
));

curl_exec($ch);
$info = curl_getinfo($ch);
header('Location: '. $info['redirect_url']);

Example three

Same as example one but with a ‘redirect_url’ to redirect to a specific page after a login.

<?php
$sharedKey = 'xxxxxx'; // shared key of organisation, see note below

// Make sure parameters are specified in alphabetical order for correct calculation of hash
$request = array(
    'contactref' => 'yyyy',             // reference to partner as set when importing them or via API
    'expo' => 'zzzzzzz',                // expo code from visit
    'redirect_url' => '/registrants',   // a path to a specific Visit Connect page e.g. '/leads', '/dashboard' or '/registrants'
    'time' => time()
);

// create a hash from decoded query string and sign with pre-shared-key
$hashSource = urldecode(http_build_query($request)) . $sharedKey;
echo "HASH is taken from SHA256('" .$hashSource . "')<br/>";

// checksum based on alphabetically ordered name/value pairs with appended sharedkey
$request['check'] = hash('sha256', $hashSource);
echo "<form action='https://visitconnect.gesevent.com/partner/loginauth' method='POST'>";
foreach ($request as $key => $value) {
    echo "<input type='text' name='". $key ."' value='" . $value ."'/>";
}
echo "<input type='submit' value='Submit'/></form>";

Example four

Same as example three but with a ‘redirect_url’ to redirect to a specific page after a login.

<?php
$sharedKey = 'xxxxxx'; // shared key of organisation, see note below

// Make sure parameters are specified in alphabetical order for correct calculation of hash
$request = array(
    'contactref' => 'yyyy',             // reference to partner as set when importing them or via API
    'expo' => 'zzzzzzz',                // expo code from visit
    'redirect_url' => '/registrants',   // a path to a specific Visit Connect page e.g. '/leads', '/dashboard' or '/registrants'
    'time' => time()
);

// create a hash from un-encoded query string and sign with pre-shared-key
$request['check'] = hash('sha256', urldecode(http_build_query($request)) . $sharedKey);

$ch = curl_init('https://visitconnect.gesevent.com/partner/loginauth');

curl_setopt_array($ch, array(
    CURLOPT_POST => true,
    CURLOPT_FOLLOWLOCATION => false,
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_POSTFIELDS => http_build_query($request)
));

curl_exec($ch);
$info = curl_getinfo($ch);
header('Location: '. $info['redirect_url']);
CONTENTS