Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F4106214
AccessToken.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
AccessToken.php
View Options
<?php
namespace
MediaWiki\Extension\OAuth\AuthorizationProvider
;
use
League\OAuth2\Server\Exception\OAuthServerException
;
use
Psr\Http\Message\ResponseInterface
;
use
Psr\Http\Message\ServerRequestInterface
;
abstract
class
AccessToken
extends
AuthorizationProvider
implements
IAccessTokenProvider
{
/**
* @param ServerRequestInterface $request
* @param ResponseInterface $response
*
* @return ResponseInterface
* @throws OAuthServerException
*/
public
function
getAccessTokens
(
ServerRequestInterface
$request
,
ResponseInterface
$response
):
ResponseInterface
{
$this
->
logAccessTokenRequest
(
$request
);
return
$this
->
server
->
respondToAccessTokenRequest
(
$request
,
$response
);
}
/**
* @param ServerRequestInterface $request
*/
protected
function
logAccessTokenRequest
(
ServerRequestInterface
$request
)
{
$this
->
logger
->
info
(
"OAuth2: Access token request - Grant type {grant}, client id: {client}"
,
[
'grant'
=>
$this
->
getGrantSingleton
()->
getIdentifier
(),
'client'
=>
$this
->
getClientIdFromRequest
(
$request
)
]
);
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Tue, Aug 18, 19:21 (2 w, 4 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
f3/20/c5b57fd332d7acff6170fe8fcab2
Default Alt Text
AccessToken.php (1 KB)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment