VirtualBox

Changeset 98813 in vbox for trunk/src/VBox/Additions/common


Ignore:
Timestamp:
Mar 2, 2023 12:20:41 PM (21 months ago)
Author:
vboxsync
Message:

Guest Control: Removed the ACL data portion from the HGCM callback messages (as ACLs are not implemented yet). bugref:9783

Location:
trunk/src/VBox/Additions/common
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/common/VBoxGuest/lib/VBoxGuestR3LibGuestCtrl.cpp

    r98804 r98813  
    22812281 * @param   pszGroups           Associated user groups as a string.
    22822282 *                              Multiple groups are delimited by "\r\n", whereas the first group always is the primary group.
    2283  * @param   pvACL               ACL block to send.
    2284  * @param   cbACL               Size (in bytes) of ACL block to send.
    22852283 */
    22862284VBGLR3DECL(int) VbglR3GuestCtrlDirCbReadEx(PVBGLR3GUESTCTRLCMDCTX pCtx, uint32_t uRc, PGSTCTLDIRENTRYEX pEntry, uint32_t cbSize,
    2287                                            char *pszUser, char *pszGroups, void *pvACL, size_t cbACL)
     2285                                           char *pszUser, char *pszGroups)
    22882286{
    22892287    AssertPtrReturn(pCtx, VERR_INVALID_POINTER);
    22902288    AssertPtrReturn(pszUser, VERR_INVALID_POINTER);
    22912289    AssertPtrReturn(pszGroups, VERR_INVALID_POINTER);
    2292     AssertPtrReturn(pvACL, VERR_INVALID_POINTER);
    2293     AssertReturn(cbACL, VERR_INVALID_PARAMETER);
    22942290
    22952291    HGCMReplyDirNotify Msg;
    2296     VBGL_HGCM_HDR_INIT(&Msg.reply_hdr.hdr, pCtx->uClientID, GUEST_MSG_DIR_NOTIFY, GSTCTL_HGCM_REPLY_HDR_PARMS + 4);
     2292    VBGL_HGCM_HDR_INIT(&Msg.reply_hdr.hdr, pCtx->uClientID, GUEST_MSG_DIR_NOTIFY, GSTCTL_HGCM_REPLY_HDR_PARMS + 3);
    22972293    VbglHGCMParmUInt32Set(&Msg.reply_hdr.context, pCtx->uContextID);
    22982294    VbglHGCMParmUInt32Set(&Msg.reply_hdr.type, GUEST_DIR_NOTIFYTYPE_READ);
     
    23022298    VbglHGCMParmPtrSetString(&Msg.u.read.user,    pszUser);
    23032299    VbglHGCMParmPtrSetString(&Msg.u.read.groups,  pszGroups);
    2304     VbglHGCMParmPtrSet      (&Msg.u.read.acl,     pvACL, (uint32_t)cbACL);
    23052300
    23062301    return VbglR3HGCMCall(&Msg.reply_hdr.hdr, RT_UOFFSET_AFTER(HGCMReplyDirNotify, u.read));
     
    23222317{
    23232318    char szIgnored[1] = { 0 };
    2324     return VbglR3GuestCtrlDirCbReadEx(pCtx, uRc, pEntry, cbSize, szIgnored /* pszUser */, szIgnored /* pszGroups */,
    2325                                       szIgnored /* pvACL */, sizeof(szIgnored) /* cbACL */);
     2319    return VbglR3GuestCtrlDirCbReadEx(pCtx, uRc, pEntry, cbSize, szIgnored /* pszUser */, szIgnored /* pszGroups */);
    23262320}
    23272321
     
    26052599 * @param   pszGroups           Associated user groups as a string.
    26062600 *                              Multiple groups are delimited by "\r\n", whereas the first group always is the primary group.
    2607  * @param   pvACL               ACL block to send.
    2608  * @param   cbACL               Size (in bytes) of ACL block to send.
    26092601 */
    26102602VBGLR3DECL(int) VbglR3GuestCtrlFsCbQueryInfoEx(PVBGLR3GUESTCTRLCMDCTX pCtx, uint32_t uRc, PGSTCTLFSOBJINFO pFsObjInfo,
    2611                                                char *pszUser, char *pszGroups, void *pvACL, uint32_t cbACL)
     2603                                               char *pszUser, char *pszGroups)
    26122604{
    26132605    AssertPtrReturn(pCtx, VERR_INVALID_POINTER);
     
    26152607    AssertPtrReturn(pszUser, VERR_INVALID_POINTER);
    26162608    AssertPtrReturn(pszGroups, VERR_INVALID_POINTER);
    2617     AssertPtrReturn(pvACL, VERR_INVALID_POINTER);
    2618     AssertReturn(cbACL, VERR_INVALID_PARAMETER);
    26192609
    26202610    HGCMReplyFsNotify Msg;
    2621     VBGL_HGCM_HDR_INIT(&Msg.reply_hdr.hdr, pCtx->uClientID, GUEST_MSG_FS_NOTIFY, 7);
     2611    VBGL_HGCM_HDR_INIT(&Msg.reply_hdr.hdr, pCtx->uClientID, GUEST_MSG_FS_NOTIFY, GSTCTL_HGCM_REPLY_HDR_PARMS + 3);
    26222612    VbglHGCMParmUInt32Set(&Msg.reply_hdr.context, pCtx->uContextID);
    26232613    VbglHGCMParmUInt32Set(&Msg.reply_hdr.type, GUEST_FS_NOTIFYTYPE_QUERY_INFO);
    26242614    VbglHGCMParmUInt32Set(&Msg.reply_hdr.rc, uRc);
     2615
    26252616    VbglHGCMParmPtrSet      (&Msg.u.queryinfo.obj_info, pFsObjInfo, sizeof(GSTCTLFSOBJINFO));
    26262617    VbglHGCMParmPtrSetString(&Msg.u.queryinfo.user,   pszUser);
    26272618    VbglHGCMParmPtrSetString(&Msg.u.queryinfo.groups, pszGroups);
    2628     VbglHGCMParmPtrSet      (&Msg.u.queryinfo.acl,    pvACL, cbACL);
    26292619
    26302620    return VbglR3HGCMCall(&Msg.reply_hdr.hdr, RT_UOFFSET_AFTER(HGCMReplyFsNotify, u.queryinfo));
     
    26432633{
    26442634    char szIgnored[1];
    2645     return VbglR3GuestCtrlFsCbQueryInfoEx(pCtx, uRc, pFsObjInfo, szIgnored /* pszUser */, szIgnored /* pszGroups */,
    2646                                           szIgnored /* pvACL */, sizeof(szIgnored) /* cbACL */);
     2635    return VbglR3GuestCtrlFsCbQueryInfoEx(pCtx, uRc, pFsObjInfo, szIgnored /* pszUser */, szIgnored /* pszGroups */);
    26472636}
    26482637
     
    26632652
    26642653    HGCMReplyFsNotify Msg;
    2665     VBGL_HGCM_HDR_INIT(&Msg.reply_hdr.hdr, pCtx->uClientID, GUEST_MSG_FS_NOTIFY, 4);
     2654    VBGL_HGCM_HDR_INIT(&Msg.reply_hdr.hdr, pCtx->uClientID, GUEST_MSG_FS_NOTIFY, GSTCTL_HGCM_REPLY_HDR_PARMS + 1);
    26662655    VbglHGCMParmUInt32Set(&Msg.reply_hdr.context, pCtx->uContextID);
    26672656    VbglHGCMParmUInt32Set(&Msg.reply_hdr.type, GUEST_FS_NOTIFYTYPE_CREATE_TEMP);
    26682657    VbglHGCMParmUInt32Set(&Msg.reply_hdr.rc, uRc);
     2658
    26692659    VbglHGCMParmPtrSetString(&Msg.u.createtemp.path, pszPath);
    26702660
  • trunk/src/VBox/Additions/common/VBoxService/VBoxServiceControlSession.cpp

    r98791 r98813  
    11851185                         pszGroup ? pszGroup : "", DirEntryEx.Info.Attr.u.UnixGroup.gid);
    11861186
    1187             char szIgnored[] = "???"; /** @todo Implement ACL support. */
     1187            char szIgnored[] = "???";
    11881188            int rc2 = VbglR3GuestCtrlDirCbReadEx(pHostCtx, rc,
    11891189                                                 &DirEntryEx, (uint32_t)(sizeof(GSTCTLDIRENTRYEX) + cbDirEntry),
    1190                                                  pszUser ? pszUser : szIgnored, pszGroup ? pszGroup : szIgnored,
    1191                                                  szIgnored /* pvACL */, sizeof(szIgnored) /* cbACL */);
     1190                                                 pszUser ? pszUser : szIgnored, pszGroup ? pszGroup : szIgnored);
    11921191            RTStrFree(pszUser);
    11931192            RTStrFree(pszGroup);
     
    18701869        AssertStmt(pszGroup != NULL, rc = VERR_NO_MEMORY);
    18711870
    1872         char  szNotImplemented[] = "<not-implemented>"; /** @todo Implement ACL support. */
    1873         int rc2 = VbglR3GuestCtrlFsCbQueryInfoEx(pHostCtx, rc, pObjInfo, pszUser, pszGroup,
    1874                                                  szNotImplemented, sizeof(szNotImplemented));
     1871        int rc2 = VbglR3GuestCtrlFsCbQueryInfoEx(pHostCtx, rc, pObjInfo, pszUser, pszGroup);
    18751872        RTStrFree(pszUser);
    18761873        RTStrFree(pszGroup);
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