Posts

Post not yet marked as solved
7 Replies
3.3k Views
Hi all,I have been able to reproduce a scenario where apps/files do not open when I subscribe to ES_EVENT_TYPE_AUTH_OPEN and set caching to true while authorizing the opening of a file by responding to es_respond_flags_result(,,,).In details, If I subscribe to ES_EVENT_TYPE_AUTH_OPEN event and set bool cache = true in es_respond_flags_result(,,,)es_handler_block_t file_cbk = ^(es_client_t *client, const es_message_t *msg) { log_event_message(msg); // just to log events to the console int32_t flag = msg->event.open.fflag; // getting the file-opening mask es_respond_result_t res = es_respond_flags_result(client, msg, flag, true); // simply allowing all files to open and cache the result if (ES_RESPOND_RESULT_SUCCESS != res) LOG_ERROR("es_respond_auth_result: %d", res); };Whatever application or file that I open leads me to some EPERM popup, "The Application cannot be opened" and complete unresponsiveness of the machine with occasional spinning beach balls. As you can see, I am not doing any sort of processing with the file event messages (apart from just logging to the console) - I'm simply allowing all file open operations and caching the results.This issue with es_respond_flags_result(,,,) only appears if I cache the event result; without caching everything works as expected. However, if I subscribe to ES_EVENT_TYPE_AUTH_EXEC event and respond using es_respond_auth_result(,,,) authorizing the execution of a process with the caching parameter set to true, everything seems to work gracefully.I am completely new to Objective C so there's a high chance of doing something wrong - please LMK if I am handling the event messages in an undesired fashion and suggest me the way it should be handled. If this is a known/duplicate issue, please point me to the relevant ticket or guide me on the way forward.Also added a 2 min screen recording illustrating the issue (Unlisted video): https://youtu.be/R9zSpHk72_QLooking forward to your help and support...Thanks!Uddalak
Posted
by Uddalak.
Last updated
.