GNU screen contains a global buffer overflow vulnerability in the SendCmdMessage() function due to an unchecked sprintf() call involving the STY environment variable. This flaw can be triggered when the HOME and STY environment variables are attacker-controlled and sufficiently long. Exploitation may cause application crashes or potentially arbitrary code execution. The issue was fixed in version 5.0.2.