This uses an RAII class to log a single message for whether the brokering was allowed or blocked. This removes the console logging. This was only originally added for old style extensions. They could override most firefox code and could cause violations. CallNtOpenProcessTokenEx loses its log calls with no SYSCALL_BROKERING replacement. The token ACL now retains the user's own SID plus the sandbox random SID so both normal and restricted checks pass anyway. Threading the macros through this non-Target* helper isn't worth it. It also removes the stack trace logging, this is now difficult to get working in strong sandboxes and will be replaced by profiler markers. Differential Revision: https://phabricator.services.mozilla.com/D309372
36 lines
882 B
C++
36 lines
882 B
C++
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
#ifndef XREChildData_h
|
|
#define XREChildData_h
|
|
|
|
#if defined(XP_WIN) && defined(MOZ_SANDBOX)
|
|
# include "mozilla/sandboxing/TargetGeckoServices.h"
|
|
|
|
namespace sandbox {
|
|
class BrokerServices;
|
|
class TargetServices;
|
|
} // namespace sandbox
|
|
#endif
|
|
|
|
/**
|
|
* Data needed to start a child process.
|
|
*/
|
|
struct XREChildData {
|
|
#if defined(XP_WIN) && defined(MOZ_SANDBOX)
|
|
/**
|
|
* Chromium sandbox TargetServices.
|
|
*/
|
|
sandbox::TargetServices* sandboxTargetServices = nullptr;
|
|
|
|
/**
|
|
* Callback to set TargetGeckoServices in the chromium sandbox code.
|
|
*/
|
|
mozilla::sandboxing::SetTargetGeckoServicesCb setTargetGeckoServices =
|
|
nullptr;
|
|
#endif
|
|
};
|
|
|
|
#endif // XREChildData_h
|