Information Assurance |
Clare M. Schramm |
Information AssuranceBugtraq AnalysisVulnerability on a Temporary Folder Creation in Avast! Linux Home Edition Product Link |
Avast! is an anti-virus software program for the UNIX system. This
vulnerability is of particular interest because any anti-virus
software is supposed to prevent viruses, not make it easier for
someone to access your computer! The vulnerability occurs when the program scans for a virus. A temporary directory called /tmp is created in an insecure manner because it is assigned a chmod of 1777, which allows all users to read, write, and execute the file. This can create an entryway for local users to gain escalated privileges. Alternatively, the local users can use the escalated privileges to cause a Denial of Service, which is very annoying for the root user. In order to exploit this vulnerability, a malicious user (who must be locally logged- in to the system) must create a sym link from /etc/passwd to /tmp/_avast4_ Here is a sample of how this is done:
$ ls -l /etc/passwd Basically, this vulnerability is due to missing INPUT VALIDATION in the device driver. Thus, someone can overwrite arbitrary memory via signals with specially- created input! Hence why it is SO important to CHECK YOUR INPUT!!! How should Avast! fix this critical vulnerability? The user can begin by not being connected to a local network so nobody could run the risk of gaining root privilege. But this is not always possible. Until a patch is developed which CHECKS FOR SYM LINKS or gives the file a MORE SECURE CHMOD, there's basically no protection for the user. However, this is an extremely difficult vulnerability for someone to take advantage of, considering as the "_avast4_" folder is not erased when the virus scan is finished. Also, the malicious user must act within a short period of time, because this distribution of software usually cleans the /tmp folder with the tmpwatch utility, which gets rid of all files older than a certain age. MORAL OF THE STORY: PEOPLE ARE EVIL--BEWARE OF SYM LINKS!!! And always check for them when opening files to make your code secure!
|