mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-05 03:24:56 +08:00
engine: pass customization file fragments into IsSafeFileToDownload
This function already validates customization filenames.
This commit is contained in:
@@ -1244,7 +1244,7 @@ qboolean Netchan_CopyFileFragments( netchan_t *chan, sizebuf_t *msg )
|
|||||||
Netchan_FlushIncoming( chan, FRAG_FILE_STREAM );
|
Netchan_FlushIncoming( chan, FRAG_FILE_STREAM );
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else if( filename[0] != '!' && ( COM_CheckNastyPath( filename ) || !COM_IsSafeFileToDownload( filename )))
|
else if( COM_CheckNastyPath( filename ) || !COM_IsSafeFileToDownload( filename ))
|
||||||
{
|
{
|
||||||
Con_Printf( S_ERROR "file fragment received with bad path, ignoring\n" );
|
Con_Printf( S_ERROR "file fragment received with bad path, ignoring\n" );
|
||||||
Netchan_FlushIncoming( chan, FRAG_FILE_STREAM );
|
Netchan_FlushIncoming( chan, FRAG_FILE_STREAM );
|
||||||
|
|||||||
Reference in New Issue
Block a user