1 | <?php |
||
8 | class VerifySlackRequest |
||
9 | { |
||
10 | /** @var SlackRequestSignature */ |
||
11 | private $slackRequestSignature; |
||
12 | |||
13 | public function __construct(SlackRequestSignature $slackRequestSignature) |
||
17 | |||
18 | /** |
||
19 | * @param \Illuminate\Http\Request $request |
||
20 | * @param \Closure $next |
||
21 | * |
||
22 | * @return mixed |
||
23 | */ |
||
24 | public function handle($request, Closure $next) |
||
34 | |||
35 | private function isEqualsSignature(string $signature, string $slackSignature): bool |
||
39 | } |
||
40 |
This check looks at variables that are passed out again to other methods.
If the outgoing method call has stricter type requirements than the method itself, an issue is raised.
An additional type check may prevent trouble.