Skip to content

Commit cf1f303

Browse files
add missing RBAC checks to twingraph service
1 parent bf5f996 commit cf1f303

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

twingraph/src/main/kotlin/com/cosmotech/twingraph/api/TwingraphServiceImpl.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,8 @@ class TwingraphServiceImpl(
118118

119119
override fun jobStatus(organizationId: String, jobId: String): String {
120120
checkIfGraphFunctionalityIsAvailable()
121+
organizationService.getVerifiedOrganization(organizationId)
122+
121123
val twingraphImportJobInfoRequest = TwingraphImportJobInfoRequest(this, jobId, organizationId)
122124
this.eventPublisher.publishEvent(twingraphImportJobInfoRequest)
123125
logger.debug("TwingraphImportEventResponse={}", twingraphImportJobInfoRequest.response)
@@ -151,6 +153,7 @@ class TwingraphServiceImpl(
151153

152154
override fun getGraphMetaData(organizationId: String, graphId: String): Map<String, String> {
153155
checkIfGraphFunctionalityIsAvailable()
156+
organizationService.getVerifiedOrganization(organizationId)
154157
if (unifiedJedis.exists(graphId.toRedisMetaDataKey())) {
155158
return unifiedJedis.hgetAll(graphId.toRedisMetaDataKey())
156159
}

0 commit comments

Comments
 (0)