You may think to yourself:
"Oh, since I'm a Mac user, I don't get viruses. Not like stupid and crappy Windows users, HAHAHAHAHAHAROFL"
Well, you're wrong. Very wrong.
Viruses are on Macs, and you probably aren't even realizing it because you were too stupid to realize it.
Here's an example, along with thorough explanations:
Trojan-Dropper:OSX/Revir.D and
Backdoor:OSX/Imuler.B (they are both linked, Revir may include other malware due to it being a application package)
Technical Details
Trojan-Dropper:OSX/Revir.D is distributed as an application bundled, comprising the following components:
- The main binary - detected as Trojan-Dropper:OSX/Revir.D
- .conft - Contains an encrypted payload
- .confr - contains a decoy file. The first 2048 bytes are also used as the RC4 key to decrypt the payload
- .cnf - contains the filename to be used when creating the decoy file
Payload
Upon execution, the malware drops and executes its payload as the following:
In the samples brown townyzed, the payload contained another malware detected as Backdoor:OSX/Imuler.B; however, since Revir.D is an application bundle, other malware may be used in other samples.
Social Engineering
To distract the user from noticing its malicious activities, Revir.D drops a copy of the decoy file into the /tmp folder and opens it using the 'open' command. This command directs the OS X system to use the default application to handle the target file's filetype for this action. Unlike previous Revir variants, the decoy file is not limited to PDF (see Revir.A) or JPEG (see Revir.B).
For extra insurance, Revir.D drops another copy of the decoy file into the folder where the malware was executed, and then deletes itself. Presumably, this is done so that if users ever attempts to find the application they just executed, they would only find the decoy file instead.
Both copies of the decoy file use the filename specified in the .cnf component. If the .cnf component does not exist, the decoy files will use the default filename "TMPAAABBB."
Installation
Upon execution, the backdoor drops a copy of itself to the following location:
- ~/library/LaunchAgents/ScheduledSync
It creates the following launch point:
- ~/library/LaunchAgents/ScheduledSync.plist
It also creates the following file, containing its Command and Control, or C&C, server:
Network Connections
The malware obtains the external IP address and current time by connecting to the following URLs:
It collects system information, then uploads the collected information to the following location:
Collected information includes the following:
- Internal IP
- External IP
- Username of the infected user
- Time of last execution
- Kernel version of the infected host
The malware then makes a HTTP POST containing the%botid% to the following URL, presumably to associate the bot to the previous session:
The malware then checks if there is a Wireshark process that is running. It will skip the rest of its routine if found. Otherwise, it makes another HTTP POST containing the%botid% to the following URL, presumably to report that the infected host is ready to receive commands:
Note: In the brown townyzed sample,%server% was [revoked for the safety of others]
Backdoor
The malware contacts a remote server (the C&C server) to get its instructions. The URL is based on the following formula:
Where:
- %botid% - Is composed of:%user%%pad%%mac%
- %user% - Are the first 8 characters of the username of the infected user ("XXXXXXXX" if username is longer than 8 characters)
- %pad% - Is a series of "X" characters to make %botid% 20 characters long
- %mac% - Is the MAC address of the machine
Depending on the instructions received, the backdoor is capable of performing the following actions:
- Download additional files
- Execute files on the infected host
- Collect system information then upload to the C&C
- Collect files to an archive, then upload it to the C&C server
- Capture an image of the computer screen, then upload it to the C&C
After receiving the commands, the malware makes a HTTP HEAD request the to following URL, presumably to report that the infected host has successfully receive the commands:
Please, don't act like a idiot and not take this seriously. Viruses exist on most of technology, you're just going to have to learn to deal with it and get protection. Because if you don't, you're probably going to lose your data, get things stolen and just have your computer destroyed.