[email protected] | 3b48dbc | 2012-01-06 16:34:17 | [diff] [blame] | 1 | // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
| 5 | // This class responds to requests from renderers for the list of plugins, and |
| 6 | // also a proxy object for plugin instances. |
| 7 | |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 8 | #ifndef CONTENT_BROWSER_PLUGIN_SERVICE_IMPL_H_ |
| 9 | #define CONTENT_BROWSER_PLUGIN_SERVICE_IMPL_H_ |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 10 | |
[email protected] | 47214d88 | 2012-02-29 06:28:48 | [diff] [blame] | 11 | #include <map> |
[email protected] | 7dba43dc | 2011-11-10 01:57:58 | [diff] [blame] | 12 | #include <set> |
[email protected] | 47214d88 | 2012-02-29 06:28:48 | [diff] [blame] | 13 | #include <vector> |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 14 | |
| 15 | #include "base/basictypes.h" |
[email protected] | bdd6deb | 2011-12-21 03:03:24 | [diff] [blame] | 16 | #include "base/compiler_specific.h" |
[email protected] | 3b63f8f4 | 2011-03-28 01:54:15 | [diff] [blame] | 17 | #include "base/memory/scoped_vector.h" |
| 18 | #include "base/memory/singleton.h" |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 19 | #include "base/synchronization/waitable_event_watcher.h" |
[email protected] | a33fa9d | 2012-05-16 14:47:49 | [diff] [blame] | 20 | #include "base/threading/sequenced_worker_pool.h" |
[email protected] | 47214d88 | 2012-02-29 06:28:48 | [diff] [blame] | 21 | #include "base/time.h" |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 22 | #include "build/build_config.h" |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 23 | #include "content/browser/plugin_process_host.h" |
| 24 | #include "content/browser/ppapi_plugin_process_host.h" |
[email protected] | 8d128d6 | 2011-09-13 22:11:57 | [diff] [blame] | 25 | #include "content/common/content_export.h" |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 26 | #include "content/public/browser/plugin_service.h" |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 27 | #include "googleurl/src/gurl.h" |
| 28 | #include "ipc/ipc_channel_handle.h" |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 29 | |
| 30 | #if defined(OS_WIN) |
[email protected] | 3b63f8f4 | 2011-03-28 01:54:15 | [diff] [blame] | 31 | #include "base/memory/scoped_ptr.h" |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 32 | #include "base/win/registry.h" |
| 33 | #endif |
| 34 | |
[email protected] | 52348b2 | 2012-11-07 10:19:34 | [diff] [blame] | 35 | #if defined(OS_POSIX) && !defined(OS_OPENBSD) && !defined(OS_ANDROID) |
[email protected] | 493c800 | 2011-04-14 16:56:01 | [diff] [blame] | 36 | #include "base/files/file_path_watcher.h" |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 37 | #endif |
| 38 | |
[email protected] | d33e7cc | 2011-09-23 01:43:56 | [diff] [blame] | 39 | namespace base { |
| 40 | class MessageLoopProxy; |
| 41 | } |
| 42 | |
[email protected] | d33e7cc | 2011-09-23 01:43:56 | [diff] [blame] | 43 | namespace webkit { |
| 44 | namespace npapi { |
[email protected] | d33e7cc | 2011-09-23 01:43:56 | [diff] [blame] | 45 | class PluginList; |
| 46 | } |
| 47 | } |
| 48 | |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 49 | namespace content { |
| 50 | class BrowserContext; |
| 51 | class PluginDirWatcherDelegate; |
| 52 | class PluginLoaderPosix; |
| 53 | class PluginServiceFilter; |
| 54 | class ResourceContext; |
| 55 | struct PepperPluginInfo; |
| 56 | |
[email protected] | 209f2ae | 2012-03-13 01:28:08 | [diff] [blame] | 57 | // base::Bind() has limited arity, and the filter-related methods tend to |
| 58 | // surpass that limit. |
| 59 | struct PluginServiceFilterParams { |
| 60 | int render_process_id; |
| 61 | int render_view_id; |
| 62 | GURL page_url; |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 63 | ResourceContext* resource_context; |
[email protected] | 209f2ae | 2012-03-13 01:28:08 | [diff] [blame] | 64 | }; |
| 65 | |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 66 | class CONTENT_EXPORT PluginServiceImpl |
[email protected] | 329be05 | 2013-02-04 18:14:28 | [diff] [blame] | 67 | : NON_EXPORTED_BASE(public PluginService) { |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 68 | public: |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 69 | // Returns the PluginServiceImpl singleton. |
| 70 | static PluginServiceImpl* GetInstance(); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 71 | |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 72 | // PluginService implementation: |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 73 | virtual void Init() OVERRIDE; |
| 74 | virtual void StartWatchingPlugins() OVERRIDE; |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 75 | virtual bool GetPluginInfoArray( |
| 76 | const GURL& url, |
| 77 | const std::string& mime_type, |
| 78 | bool allow_wildcard, |
| 79 | std::vector<webkit::WebPluginInfo>* info, |
| 80 | std::vector<std::string>* actual_mime_types) OVERRIDE; |
| 81 | virtual bool GetPluginInfo(int render_process_id, |
| 82 | int render_view_id, |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 83 | ResourceContext* context, |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 84 | const GURL& url, |
| 85 | const GURL& page_url, |
| 86 | const std::string& mime_type, |
| 87 | bool allow_wildcard, |
| 88 | bool* is_stale, |
| 89 | webkit::WebPluginInfo* info, |
| 90 | std::string* actual_mime_type) OVERRIDE; |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 91 | virtual bool GetPluginInfoByPath(const base::FilePath& plugin_path, |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 92 | webkit::WebPluginInfo* info) OVERRIDE; |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 93 | virtual string16 GetPluginDisplayNameByPath( |
| 94 | const base::FilePath& path) OVERRIDE; |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 95 | virtual void GetPlugins(const GetPluginsCallback& callback) OVERRIDE; |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 96 | virtual PepperPluginInfo* GetRegisteredPpapiPluginInfo( |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 97 | const base::FilePath& plugin_path) OVERRIDE; |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 98 | virtual void SetFilter(PluginServiceFilter* filter) OVERRIDE; |
| 99 | virtual PluginServiceFilter* GetFilter() OVERRIDE; |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 100 | virtual void ForcePluginShutdown(const base::FilePath& plugin_path) OVERRIDE; |
| 101 | virtual bool IsPluginUnstable(const base::FilePath& plugin_path) OVERRIDE; |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 102 | virtual void RefreshPlugins() OVERRIDE; |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 103 | virtual void AddExtraPluginPath(const base::FilePath& path) OVERRIDE; |
| 104 | virtual void AddExtraPluginDir(const base::FilePath& path) OVERRIDE; |
| 105 | virtual void RemoveExtraPluginPath(const base::FilePath& path) OVERRIDE; |
| 106 | virtual void UnregisterInternalPlugin(const base::FilePath& path) OVERRIDE; |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 107 | virtual void RegisterInternalPlugin( |
[email protected] | c6f3dea | 2012-01-14 02:23:11 | [diff] [blame] | 108 | const webkit::WebPluginInfo& info, bool add_at_beginning) OVERRIDE; |
[email protected] | 57aece2 | 2012-10-10 22:10:27 | [diff] [blame] | 109 | virtual void GetInternalPlugins( |
| 110 | std::vector<webkit::WebPluginInfo>* plugins) OVERRIDE; |
[email protected] | 3a5180ae | 2011-12-21 02:39:38 | [diff] [blame] | 111 | virtual webkit::npapi::PluginList* GetPluginList() OVERRIDE; |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 112 | virtual void SetPluginListForTesting( |
| 113 | webkit::npapi::PluginList* plugin_list) OVERRIDE; |
[email protected] | 5904cb4 | 2012-09-24 15:05:20 | [diff] [blame] | 114 | #if defined(OS_MACOSX) |
| 115 | virtual void AppActivated() OVERRIDE; |
| 116 | #endif |
[email protected] | dfba876 | 2011-09-02 12:49:54 | [diff] [blame] | 117 | |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 118 | // Returns the plugin process host corresponding to the plugin process that |
| 119 | // has been started by this service. This will start a process to host the |
| 120 | // 'plugin_path' if needed. If the process fails to start, the return value |
| 121 | // is NULL. Must be called on the IO thread. |
| 122 | PluginProcessHost* FindOrStartNpapiPluginProcess( |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 123 | int render_process_id, const base::FilePath& plugin_path); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 124 | PpapiPluginProcessHost* FindOrStartPpapiPluginProcess( |
[email protected] | 6be31d20 | 2013-02-01 18:20:54 | [diff] [blame] | 125 | int render_process_id, |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 126 | const base::FilePath& plugin_path, |
| 127 | const base::FilePath& profile_data_directory, |
[email protected] | a50432d | 2011-09-30 16:32:14 | [diff] [blame] | 128 | PpapiPluginProcessHost::PluginClient* client); |
| 129 | PpapiPluginProcessHost* FindOrStartPpapiBrokerProcess( |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 130 | int render_process_id, const base::FilePath& plugin_path); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 131 | |
| 132 | // Opens a channel to a plugin process for the given mime type, starting |
| 133 | // a new plugin process if necessary. This must be called on the IO thread |
| 134 | // or else a deadlock can occur. |
| 135 | void OpenChannelToNpapiPlugin(int render_process_id, |
| 136 | int render_view_id, |
| 137 | const GURL& url, |
[email protected] | dfba876 | 2011-09-02 12:49:54 | [diff] [blame] | 138 | const GURL& page_url, |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 139 | const std::string& mime_type, |
| 140 | PluginProcessHost::Client* client); |
[email protected] | 6be31d20 | 2013-02-01 18:20:54 | [diff] [blame] | 141 | void OpenChannelToPpapiPlugin(int render_process_id, |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 142 | const base::FilePath& plugin_path, |
| 143 | const base::FilePath& profile_data_directory, |
[email protected] | a50432d | 2011-09-30 16:32:14 | [diff] [blame] | 144 | PpapiPluginProcessHost::PluginClient* client); |
[email protected] | 6be31d20 | 2013-02-01 18:20:54 | [diff] [blame] | 145 | void OpenChannelToPpapiBroker(int render_process_id, |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 146 | const base::FilePath& path, |
[email protected] | a50432d | 2011-09-30 16:32:14 | [diff] [blame] | 147 | PpapiPluginProcessHost::BrokerClient* client); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 148 | |
[email protected] | 4befe759 | 2011-09-14 22:49:09 | [diff] [blame] | 149 | // Cancels opening a channel to a NPAPI plugin. |
| 150 | void CancelOpenChannelToNpapiPlugin(PluginProcessHost::Client* client); |
| 151 | |
[email protected] | 47214d88 | 2012-02-29 06:28:48 | [diff] [blame] | 152 | // Used to monitor plug-in stability. |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 153 | void RegisterPluginCrash(const base::FilePath& plugin_path); |
[email protected] | 47214d88 | 2012-02-29 06:28:48 | [diff] [blame] | 154 | |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 155 | private: |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 156 | friend struct DefaultSingletonTraits<PluginServiceImpl>; |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 157 | |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 158 | // Creates the PluginServiceImpl object, but doesn't actually build the plugin |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 159 | // list yet. It's generated lazily. |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 160 | PluginServiceImpl(); |
| 161 | virtual ~PluginServiceImpl(); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 162 | |
[email protected] | 329be05 | 2013-02-04 18:14:28 | [diff] [blame] | 163 | void OnWaitableEventSignaled(base::WaitableEvent* waitable_event); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 164 | |
[email protected] | b6a2f8de | 2012-01-31 17:28:49 | [diff] [blame] | 165 | // Returns the plugin process host corresponding to the plugin process that |
| 166 | // has been started by this service. Returns NULL if no process has been |
| 167 | // started. |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 168 | PluginProcessHost* FindNpapiPluginProcess(const base::FilePath& plugin_path); |
[email protected] | dd9a095 | 2012-05-31 20:11:31 | [diff] [blame] | 169 | PpapiPluginProcessHost* FindPpapiPluginProcess( |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 170 | const base::FilePath& plugin_path, |
| 171 | const base::FilePath& profile_data_directory); |
| 172 | PpapiPluginProcessHost* FindPpapiBrokerProcess( |
| 173 | const base::FilePath& broker_path); |
[email protected] | b6a2f8de | 2012-01-31 17:28:49 | [diff] [blame] | 174 | |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 175 | void RegisterPepperPlugins(); |
| 176 | |
[email protected] | a33fa9d | 2012-05-16 14:47:49 | [diff] [blame] | 177 | // Run on the blocking pool to load the plugins synchronously. |
[email protected] | d33e7cc | 2011-09-23 01:43:56 | [diff] [blame] | 178 | void GetPluginsInternal(base::MessageLoopProxy* target_loop, |
| 179 | const GetPluginsCallback& callback); |
| 180 | |
[email protected] | 88ca491 | 2011-10-12 14:00:43 | [diff] [blame] | 181 | // Binding directly to GetAllowedPluginForOpenChannelToPlugin() isn't possible |
| 182 | // because more arity is needed <http://crbug.com/98542>. This just forwards. |
| 183 | void ForwardGetAllowedPluginForOpenChannelToPlugin( |
[email protected] | 209f2ae | 2012-03-13 01:28:08 | [diff] [blame] | 184 | const PluginServiceFilterParams& params, |
[email protected] | 88ca491 | 2011-10-12 14:00:43 | [diff] [blame] | 185 | const GURL& url, |
| 186 | const std::string& mime_type, |
| 187 | PluginProcessHost::Client* client, |
| 188 | const std::vector<webkit::WebPluginInfo>&); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 189 | // Helper so we can do the plugin lookup on the FILE thread. |
| 190 | void GetAllowedPluginForOpenChannelToPlugin( |
| 191 | int render_process_id, |
| 192 | int render_view_id, |
| 193 | const GURL& url, |
[email protected] | dfba876 | 2011-09-02 12:49:54 | [diff] [blame] | 194 | const GURL& page_url, |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 195 | const std::string& mime_type, |
[email protected] | 87c4be4 | 2011-09-16 01:10:59 | [diff] [blame] | 196 | PluginProcessHost::Client* client, |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 197 | ResourceContext* resource_context); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 198 | |
| 199 | // Helper so we can finish opening the channel after looking up the |
| 200 | // plugin. |
[email protected] | 6be31d20 | 2013-02-01 18:20:54 | [diff] [blame] | 201 | void FinishOpenChannelToPlugin(int render_process_id, |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 202 | const base::FilePath& plugin_path, |
[email protected] | 07b71c8 | 2013-01-08 19:07:31 | [diff] [blame] | 203 | PluginProcessHost::Client* client); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 204 | |
[email protected] | 52348b2 | 2012-11-07 10:19:34 | [diff] [blame] | 205 | #if defined(OS_POSIX) && !defined(OS_OPENBSD) && !defined(OS_ANDROID) |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 206 | // Registers a new FilePathWatcher for a given path. |
[email protected] | 6665571f | 2013-01-15 07:59:52 | [diff] [blame] | 207 | static void RegisterFilePathWatcher(base::FilePathWatcher* watcher, |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 208 | const base::FilePath& path); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 209 | #endif |
| 210 | |
[email protected] | ee06617 | 2011-11-10 23:20:05 | [diff] [blame] | 211 | // The plugin list instance. |
| 212 | webkit::npapi::PluginList* plugin_list_; |
| 213 | |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 214 | #if defined(OS_WIN) |
| 215 | // Registry keys for getting notifications when new plugins are installed. |
| 216 | base::win::RegKey hkcu_key_; |
| 217 | base::win::RegKey hklm_key_; |
| 218 | scoped_ptr<base::WaitableEvent> hkcu_event_; |
| 219 | scoped_ptr<base::WaitableEvent> hklm_event_; |
| 220 | base::WaitableEventWatcher hkcu_watcher_; |
| 221 | base::WaitableEventWatcher hklm_watcher_; |
| 222 | #endif |
| 223 | |
[email protected] | 52348b2 | 2012-11-07 10:19:34 | [diff] [blame] | 224 | #if defined(OS_POSIX) && !defined(OS_OPENBSD) && !defined(OS_ANDROID) |
[email protected] | 6665571f | 2013-01-15 07:59:52 | [diff] [blame] | 225 | ScopedVector<base::FilePathWatcher> file_watchers_; |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 226 | #endif |
| 227 | |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 228 | std::vector<PepperPluginInfo> ppapi_plugins_; |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 229 | |
[email protected] | dfba876 | 2011-09-02 12:49:54 | [diff] [blame] | 230 | // Weak pointer; outlives us. |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 231 | PluginServiceFilter* filter_; |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 232 | |
[email protected] | 4befe759 | 2011-09-14 22:49:09 | [diff] [blame] | 233 | std::set<PluginProcessHost::Client*> pending_plugin_clients_; |
| 234 | |
[email protected] | a33fa9d | 2012-05-16 14:47:49 | [diff] [blame] | 235 | // Used to sequentialize loading plug-ins from disk. |
| 236 | base::SequencedWorkerPool::SequenceToken plugin_list_token_; |
[email protected] | 1b51720 | 2012-12-19 17:16:10 | [diff] [blame] | 237 | |
[email protected] | d4af1e7 | 2011-10-21 17:45:43 | [diff] [blame] | 238 | #if defined(OS_POSIX) |
| 239 | scoped_refptr<PluginLoaderPosix> plugin_loader_; |
| 240 | #endif |
| 241 | |
[email protected] | 47214d88 | 2012-02-29 06:28:48 | [diff] [blame] | 242 | // Used to detect if a given plug-in is crashing over and over. |
[email protected] | 2dec8ec | 2013-02-07 19:20:34 | [diff] [blame] | 243 | std::map<base::FilePath, std::vector<base::Time> > crash_times_; |
[email protected] | 47214d88 | 2012-02-29 06:28:48 | [diff] [blame] | 244 | |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 245 | DISALLOW_COPY_AND_ASSIGN(PluginServiceImpl); |
[email protected] | a042173 | 2011-02-23 03:55:40 | [diff] [blame] | 246 | }; |
| 247 | |
[email protected] | 13075767 | 2012-10-24 00:26:19 | [diff] [blame] | 248 | } // namespace content |
| 249 | |
[email protected] | e67385f | 2011-12-21 06:00:56 | [diff] [blame] | 250 | #endif // CONTENT_BROWSER_PLUGIN_SERVICE_IMPL_H_ |