定制 yanlongli/php-apple-signin 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

yanlongli/php-apple-signin

最新稳定版本:2.0.2

Composer 安装命令:

composer require yanlongli/php-apple-signin

包简介

A simple library to decode and parse Apple Sign In client tokens.苹果账号登陆,替代 griffinledingham/php-apple-signin

README 文档

README

PHP library to manage Sign In with Apple identifier tokens, and validate them server side passed through by the iOS client.

PHP库来管理使用Apple标识符令牌的登录,并验证iOS客户端通过的服务器端。

Parity replacement griffinledingham/php-apple-signin (Library out of maintenance)

平价替换 griffinledingham/php-apple-signin (停止维护的库)

Installation 安装

Use composer to manage your dependencies and download php-apple-signin:

需要您的项目使用 composer 管理依赖,使用下方命令安装此库。

composer require yanlongli/php-apple-signin

Example

<?php
use AppleSignIn\ASDecoder;
// ASAuthorizationAppleIDCredential credential
$clientUser = "example_client_user"; //credential.user
$identityToken = "example_encoded_jwt"; // credential.identityToken

// option 
// ASDecoder::$publicKeys = Cache apple keys;

$appleSignInPayload = ASDecoder::getAppleSignInPayload($identityToken);

/**
 * Obtain the Sign In with Apple email and user creds.
 */
$email = $appleSignInPayload->getEmail();
$user = $appleSignInPayload->getUser();

/**
 * Determine whether the client-provided user is valid.
 */
$isValid = $appleSignInPayload->verifyUser($clientUser);

?>

change log

v2.0

Simplify the code and update the data decoding with the dependent library

简化代码,随依赖库更新数据解码

FAQ

FAQ

统计信息

  • 总下载量: 13.98k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 0
  • Forks: 89
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2020-09-16