| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef SANDBOX_MAC_LAUNCHD_INTERCEPTION_SERVER_H_ | 5 #ifndef SANDBOX_MAC_LAUNCHD_INTERCEPTION_SERVER_H_ |
| 6 #define SANDBOX_MAC_LAUNCHD_INTERCEPTION_SERVER_H_ | 6 #define SANDBOX_MAC_LAUNCHD_INTERCEPTION_SERVER_H_ |
| 7 | 7 |
| 8 #include <dispatch/dispatch.h> | 8 #include <dispatch/dispatch.h> |
| 9 | 9 |
| 10 #include "base/mac/scoped_mach_port.h" | 10 #include "base/mac/scoped_mach_port.h" |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 | 49 |
| 50 // Forwards the original |request| on to real bootstrap server for handling. | 50 // Forwards the original |request| on to real bootstrap server for handling. |
| 51 void ForwardMessage(IPCMessage request); | 51 void ForwardMessage(IPCMessage request); |
| 52 | 52 |
| 53 // The sandbox for which this message server is running. | 53 // The sandbox for which this message server is running. |
| 54 const BootstrapSandbox* sandbox_; | 54 const BootstrapSandbox* sandbox_; |
| 55 | 55 |
| 56 // The Mach IPC server. | 56 // The Mach IPC server. |
| 57 scoped_ptr<MessageServer> message_server_; | 57 scoped_ptr<MessageServer> message_server_; |
| 58 | 58 |
| 59 // Whether or not the system is using an XPC-based launchd. |
| 60 bool xpc_launchd_; |
| 61 |
| 59 // The Mach port handed out in reply to denied look up requests. All denied | 62 // The Mach port handed out in reply to denied look up requests. All denied |
| 60 // requests share the same port, though nothing reads messages from it. | 63 // requests share the same port, though nothing reads messages from it. |
| 61 base::mac::ScopedMachReceiveRight sandbox_port_; | 64 base::mac::ScopedMachReceiveRight sandbox_port_; |
| 62 // The send right for the above |sandbox_port_|, used with | 65 // The send right for the above |sandbox_port_|, used with |
| 63 // MACH_MSG_TYPE_COPY_SEND when handing out references to the dummy port. | 66 // MACH_MSG_TYPE_COPY_SEND when handing out references to the dummy port. |
| 64 base::mac::ScopedMachSendRight sandbox_send_port_; | 67 base::mac::ScopedMachSendRight sandbox_send_port_; |
| 65 | 68 |
| 66 // The compatibility shim that handles differences in message header IDs and | 69 // The compatibility shim that handles differences in message header IDs and |
| 67 // request/reply structures between different OS X versions. | 70 // request/reply structures between different OS X versions. |
| 68 scoped_ptr<OSCompatibility> compat_shim_; | 71 scoped_ptr<OSCompatibility> compat_shim_; |
| 69 }; | 72 }; |
| 70 | 73 |
| 71 } // namespace sandbox | 74 } // namespace sandbox |
| 72 | 75 |
| 73 #endif // SANDBOX_MAC_LAUNCHD_INTERCEPTION_SERVER_H_ | 76 #endif // SANDBOX_MAC_LAUNCHD_INTERCEPTION_SERVER_H_ |
| OLD | NEW |