wso2 API manager for authorsation and authentication of a web application

孤街浪徒 提交于 2019-12-06 20:52:31

you can use wso2 appmanager to control the access of any web apps[1]. App manager supports role based access control as well as xacml policy based access control . In order to provide api level role based security you can use scopes[2] in wso2 api manager

[1] https://docs.wso2.com/display/APPM120/Web+Application+Resource+Authorization

[2] https://docs.wso2.com/display/APPM120/Web+Application+Resource+Authorization

Bee

Let me suggest another solution. I haven't tried this with APIM. But since APIM also has Identity features installed in it, this should work.

Use OpenID Connect for login. See here for a sample. This sample is for IS, but it should work for APIM too. Only endpoint URLs are different in APIM like this.

Token: https://localhost:8243/token 
Revoke: https://localhost:8243/revoke 
Authorize: https://localhost:8243/authorize 

There, when a user login, you get an ID_token which contains user claims. You can allow/deny page views depending on those data.

In above step, you create an SP and generate a client key-secret pair. You can set the same keys in APIM's application. Read this.

Then, as I mentioned here, you can use scopes to secure your APIs by roles.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!