VirtualBox

Changeset 38630 in vbox


Ignore:
Timestamp:
Sep 5, 2011 10:52:26 AM (14 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
73837
Message:

DrvIntNet: Check the RequireExactPolicyMatch and RequireAsRestrictivePolicy config options.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Network/DrvIntNet.cpp

    r38549 r38630  
    14551455                                N_("Configuration error: Failed to get the \"RestrictAccess\" value"));
    14561456
     1457    /** @cfgm{RequireExactPolicyMatch, boolean, false}
     1458     * Whether to require that the current security and promiscuous policies of
     1459     * the network is exactly as the ones specified in this open network
     1460     * request.  Use this with RequireAsRestrictivePolicy to prevent
     1461     * restrictions from being lifted.  If no further policy changes are
     1462     * desired, apply the relevant fixed flags. */
     1463    rc = CFGMR3QueryBoolDef(pCfg, "RequireExactPolicyMatch", &f, false);
     1464    if (RT_FAILURE(rc))
     1465        return PDMDRV_SET_ERROR(pDrvIns, rc,
     1466                                N_("Configuration error: Failed to get the \"RequireExactPolicyMatch\" value"));
     1467    if (f)
     1468        OpenReq.fFlags |= INTNET_OPEN_FLAGS_REQUIRE_EXACT;
     1469
     1470    /** @cfgm{RequireAsRestrictivePolicy, boolean, false}
     1471     * Whether to require that the security and promiscuous policies of the
     1472     * network is at least as restrictive as specified this request specifies
     1473     * and prevent them  being lifted later on.
     1474     */
     1475    rc = CFGMR3QueryBoolDef(pCfg, "RequireAsRestrictivePolicy", &f, false);
     1476    if (RT_FAILURE(rc))
     1477        return PDMDRV_SET_ERROR(pDrvIns, rc,
     1478                                N_("Configuration error: Failed to get the \"RequireAsRestrictivePolicy\" value"));
     1479    if (f)
     1480        OpenReq.fFlags |= INTNET_OPEN_FLAGS_REQUIRE_AS_RESTRICTIVE_POLICIES;
    14571481
    14581482    /** @cfgm{AccessPolicy, string, "none"}
Note: See TracChangeset for help on using the changeset viewer.

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