wpgsh / cloud4water

Apache License 2.0
0 stars 0 forks source link

Few more questions about development #17

Closed asd1245dss closed 7 years ago

asd1245dss commented 7 years ago
  1. The water equipment managment application is using the same oauth2 process as the authentication application,so the entity user,accesstoken,registeredclient is all needed.And according to the Authentication Flows diagram in the chapter of Authentication Application,these two application should share the same user and registered client,how to synchronize the data?

  2. When request rest api,it should be through the servlet first,but how to forward the request to the ObjectResource or any other jax-rs class,using request.getRequestDispatcher().forward(request, response)?

  3. imageIf the user has the permission for China,but he wants to check permission for ShangHai,how to make it in the hql statment?

  4. ~~qq 20161104084546 FineGrainedAuthorizationScheme is not invoked after request the getObject method.~~

  5. The annotation FineGrainedAuthorization doesn't take effect in my unit test.I use jersey test dependency to do rest api test,everthings is ok except the custom annotation.Following is my test dependencies; image image image

alexlukichev commented 7 years ago
  1. WEMP and Authn App only share userId which is synchronized during initial user provisioning stage in the WEMP (when the new user first contacts the app). The registered clients are not shared. In fact, for Authn the registered client is WEMP, and for WEMP the registered client is SWMS app.
  2. The API request doesn't need to go through any custom servlet and can be served directly by a JAX-RS servlet (at /services).
  3. To check such kind of permission one need to construct the query that will check permissions for "Shanghai", its parent, and parent of its parent.