Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(39)

Side by Side Diff: mojo/edk/system/entrypoint_class.h

Issue 1953293003: EDK: Add handle rights checking to the various entrypoints. (Closed) Base URL: https://github.com/domokit/mojo.git@work788_edk_handle_13.9-x-work787_edk_handle_13.8
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 MOJO_EDK_SYSTEM_ENTRYPOINT_CLASS_H_ 5 #ifndef MOJO_EDK_SYSTEM_ENTRYPOINT_CLASS_H_
6 #define MOJO_EDK_SYSTEM_ENTRYPOINT_CLASS_H_ 6 #define MOJO_EDK_SYSTEM_ENTRYPOINT_CLASS_H_
7 7
8 namespace mojo { 8 namespace mojo {
9 namespace system { 9 namespace system {
10 10
11 // Classes of "entrypoints"/"syscalls": Each dispatcher should support entire 11 // Classes of "entrypoints"/"syscalls": Each dispatcher should support entire
12 // classes of methods (and if they don't support a given class, they should 12 // classes of methods (and if they don't support a given class, they should
13 // return |MOJO_RESULT_INVALID_ARGUMENT| for all the methods in that class). 13 // return |MOJO_RESULT_INVALID_ARGUMENT| for all the methods in that class).
14 // Warning: A dispatcher method may be called even if the dispatcher's 14 // Warning: A dispatcher method may be called even if the dispatcher's
15 // |SupportsEntrypointClass()| indicates that the method's class is not 15 // |SupportsEntrypointClass()| indicates that the method's class is not
16 // supported. 16 // supported.
17 enum class EntrypointClass { 17 enum class EntrypointClass {
18 // Not an entrypoint; all implementations of
19 // |Dispatcher::SupportsEntrypointClass()| should return true for this:
20 NONE,
21
18 // |Dispatcher::ReadMessage()|, |Dispatcher::WriteMessage()|: 22 // |Dispatcher::ReadMessage()|, |Dispatcher::WriteMessage()|:
19 MESSAGE_PIPE, 23 MESSAGE_PIPE,
20 24
21 // |Dispatcher::SetDataPipeProducerOptions()|, 25 // |Dispatcher::SetDataPipeProducerOptions()|,
22 // |Dispatcher::GetDataPipeProducerOptions()|, 26 // |Dispatcher::GetDataPipeProducerOptions()|,
23 // |Dispatcher::WriteData()|, |Dispatcher::BeginWriteData()|, 27 // |Dispatcher::WriteData()|, |Dispatcher::BeginWriteData()|,
24 // |Dispatcher::EndWriteData()|: 28 // |Dispatcher::EndWriteData()|:
25 DATA_PIPE_PRODUCER, 29 DATA_PIPE_PRODUCER,
26 30
27 // |Dispatcher::SetDataPipeConsumerOptions()|, 31 // |Dispatcher::SetDataPipeConsumerOptions()|,
28 // |Dispatcher::GetDataPipeConsumerOptions()|, |Dispatcher::ReadData()|, 32 // |Dispatcher::GetDataPipeConsumerOptions()|, |Dispatcher::ReadData()|,
29 // |Dispatcher::BeginReadData()|, |Dispatcher::EndReadData()|: 33 // |Dispatcher::BeginReadData()|, |Dispatcher::EndReadData()|:
30 DATA_PIPE_CONSUMER, 34 DATA_PIPE_CONSUMER,
31 35
32 // |Dispatcher::DuplicateBufferHandle()|, 36 // |Dispatcher::DuplicateBufferHandle()|,
33 // |Dispatcher::GetBufferInformation()|, |Dispatcher::MapBuffer()|: 37 // |Dispatcher::GetBufferInformation()|, |Dispatcher::MapBuffer()|:
34 BUFFER, 38 BUFFER,
35 }; 39 };
36 40
37 } // namespace system 41 } // namespace system
38 } // namespace mojo 42 } // namespace mojo
39 43
40 #endif // MOJO_EDK_SYSTEM_ENTRYPOINT_CLASS_H_ 44 #endif // MOJO_EDK_SYSTEM_ENTRYPOINT_CLASS_H_
OLDNEW
« no previous file with comments | « mojo/edk/system/data_pipe_consumer_dispatcher.cc ('k') | mojo/edk/system/message_pipe_dispatcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698