VirtualBox

Changeset 95592 in vbox for trunk/src/VBox/Devices/Network


Ignore:
Timestamp:
Jul 11, 2022 10:32:41 PM (3 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
152228
Message:

PDM/network, Network/virtio: Add sanity checking. bugref:10240

File:
1 edited

Legend:

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

    r94976 r95592  
    16951695    pGso->cbHdrsTotal = pPktHdr->uHdrLen;
    16961696    pGso->cbMaxSeg    = pPktHdr->uGsoSize;
     1697    /* Mark GSO frames with zero MSS as PDMNETWORKGSOTYPE_INVALID, so they will be ignored by send. */
     1698    if (pPktHdr->uGsoType != VIRTIONET_HDR_GSO_NONE && pPktHdr->uGsoSize == 0)
     1699        pGso->u8Type = PDMNETWORKGSOTYPE_INVALID;
    16971700    return pGso;
    16981701}
     
    26162619                pGso->cbHdrsSeg = pPktHdr->uChksumStart;
    26172620                break;
     2621            case PDMNETWORKGSOTYPE_INVALID:
     2622                LogFunc(("%s ignoring invalid GSO frame\n", pThis->szInst));
     2623                return VERR_INVALID_PARAMETER;
    26182624        }
    26192625        /* Update GSO structure embedded into the frame */
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