OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // Defines messages between the browser and NaCl process. | 5 // Defines messages between the browser and NaCl process. |
6 | 6 |
7 // Multiply-included message file, no traditional include guard. | 7 // Multiply-included message file, no traditional include guard. |
8 #include "base/process.h" | 8 #include "base/process.h" |
9 #include "chrome/common/nacl_types.h" | 9 #include "chrome/common/nacl_types.h" |
10 #include "ipc/ipc_channel_handle.h" | 10 #include "ipc/ipc_channel_handle.h" |
11 #include "ipc/ipc_message_macros.h" | 11 #include "ipc/ipc_message_macros.h" |
| 12 #include "ipc/ipc_platform_file.h" |
12 | 13 |
13 #define IPC_MESSAGE_START NaClMsgStart | 14 #define IPC_MESSAGE_START NaClMsgStart |
14 | 15 |
15 IPC_STRUCT_TRAITS_BEGIN(nacl::NaClStartParams) | 16 IPC_STRUCT_TRAITS_BEGIN(nacl::NaClStartParams) |
16 IPC_STRUCT_TRAITS_MEMBER(handles) | 17 IPC_STRUCT_TRAITS_MEMBER(handles) |
17 IPC_STRUCT_TRAITS_MEMBER(debug_stub_server_bound_socket) | 18 IPC_STRUCT_TRAITS_MEMBER(debug_stub_server_bound_socket) |
18 IPC_STRUCT_TRAITS_MEMBER(validation_cache_enabled) | 19 IPC_STRUCT_TRAITS_MEMBER(validation_cache_enabled) |
19 IPC_STRUCT_TRAITS_MEMBER(validation_cache_key) | 20 IPC_STRUCT_TRAITS_MEMBER(validation_cache_key) |
20 IPC_STRUCT_TRAITS_MEMBER(version) | 21 IPC_STRUCT_TRAITS_MEMBER(version) |
21 IPC_STRUCT_TRAITS_MEMBER(enable_exception_handling) | 22 IPC_STRUCT_TRAITS_MEMBER(enable_exception_handling) |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 // contains the signatures of previously validated code chunks. | 72 // contains the signatures of previously validated code chunks. |
72 IPC_SYNC_MESSAGE_CONTROL1_1(NaClProcessMsg_QueryKnownToValidate, | 73 IPC_SYNC_MESSAGE_CONTROL1_1(NaClProcessMsg_QueryKnownToValidate, |
73 std::string, /* A validation signature */ | 74 std::string, /* A validation signature */ |
74 bool /* Can validation be skipped? */) | 75 bool /* Can validation be skipped? */) |
75 | 76 |
76 // Used by the NaCl process to add a validation signature to the validation | 77 // Used by the NaCl process to add a validation signature to the validation |
77 // database in the browser. | 78 // database in the browser. |
78 IPC_MESSAGE_CONTROL1(NaClProcessMsg_SetKnownToValidate, | 79 IPC_MESSAGE_CONTROL1(NaClProcessMsg_SetKnownToValidate, |
79 std::string /* A validation signature */) | 80 std::string /* A validation signature */) |
80 | 81 |
| 82 // Used by the NaCl process to acquire trusted information about a file directly |
| 83 // from the browser, including the file's path as well as a fresh version of the |
| 84 // file handle. |
| 85 IPC_SYNC_MESSAGE_CONTROL2_2(NaClProcessMsg_ResolveFileToken, |
| 86 uint64, /* file_token_lo */ |
| 87 uint64, /* file_token_hi */ |
| 88 IPC::PlatformFileForTransit, /* fd */ |
| 89 base::FilePath /* Path opened to get fd */) |
| 90 |
81 // Notify the browser process that the server side of the PPAPI channel was | 91 // Notify the browser process that the server side of the PPAPI channel was |
82 // created successfully. | 92 // created successfully. |
83 IPC_MESSAGE_CONTROL1(NaClProcessHostMsg_PpapiChannelCreated, | 93 IPC_MESSAGE_CONTROL1(NaClProcessHostMsg_PpapiChannelCreated, |
84 IPC::ChannelHandle /* channel_handle */) | 94 IPC::ChannelHandle /* channel_handle */) |
OLD | NEW |