VirtualBox

Changeset 34558 in vbox for trunk/include/VBox/VRDPAuth.h


Ignore:
Timestamp:
Dec 1, 2010 10:56:44 AM (14 years ago)
Author:
vboxsync
Message:

Updated VBox authentication library interface, removed references to VRDP.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/VRDPAuth.h

    r28800 r34558  
    11/** @file
    2  * VBox Remote Desktop Protocol - External Authentication Library Interface.
    3  * (VRDP)
     2 * VirtualBox External Authentication Library Interface.
    43 */
    54
    65/*
    7  * Copyright (C) 2006-2007 Oracle Corporation
     6 * Copyright (C) 2006-2010 Oracle Corporation
    87 *
    98 * This file is part of VirtualBox Open Source Edition (OSE), as
     
    2928
    3029/* The following 2 enums are 32 bits values.*/
    31 typedef enum _VRDPAuthResult
     30typedef enum AuthResult
    3231{
    33     VRDPAuthAccessDenied    = 0,
    34     VRDPAuthAccessGranted   = 1,
    35     VRDPAuthDelegateToGuest = 2,
    36     VRDPAuthSizeHack        = 0x7fffffff
    37 } VRDPAuthResult;
     32    AuthResultAccessDenied    = 0,
     33    AuthResultAccessGranted   = 1,
     34    AuthResultDelegateToGuest = 2,
     35    AuthResultSizeHack        = 0x7fffffff
     36} AuthResult;
    3837
    39 typedef enum _VRDPAuthGuestJudgement
     38typedef enum AuthGuestJudgement
    4039{
    41     VRDPAuthGuestNotAsked      = 0,
    42     VRDPAuthGuestAccessDenied  = 1,
    43     VRDPAuthGuestNoJudgement   = 2,
    44     VRDPAuthGuestAccessGranted = 3,
    45     VRDPAuthGuestNotReacted    = 4,
    46     VRDPAuthGuestSizeHack      = 0x7fffffff
    47 } VRDPAuthGuestJudgement;
     40    AuthGuestNotAsked      = 0,
     41    AuthGuestAccessDenied  = 1,
     42    AuthGuestNoJudgement   = 2,
     43    AuthGuestAccessGranted = 3,
     44    AuthGuestNotReacted    = 4,
     45    AuthGuestSizeHack      = 0x7fffffff
     46} AuthGuestJudgement;
    4847
    4948/* UUID memory representation. Array of 16 bytes. */
    50 typedef unsigned char VRDPAUTHUUID[16];
    51 typedef VRDPAUTHUUID *PVRDPAUTHUUID;
     49typedef unsigned char AUTHUUID[16];
     50typedef AUTHUUID *PAUTHUUID;
    5251/*
    5352Note: VirtualBox uses a consistent binary representation of UUIDs on all platforms. For this reason
     
    6564/* The library entry point calling convention. */
    6665#ifdef _MSC_VER
    67 # define VRDPAUTHCALL __cdecl
     66# define AUTHCALL __cdecl
    6867#elif defined(__GNUC__)
    69 # define VRDPAUTHCALL
     68# define AUTHCALL
    7069#else
    7170# error "Unsupported compiler"
     
    7473
    7574/**
    76  * Authentication library entry point. Decides whether to allow
    77  * a client connection.
     75 * Authentication library entry point.
    7876 *
    7977 * Parameters:
    8078 *
    81  *   pUuid            Pointer to the UUID of the virtual machine
    82  *                    which the client connected to.
     79 *   pUuid            Pointer to the UUID of the accessed virtual machine. Can be NULL.
    8380 *   guestJudgement   Result of the guest authentication.
    8481 *   szUser           User name passed in by the client (UTF8).
     
    8885 * Return code:
    8986 *
    90  *   VRDPAuthAccessDenied    Client access has been denied.
    91  *   VRDPAuthAccessGranted   Client has the right to use the
    92  *                           virtual machine.
    93  *   VRDPAuthDelegateToGuest Guest operating system must
    94  *                           authenticate the client and the
    95  *                           library must be called again with
    96  *                           the result of the guest
    97  *                           authentication.
     87 *   AuthAccessDenied    Client access has been denied.
     88 *   AuthAccessGranted   Client has the right to use the
     89 *                       virtual machine.
     90 *   AuthDelegateToGuest Guest operating system must
     91 *                       authenticate the client and the
     92 *                       library must be called again with
     93 *                       the result of the guest
     94 *                       authentication.
    9895 */
    99 typedef VRDPAuthResult VRDPAUTHCALL VRDPAUTHENTRY(PVRDPAUTHUUID pUuid,
    100                                                   VRDPAuthGuestJudgement guestJudgement,
    101                                                   const char *szUser,
    102                                                   const char *szPassword,
    103                                                   const char *szDomain);
     96typedef AuthResult AUTHCALL AUTHENTRY(PAUTHUUID pUuid,
     97                                      AuthGuestJudgement guestJudgement,
     98                                      const char *szUser,
     99                                      const char *szPassword,
     100                                      const char *szDomain);
    104101
    105102
    106 typedef VRDPAUTHENTRY *PVRDPAUTHENTRY;
     103typedef AUTHENTRY *PAUTHENTRY;
     104
     105#define AUTHENTRY_NAME "VRDPAuth"
    107106
    108107/**
    109  * Authentication library entry point version 2. Decides whether to allow
    110  * a client connection.
     108 * Authentication library entry point version 2.
    111109 *
    112110 * Parameters:
    113111 *
    114  *   pUuid            Pointer to the UUID of the virtual machine
    115  *                    which the client connected to.
     112 *   pUuid            Pointer to the UUID of the accessed virtual machine. Can be NULL.
    116113 *   guestJudgement   Result of the guest authentication.
    117114 *   szUser           User name passed in by the client (UTF8).
     
    124121 * Return code:
    125122 *
    126  *   VRDPAuthAccessDenied    Client access has been denied.
    127  *   VRDPAuthAccessGranted   Client has the right to use the
    128  *                           virtual machine.
    129  *   VRDPAuthDelegateToGuest Guest operating system must
    130  *                           authenticate the client and the
    131  *                           library must be called again with
    132  *                           the result of the guest
    133  *                           authentication.
     123 *   AuthAccessDenied    Client access has been denied.
     124 *   AuthAccessGranted   Client has the right to use the
     125 *                       virtual machine.
     126 *   AuthDelegateToGuest Guest operating system must
     127 *                       authenticate the client and the
     128 *                       library must be called again with
     129 *                       the result of the guest
     130 *                       authentication.
    134131 *
    135132 * Note: When 'fLogon' is 0, only pUuid and clientId are valid and the return
    136133 *       code is ignored.
    137134 */
    138 typedef VRDPAuthResult VRDPAUTHCALL VRDPAUTHENTRY2(PVRDPAUTHUUID pUuid,
    139                                                    VRDPAuthGuestJudgement guestJudgement,
    140                                                    const char *szUser,
    141                                                    const char *szPassword,
    142                                                    const char *szDomain,
    143                                                    int fLogon,
    144                                                    unsigned clientId);
     135typedef AuthResult AUTHCALL AUTHENTRY2(PAUTHUUID pUuid,
     136                                       AuthGuestJudgement guestJudgement,
     137                                       const char *szUser,
     138                                       const char *szPassword,
     139                                       const char *szDomain,
     140                                       int fLogon,
     141                                       unsigned clientId);
    145142
    146143
    147 typedef VRDPAUTHENTRY2 *PVRDPAUTHENTRY2;
     144typedef AUTHENTRY2 *PAUTHENTRY2;
     145
     146#define AUTHENTRY2_NAME "VRDPAuth2"
     147
     148/**
     149 * Authentication library entry point version 3.
     150 *
     151 * Parameters:
     152 *
     153 *   szCaller         The name of the component which calls the library (UTF8).
     154 *   pUuid            Pointer to the UUID of the accessed virtual machine. Can be NULL.
     155 *   guestJudgement   Result of the guest authentication.
     156 *   szUser           User name passed in by the client (UTF8).
     157 *   szPassword       Password passed in by the client (UTF8).
     158 *   szDomain         Domain passed in by the client (UTF8).
     159 *   fLogon           Boolean flag. Indicates whether the entry point is called
     160 *                    for a client logon or the client disconnect.
     161 *   clientId         Server side unique identifier of the client.
     162 *
     163 * Return code:
     164 *
     165 *   AuthAccessDenied    Client access has been denied.
     166 *   AuthAccessGranted   Client has the right to use the
     167 *                       virtual machine.
     168 *   AuthDelegateToGuest Guest operating system must
     169 *                       authenticate the client and the
     170 *                       library must be called again with
     171 *                       the result of the guest
     172 *                       authentication.
     173 *
     174 * Note: When 'fLogon' is 0, only pszCaller, pUuid and clientId are valid and the return
     175 *       code is ignored.
     176 */
     177typedef AuthResult AUTHCALL AUTHENTRY3(const char *szCaller,
     178                                       PAUTHUUID pUuid,
     179                                       AuthGuestJudgement guestJudgement,
     180                                       const char *szUser,
     181                                       const char *szPassword,
     182                                       const char *szDomain,
     183                                       int fLogon,
     184                                       unsigned clientId);
     185
     186
     187typedef AUTHENTRY3 *PAUTHENTRY3;
     188
     189#define AUTHENTRY3_NAME "AuthEntry"
    148190
    149191#endif
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette