Skip to content

Commit d0b8478

Browse files
committed
chore: drop explanatory comment on the current-permissions OAuth gate
1 parent c71c2a6 commit d0b8478

1 file changed

Lines changed: 0 additions & 3 deletions

File tree

backend/api/src/main/kotlin/io/tolgee/api/v2/controllers/ApiKeyController.kt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -216,9 +216,6 @@ class ApiKeyController(
216216
else -> throw BadRequestException(Message.INVALID_AUTHENTICATION_METHOD)
217217
}
218218

219-
// The route has no project path variable, so ProjectAuthorizationInterceptor never narrows an OAuth token here.
220-
// Without this gate the response would still expose a project's name, the user's role and permitted languages for a
221-
// project outside the token's consented set (only `scopes` is emptied below), leaking past the confinement.
222219
authenticationFacade.oauthTokenCredentials?.let {
223220
if (!it.coversProject(projectIdNotNull)) throw PermissionException(Message.USER_HAS_NO_PROJECT_ACCESS)
224221
}

0 commit comments

Comments
 (0)