GuestControlSvc.h revision 9d4498106267e3834edc3a37bca5ca660153525c
4865N/A * Guest control service - Common header for host service and guest clients. 4865N/A * Copyright (C) 2010 Oracle Corporation 4865N/A * This file is part of VirtualBox Open Source Edition (OSE), as 4865N/A * you can redistribute it and/or modify it under the terms of the GNU 4865N/A * General Public License (GPL) as published by the Free Software 4865N/A * Foundation, in version 2 as it comes in the "COPYING" file of the 4865N/A * VirtualBox OSE distribution. VirtualBox OSE is distributed in the 4865N/A * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind. 4865N/A * The contents of this file may alternatively be used under the terms 4865N/A * of the Common Development and Distribution License Version 1.0 4865N/A * (CDDL) only, as it comes in the "COPYING.CDDL" file of the 4865N/A * VirtualBox OSE distribution, in which case the provisions of the 4865N/A * CDDL are applicable instead of those of the GPL. 4865N/A * You may elect to license modified versions of this file under the 4865N/A * terms and conditions of either the GPL or the CDDL or both. 4865N/A/* Everything defined in this file lives in this namespace. */ 4865N/A/****************************************************************************** 4865N/A* Typedefs, constants and inlines * 4865N/A******************************************************************************/ 4865N/A * Process status when executed in the guest. 4865N/A * Note: Has to match Main's ExecuteProcessStatus_*! 4865N/A /** Process is in an undefined state. */ /** Process has been started. */ /** Process terminated normally. */ /** Process terminated via signal. */ /** Process terminated abnormally. */ /** Process timed out and was killed. */ /** Process timed out and was not killed successfully. */ /** Service/OS is stopping, process was killed. */ /** Something went wrong (error code in flags). */ * Input flags, set by the host. This is needed for * handling flags on the guest side. * Note: Has to match Main's ProcessInputFlag_* flags! * Pipe handle IDs used internally for referencing to /** @name Internal tools built into VBoxService which are used in order to * accomplish tasks host<->guest. * Input status, reported by the client. /** Input is in an undefined state. */ /** Input was written (partially, see cbProcessed). */ /** Input failed with an error (see flags for rc). */ /** Process has abandoned / terminated input handling. */ /** Too much input data. */ * The guest control callback data header. Must come first * on each callback structure defined below this struct. /** Magic number to identify the structure. */ /** Context ID to identify callback data. */ /** Callback data header. */ * Data structure to pass to the service extension callback. We use this to * notify the host of changes to properties. /** Callback data header. */ /** The process ID (PID). */ /** The process status. */ /** Optional flags, varies, based on u32Status. */ /** Optional data buffer (not used atm). */ /** Size of optional data buffer (not used atm). */ /** Callback data header. */ /** The process ID (PID). */ /** Optional flags (not used atm). */ /** Optional data buffer. */ /** Size (in bytes) of optional data buffer. */ /** Callback data header. */ /** The process ID (PID). */ /** Current input status. */ /** Size (in bytes) of processed input data. */ /** Callback data header. */ /** The native node id. */ /** Callback data header. */ /** The native node id. */ /** Size (in bytes) of entry name. */ * The service functions which are callable by host. * The host asks the client to cancel all pending waits and exit. * The host wants to execute something in the guest. This can be a command line * Sends input data for stdin to a running process executed by HOST_EXEC_CMD. * Gets the current status of a running process, e.g. * Opens a directory for reading. * Closes a formerly opened directory. * Reads the next entry from an open directory. * The service functions which are called by guest. The numbers may not change, * Guest waits for a new message the host wants to process on the guest side. * This is a blocking call and can be deferred. * Guest asks the host to cancel all pending waits the guest itself waits on. * This becomes necessary when the guest wants to quit but still waits for * commands from the host. * Guest disconnected (terminated normally or due to a crash HGCM * detected when calling service::clientDisconnect(). * Guests sends output from an executed process. * Guest sends a status update of an executed process to the host. * Guests sends an input status notification to the host. * Guest sends back the directory handle. * Guest sends back the next directory entry. * HGCM parameter structures. * The returned command the host wants to /** Number of parameters the message needs. */ * Asks the guest control host service to cancel all pending (outstanding) * waits which were not processed yet. This is handy for a graceful shutdown. * Executes a command inside the guest. /** The command to execute on the guest. */ /** Execution flags (see IGuest::ExecuteProcessFlag_*). */ /** Number of arguments. */ /** The actual arguments. */ /** Number of environment value pairs. */ /** Size (in bytes) of environment block, including terminating zeros. */ /** The actual environment block. */ /** The user name to run the executed command under. */ /** The user's password. */ /** Timeout (in msec) which either specifies the * overall lifetime of the process or how long it * can take to bring the process up and running - * (depends on the IGuest::ExecuteProcessFlag_*). */ * Injects input to a previously executed process via stdin. /** The process ID (PID) to send the input to. */ /** Input flags (see IGuest::ProcessInputFlag_*). */ /** Actual size of data (in bytes). */ * Retrieves ouptut from a previously executed process /** The process ID (PID). */ * Reports the current status of a (just) started /** The process ID (PID). */ /** The process status. */ /** Optional flags (based on status). */ /** Optional data buffer (not used atm). */ * Reports back the status of data written to a process. /** The process ID (PID). */ /** Status of the operation. */ * Closes a formerly openend guest directory. /** Directory handle to close. */ * Opens a guest directory for reading. /** Directory (path) to open. */ /** Filter (DOS style wildcard). */ /** The user name to run the executed command under. */ /** The user's password. */ /** OUT: Handle for opened directory. */ * Reads next entry of an open guest directory. /** Directory handle to read from. */ * Structure for buffering execution requests in the host service. }
/* namespace guestControl */#
endif /* !___VBox_HostService_GuestControlService_h */