ipc_tags.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  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
  3. // found in the LICENSE file.
  4. #ifndef SANDBOX_WIN_SRC_IPC_TAGS_H_
  5. #define SANDBOX_WIN_SRC_IPC_TAGS_H_
  6. namespace sandbox {
  7. enum class IpcTag {
  8. UNUSED = 0,
  9. PING1, // Takes a cookie in parameters and returns the cookie
  10. // multiplied by 2 and the tick_count. Used for testing only.
  11. PING2, // Takes an in/out cookie in parameters and modify the cookie
  12. // to be multiplied by 3. Used for testing only.
  13. NTCREATEFILE,
  14. NTOPENFILE,
  15. NTQUERYATTRIBUTESFILE,
  16. NTQUERYFULLATTRIBUTESFILE,
  17. NTSETINFO_RENAME,
  18. CREATENAMEDPIPEW,
  19. NTOPENTHREAD,
  20. NTOPENPROCESS,
  21. NTOPENPROCESSTOKEN,
  22. NTOPENPROCESSTOKENEX,
  23. GDI_GDIDLLINITIALIZE,
  24. GDI_GETSTOCKOBJECT,
  25. USER_REGISTERCLASSW,
  26. CREATETHREAD,
  27. NTCREATESECTION,
  28. WS2SOCKET,
  29. LAST
  30. };
  31. constexpr size_t kMaxServiceCount = 64;
  32. constexpr size_t kMaxIpcTag = static_cast<size_t>(IpcTag::LAST);
  33. static_assert(kMaxIpcTag <= kMaxServiceCount, "kMaxServiceCount is too low");
  34. } // namespace sandbox
  35. #endif // SANDBOX_WIN_SRC_IPC_TAGS_H_