CVE-2026-74899: Os System Clear Screen

Using 'os.system("clear")' or 'os.system("cls")' invokes a shell to clear the terminal screen, which is vulnerable to PATH hijacking and unnecessary subprocess overhead. Use ANSI escape sequences (e.g., sys.stdout.write('\033[2J\033[H')) instead.

Provally CuratedPublic repositoryMediumHigh confidenceVerifiedApache-2.0Python
greprules fetch cve-2026-74899-os-system-clear-screen --engine opengrep

Description

Using 'os.system("clear")' or 'os.system("cls")' invokes a shell to clear the terminal screen, which is vulnerable to PATH hijacking and unnecessary subprocess overhead. Use ANSI escape sequences (e.g., sys.stdout.write('\033[2J\033[H')) instead.