Add string length checking to function COM_StripExtension. This fixes the R_RemapShader buffer overflow exploit that can be found here:
http://milw0rm.com/exploits/1750
This commit is contained in:
parent
2e368c02a6
commit
d21411452e
13 changed files with 22 additions and 22 deletions
|
@ -2066,7 +2066,7 @@ void CL_Frame ( int msec ) {
|
|||
}
|
||||
|
||||
Q_strncpyz( mapName, COM_SkipPath( cl.mapname ), sizeof( cl.mapname ) );
|
||||
COM_StripExtension( mapName, mapName );
|
||||
COM_StripExtension(mapName, mapName, sizeof(mapName));
|
||||
|
||||
Cbuf_ExecuteText( EXEC_NOW,
|
||||
va( "record %s-%s-%s", nowString, serverName, mapName ) );
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue