VirtualBox

Changeset 50247 in vbox


Ignore:
Timestamp:
Jan 27, 2014 4:22:59 PM (11 years ago)
Author:
vboxsync
Message:

VBoxLogRelCreate: avoid uncontrolled format string attack. This
function takes pcszLogFile argument that appears to be intended as the
literal file name. Don't pass it as pszFilenameFmt format string to
RTLogCreateEx(). Instead format it with "%s".

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/glue/com.cpp

    r48654 r50247  
    379379                            pcszEnvVarBase, RT_ELEMENTS(s_apszGroups), s_apszGroups, fDestFlags,
    380380                            vboxHeaderFooter, cHistory, uHistoryFileSize, uHistoryFileTime,
    381                             pszError, cbError, pcszLogFile);
     381                            pszError, cbError,
     382                            "%s", pcszLogFile);
    382383    if (RT_SUCCESS(vrc))
    383384    {
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