Open nuclear4547 opened 5 months ago
Need PR in Jobs\Middleware\CheckTokenScope.php like this
// in case token got required scope and job require it - forward
if (in_array($job->getScope(), $job->getToken()->scopes)) {
$next($job);
return;
} else {
logger()->warning(
sprintf('[Jobs][Middlewares][%s] Check Token Scope -> Removing job due to required scopes not matching with token related scopes profile.', $job->job->getJobId()),
[
'fqcn' => get_class($job),
'job_scopes' => $job->getScope(),
'character_id' => $job->getToken()->character_id,
'scopes_profile' => $job->getToken()->scopes_profile,
]);
$job->delete();
return;
}
I think the actual solution is preventing the job being queued if the scope is not available. Is it always killmail jobs?
A job requiring a not granted scope has been queued
User have only publicData scopeAnother
data
Checking Local and Latest Versions. Please wait... +--------------------+---------------+----------------+ | Package Name | Local Version | Latest Version | +--------------------+---------------+----------------+ | SeAT API | 5.0.0 | 5.0.0 | | SeAT Eseye | 3.0.1 | 3.0.1 | | SeAT Eve API | 5.0.13 | 5.0.13 | | SeAT Notifications | 5.0.8 | 5.0.8 | | SeAT Services | 5.0.7 | 5.0.7 | | SeAT Web | 5.0.13 | 5.0.13 | +--------------------+---------------+----------------+