cretueusebiu/gamecenter-identity-verifier

0.0.1 2016-07-27 22:58 UTC

This package is auto-updated.

Last update: 2024-09-14 04:44:36 UTC


README

Verify the identity of Apple GameCenter local player in PHP.

Installation

composer require cretueusebiu/gamecenter-identity-verifier

Usage

use Eusebiu\GameCenterIdentity\Verifier;

$playerId = 'G:1111111111';
$timestamp = 1469626352131;
$bundleId = 'com.myapp.dev';
$publicKeyURL = 'https://static.gc.apple.com/public-key/gc-prod-2.cer';
$salt = '...';
$signature = '...';

$verifier = new Verifier($signature, $publicKeyURL);

var_dump($verifier->verify($playerId, $bundleId, $timestamp, $salt));