Skip to content

Commit

Permalink
Mac ProjFS kext: Denies access when provider does not respond
Browse files Browse the repository at this point in the history
If for some reason the provider does not respond to a kernel request originating from an authorisation check callback, we now deny that authorisation.
  • Loading branch information
pmj committed Aug 5, 2019
1 parent 06f173a commit a30c92b
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ProjFS.Mac/PrjFSKext/ProviderMessaging.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -179,14 +179,15 @@ bool ProviderMessaging_TrySendRequestAndWaitForResponse(
{
if (0 != sendError)
{
// TODO: appropriately handle unresponsive providers
*kauthResult = KAUTH_RESULT_DEFER;
// If message delivery fails, block the operation to avoid missed messages in the provider.
*kauthResult = KAUTH_RESULT_DENY;
}
else
{
while (!message.receivedResult &&
!s_isShuttingDown)
{
// TODO: appropriately handle unresponsive providers
Mutex_Sleep(5, &message, &s_outstandingMessagesMutex);
}

Expand Down

0 comments on commit a30c92b

Please sign in to comment.