Under an operation in Business Automation, there is a "No access rights granted to method" error. How is it possible to determine which privilege is missing to perform the operation?
Note! Below procedure is valid for BA < 6.0. Since BA 6.0 different logs are written (see 125329), so its needed to use WWW.log instead of www.log and generic_worker.log instead of logs of other containers.
Check www.log while receiving the error. Find the exception, like:
[14-04-05 09:30:37.913 RO_0:2082 RQ79200 TRC] +++ DataPacket* RemoteObject::Call(const std::string&, DataPacket&, int)((RO_0:2082) method = IsFullyRegistred BM_Container::BM_Object, tmout = 86 400, user = 1007028, transaction = 78305, SID = 14513, lang = en, HP) [14-04-05 09:30:37.915 RO_0:2082 RQ79200 TRC] ... *** INTERRUPTED BY EXCEPTION *** DataPacket* RemoteObject::Call(const std::string&, DataPacket&, int) [14-04-05 09:30:37.915 RO_0:2082 RQ79200 TRC] (RO_0:2082) <98:0:2082> disconnected. ... [14-04-05 09:30:37.915 UIWorker RQ79200 ERR] RequestError:System Error ^H No access rights granted to method
Check the log where the failed method was executed. In the above example, it was the IsFullyRegistred method in BM_Container. There should be the following error in BM.log:
[14-04-05 09:30:37.914 Worker1.195 RQ79200 ERR] Method BM_Container::Worker1.195.IsFullyRegistred is forbidden for user 1007028
Find the method in the *.methods.list file of the corresponding container. In our example, it is
[root@bm ~]# grep IsFullyRegistred ~bm/conf/BM.methods.list BM Account IsFullyRegistred ACCOUNTS_VIEW_DET BM Account IsFullyRegistred CUST_MAKE_PURCHASES
You will see the privileges that allow the method to be executed. In this example, user 1007028 does not have the ACCOUNTS_VIEW_DET or the CUST_MAKE_PURCHASES privilege.
Generally, resolving the issue means assigning the missing privileges to the user. However, do not blindly assign privileges. Check which were supposed to be assigned, and why they were not, as this may be a symptom of a larger bug or misconfiguration.