BEdita API doc | 4-cactus
  • Namespace
  • Class
  • Tree
  • Deprecated
  • Download

Namespaces

  • BEdita
    • API
      • Auth
      • Controller
        • Admin
        • Component
        • Model
      • Error
      • Event
      • Exception
      • Middleware
      • Model
        • Action
      • Network
        • Exception
      • Shell
      • TestSuite
      • Utility
    • Core
      • Configure
        • Engine
      • Database
        • Type
      • Exception
      • Filesystem
        • Adapter
        • Exception
        • Thumbnail
      • I18n
      • Job
        • Service
      • Mailer
        • Preview
        • Transport
      • Model
        • Action
        • Behavior
        • Entity
        • Table
        • Validation
      • ORM
        • Inheritance
        • Locator
        • Rule
      • Shell
        • Task
      • State
      • TestSuite
        • Fixture
      • Utility

Classes

  • AnonymousAuthenticate
  • JwtAuthenticate
  • OAuth2Authenticate
  • OTPAuthenticate
  • UuidAuthenticate

Class OAuth2Authenticate

Authenticate users via OAuth2 providers.

Cake\Auth\BaseAuthenticate
Extended by BEdita\API\Auth\OAuth2Authenticate
Namespace: BEdita\API\Auth
Since: 4.0.0
Located at API/src/Auth/OAuth2Authenticate.php

Methods summary

public
# authenticate( Cake\Http\ServerRequest $request, Cake\Http\Response $response )
public
# getUser( Cake\Http\ServerRequest $request )
protected array
# getOAuth2Response( string $url, string $accessToken )

Get response from an OAuth2 provider

Get response from an OAuth2 provider

Parameters

$url
OAuth2 provider URL
$accessToken
Access token to use in request

Returns

array
Response from an OAuth2 provider

Codecoverageignore

public
# unauthenticated( Cake\Http\ServerRequest $request, Cake\Http\Response $response )

Properties summary

protected array $_defaultConfig

Default config for this object.

Default config for this object.

  • authProviders The AuthProviders entities associated to this authentication component. Array formatted with auth_providers.name as key, from AuthProvidersTable::findAuthenticate()
  • fields The fields to use to identify a user by.
  • userModel The alias for users table, defaults to Users.
  • finder The finder method to use to fetch user record. Defaults to 'all'. You can set finder name as string or an array where key is finder name and value is an array passed to Table::find() options. E.g. ['finderName' => ['some_finder_option' => 'some_value']]
  • passwordHasher Password hasher class. Can be a string specifying class name or an array containing className key, any other keys will be passed as config to the class. Defaults to 'Default'.
  • Options scope and contain have been deprecated since 3.1. Use custom finder instead to modify the query to fetch user record.
# [ 'authProviders' => [], 'userModel' => 'Users', 'fields' => [ 'username' => 'ExternalAuth.provider_username', 'password' => null, ], 'finder' => null, 'passwordHasher' => 'Default', ]
BEdita API doc | 4-cactus API documentation generated by ApiGen