K2 environment is 5.2 with Fix Pack 10. I am getting this error when the smartForm first initializes.
Now this has been resolved in K2 Blackpearl forum and I have tried disabling rules but no luck as per recommendations shown in that thread. Permissions are setup appropriately.
Full Error message:
Unauthorised SmartObject access
Scope Name:SourceCode.Forms.dll Declaring Type
at SourceCode.Forms.AppFramework.FormRuntime.DecryptSmoMethodText(String smartObjMethodText, Guid smoGuid, String smoName)
at SourceCode.Forms.AppFramework.FormRuntime.Decrypt(BrokerPackageCollection packages, SmartObjectClientServer smoClientServer)
at SourceCode.Forms.AppFramework.FormRuntime.WorkXmlToApi(Stream input, Stream output)
at SourceCode.Forms.Runtime.AJAXCall.ProcessRequestInternal(HttpContext context)
Are permissions set on the top category level or have they been set on individual objects? If set on the top level, is the smartobject itself in the same category as the form that the user has access to?
Below are my responses:
If you suspect that the issue is related to category security permissions (see point # 1), then you can confirm this by adding the test account/user running the K2 SSIS POC V2 form to the out-of-the box Security Administrators role (K2 Management > Users > Roles > Security Administrators). My other guess is the missing process rights and it might not related to category security permissions (point # 1). You will probably need SmartObject Logging to get more details out of it (see point # 2). Also, I noticed there are 2 views on the form, one view is Process Overview and the other view is Workflows. Do you happen to know if the test user/account can run each individual view? What are the SmartObjects behind those two views? Can the test user/account execute the SmartObject?
Point # 1:
- Issue with Security setting (Authorization Framework).
Add test account to Security Administrators role and test the form. Users in this role has full admin rights and will overwrite any category security settings. If the form loads successfully, then you can start investigate on your side why this is the case.
Point # 2 (issue is not related to category permissions):
- Enable SmartObject Server Logging (https://help.k2.com/kb000298) and reproduce the issue. A restart of K2 service is required for the logging to take effect.
-Take a look at the brokerpackageout.log file (%ProgramFiles%K2 blackpearlServiceBrokerLogsrokerpackageout.log). The error will probably show up in there. You can correlate the timestamp to an event in the brokerpackagein.log (%ProgramFiles%K2 blackpearlServiceBrokerLogsrokerpackagein.log). This will help to identify the SmartObject and its method. Next, you can test if the SmartObject is executed successfuly under the user account.
Please let us know if that helps further narrowing down the issue.