1 | <?php |
||
13 | final class AuthorizationHeaderExtractor implements TokenExtractorInterface |
||
14 | { |
||
15 | /** |
||
16 | * A custom scheme expected in the Authorization header. |
||
17 | * |
||
18 | * @var string |
||
19 | */ |
||
20 | private $scheme; |
||
21 | |||
22 | /** |
||
23 | * Construct a new instance of this extractor |
||
24 | * |
||
25 | * @param string $scheme A custom scheme expected in the Authorization header. |
||
26 | */ |
||
27 | public function __construct(string $scheme = 'hmac') |
||
31 | |||
32 | /** |
||
33 | * Extracts the HMAC authentication Token from the given PSR-7 $request. |
||
34 | * |
||
35 | * @param ServerRequestInterface $request The request containing the HMAC token data. |
||
36 | * |
||
37 | * @return Token |
||
38 | * |
||
39 | * @throws AuthenticationException 400 Thrown if any required data is missing. |
||
40 | */ |
||
41 | public function extract(ServerRequestInterface $request) : Token |
||
57 | } |
||
58 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.