Page 1 of 1

Re: About Question enthuware.oce-ejbd.v6.2.606 :

Posted: Thu Jun 11, 2015 7:15 pm
by himaiMinh
For option 5 explanation, "the bean can call getCallerPrincipal and based on that it can either continue executing..."
I think the bean can also call isCallerInRole to determine if it should continue the business logic.
For example:

Code: Select all

          if ( isCallerInRole("teacher")){
                    updateStudentGrades();
            }
          else  if (isCallerInRole("admin)) {
                        updateStudentInfo();
                }



Re: About Question enthuware.oce-ejbd.v6.2.606 :

Posted: Thu Jun 11, 2015 8:03 pm
by admin
Checking roles will not do because the restriction is to be based on client and not on role. For example, out of two clients in the same role, you may want to change the logic for one client.
HTH,
Paul.