の検索結果 :
× 統合 Laravel Passport シングルサインオン (Laravel Passport SSO)
Joomla を使用して OAuth 2.0 プロトコル。 miniOrange Joomla OAuth / OpenID Connect シングル サインオン (SSO) プラグインにより、セットアップが簡単になります LaravelパスポートSSO Joomlaに導入し、 Joomla への安全なログインを有効にします。 その結果、ユーザーは、Laravel Passport OAuth プロバイダーの資格情報で認証することで Joomla にログインし、サイトにアクセスできます。
私たちの Joomla OAuth クライアント プラグイン Joomla OAuth シングル サインオン (OAuth および OpenID Connect) プラグイン用に提供される機能とプランの詳細については、Web ページをご覧ください。
composer create-project --prefer-dist laravel/laravel blog
composer require Laravel/Passport
Laravel\Passport\PassportServiceProvider::class,
namespace App;
use Laravel\Passport\HasApiTokens;
use Illuminate\Contracts\Auth\MustVerifyEmail;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Illuminate\Notifications\Notifiable;
class User extends Authenticatable
{
use HasApiTokens, Notifiable;
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'name', 'email', 'password',
];
/**
* The attributes that should be hidden for arrays.
*
* @var array
*/
protected $hidden = [
'password', 'remember_token',
];
/**
* The attributes that should be cast to native types.
*
* @var array
*/
protected $casts = [
'email_verified_at' => 'datetime',
];
}
namespace App\Providers;
use Laravel\Passport\Passport;
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
use Illuminate\Support\Facades\Gate;
class AuthServiceProvider extends ServiceProvider
{
/**
* The policy mappings for the application.
*
* @var array
*/
protected $policies = [
// 'App\Model' => 'App\Policies\ModelPolicy',
];
/**
* Register any authentication / authorization services.
*
* @return void
*/
public function boot()
{
$this->registerPolicies();
Passport::routes();
//
}
}
'guards' => [
'web' => [
'driver' => 'session',
'provider' => 'users',
],
'api' => [
'driver' => 'passport',
'provider' => 'users',
'hash' => false,
],
],
Which user ID should the client be assigned to?:
> 1
What should we name the client?:
> Demo OAuth2 Client Account
Where should we redirect the request after authorization?
[http://localhost/auth/callback]:
> http://localhost/oauth2_client/callback.php
New client created successfully.
Client ID: 1
Client secret: zMm0tQ9Cp7LbjK3QTgPy1pssoT1X0u7sg0YWUW01
use App\Http\Controllers\Controller;
use Illuminate\Http\Request;
use App\User;
class UserController extends Controller
{
public function get(Request $request)
{
$user_id = $request->get("uid", 0);
$user = User::find($user_id);
return $user;
}
}
Route::middleware('auth:api')->get('/user/get', 'UserController@get');
|
範囲:
openid メール プロファイル
|
|
認可エンドポイント:
http://your-laravel-site-url/oauth/authorize
|
|
トークンエンドポイント:
http://your-laravel-site-url/oauth/token
|
|
ユーザー情報エンドポイント:
http://your-laravel-site-url/api/user/get
|
|
クライアント認証情報を設定します。
両方 (ヘッダーと本文)
|
JoomlaをOAuthクライアントとして正常に設定し、 JoomlaとLaravelのシングルサインオン(SSO)によるユーザー認証を実現しました。
このガイドでは、Joomla OAuth Clientプラグインを使用して、 LaravelをOAuthプロバイダー、JoomlaをOAuthクライアントとして設定することで、Joomla Laravelシングルサインオン(SSO)の設定を完了しました。このソリューションにより、数分以内にLaravelログイン認証情報を使用してJoomlaサイトへの安全なアクセスを展開できるようになります。
ご要望について迅速なガイダンス(メールまたはミーティング)をご希望の場合は、 joomlasupport@xecurify.comまでメールでお問い合わせください。弊社のチームがお客様のご要望に最適なソリューション/プランの選択をお手伝いいたします。
助けが必要? 私たちはここにいます!
お問い合わせありがとうございます。
24 時間以内に当社からのご連絡がない場合は、お気軽にフォローアップ メールを送信してください。 info@xecurify.com
リクエストが失敗しました。
メールを送信してみてください info@xecurify.com
