Skip to content
This repository has been archived by the owner on Feb 18, 2021. It is now read-only.

Add auth resource to CreateConsumerGroup and refactor code a little bit #213

Merged
merged 1 commit into from
May 25, 2017

Conversation

hiboyang
Copy link
Contributor

No description provided.

@hiboyang hiboyang requested review from datoug and kirg May 24, 2017 23:47
@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 4f48ff9 on security8 into ** on master**.

authResource := common.GetResourceURNCreateConsumerGroup(h.SCommon, createRequest.DestinationPath)
err = h.GetAuthManager().Authorize(authSubject, common.OperationRead, common.Resource(authResource))

err = h.checkAuth(ctx, authResource, common.OperationRead, lclLg)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should OperationRead actually be OperationCreate?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here we use "Read Destination" as the permission to create consumer group. Try to model the CRUD permission on destination.

@hiboyang hiboyang merged commit d85ebe7 into master May 25, 2017
@hiboyang hiboyang deleted the security8 branch May 25, 2017 04:57
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants