Newsroom Update

Beginning in May, a special Today at Apple series titled “Made for Business” will offer small business owners and entrepreneurs free opportunities to learn how Apple products and services can support their growth and success. Learn more >

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

Antivirus on OS X Server 10.9

Hi,


There is a big variety of conversations in the net about wheter is necessary to install Antivirus on OS X.One of the best is here http://www.thesafemac.com/mmg-antivirus/

But i can't find anything about antivirus protection on the OS X Server (OS X + Server.app ) from malware.Is there something different in the way OS X manages its built in XProtect?

In OS X XProtect scans only /Downloads directory.Is it the same when it acts as server?

I saw in the Mail server option "scan for viruses".Does it mean that with this option scan is performed only on the messages?

Mac mini server-OTHER, OS X Mavericks (10.9.1)

Posted on Jan 8, 2014 12:49 PM

Reply
8 replies

Jan 8, 2014 3:07 PM in response to jorost

Hi Jorost,


I'd disagree with Linc on third-party malware protection if you serve Windows users. While most malware may not affect the OSX Server and OSX users, PC users connecting to your OSX Server can become infected by comprimised files.


We use Sophos Free Antivirus in our office. It's got a live protection feature as well as schedulable scans, and it covers both PC and Mac Malware. It doesn't take a lot of resources, and it has caught problems in the past steming from PC users. Available at http://www.sophos.com/en-us/products/free-tools/sophos-antivirus-for-mac-home-ed ition.aspx

Jan 8, 2014 3:30 PM in response to Linc Davis

1. This is a comment on what you should and should not do to protect yourself from malicious software ("malware") that circulates on the Internet. It does not apply to software, such as keystroke loggers, that may be installed deliberately by an intruder who has hands-on access to the victim's computer, or who has been able to log in to it remotely. That threat is in a different category, and there's no easy way to defend against it. If you have reason to suspect that you're the target of such an attack, you need expert help.

If you find this comment too long or too technical, read only sections 5, 6, and 10.

OS X now implements three layers of built-in protection specifically against malware, not counting runtime protections such as execute disable, sandboxing, system library randomization, and address space layout randomization that may also guard against other kinds of exploits.

2. All versions of OS X since 10.6.7 have been able to detect known Mac malware in downloaded files, and to block insecure web plugins. This feature is transparent to the user, but internally Apple calls it "XProtect." The malware recognition database is automatically checked for updates once a day; however, you shouldn't rely on it, because the attackers are always at least a day ahead of the defenders.

The following caveats apply to XProtect:

  • It can be bypassed by some third-party networking software, such as BitTorrent clients and Java applets.
  • It only applies to software downloaded from the network. Software installed from a CD or other media is not checked.
As new versions of OS X are released, it's not clear whether Apple will indefinitely continue to maintain the XProtect database of older versions such as 10.6. The security of obsolete system versions may eventually be degraded. Security updates to the code of obsolete systems will stop being released at some point, and that may leave them open to other kinds of attack besides malware.

3. Starting with OS X 10.7.5, there has been a second layer of built-in malware protection, designated " Gatekeeper" by Apple. By default, applications and Installer packages downloaded from the network will only run if they're digitally signed by a developer with a certificate issued by Apple. Software certified in this way hasn't necessarily been tested by Apple, but you can be reasonably sure that it hasn't been modified by anyone other than the developer. His identity is known to Apple, so he could be held legally responsible if he distributed malware. That may not mean much if the developer lives in a country with a weak legal system (see below.)

Gatekeeper doesn't depend on a database of known malware. It has, however, the same limitations as XProtect, and in addition the following:

  • It can easily be disabled or overridden by the user.
  • A malware attacker could get control of a code-signing certificate under false pretenses, or could simply ignore the consequences of distributing codesigned malware.
  • An App Store developer could find a way to bypass Apple's oversight, or the oversight could fail due to human error.

For the reasons given above, App Store products, and other applications recognized by Gatekeeper as signed, are safer than others, but they can't be considered absolutely safe. "Sandboxed" applications may prompt for access to private data, such as your contacts, or for access to the network. Think before granting that access. Sandboxing security is based on user input. Never click through any request for authorization without thinking.

4. Starting with OS X 10.8.3, a third layer of protection has been added: a "Malware Removal Tool" (MRT). MRT runs automatically in the background when you update the OS. It checks for, and removes, malware that may have evaded the other protections via a Java exploit (see below.) MRT also runs when you install or update the Apple-supplied Java runtime (but not the Oracle runtime.) Like XProtect, MRT is effective against known threats, but not against unknown ones. It notifies you if it finds malware, but otherwise there's no user interface to MRT.


5. The built-in security features of OS X reduce the risk of malware attack, but they're not absolute protection. The first and best line of defense is always going to be your own intelligence. With the possible exception of Java exploits, all known malware circulating on the Internet that affects a fully-updated installation of OS X 10.6 or later takes the form of so-called " Trojan horses," which can only have an effect if the victim is duped into running them. The threat therefore amounts to a battle of wits between you and Internet criminals. If you're smarter than they think you are, you'll win. That means, in practice, that you always stay within a safe harbor of computing practices. How do you know what is safe?
  • Any website that prompts you to install a “codec,” “plug-in,” "player," "extractor," or “certificate” that comes from that same site, or an unknown one, is unsafe.
  • A web operator who tells you that you have a “virus,” or that anything else is wrong with your computer, or that you have won a prize in a contest you never entered, is trying to commit a crime with you as the victim. (Some reputable websites did legitimately warn visitors who were infected with the "DNSChanger" malware. That exception to this rule no longer applies.)
  • Pirated copies or "cracks" of commercial software, no matter where they come from, are unsafe.
  • Software of any kind downloaded from a BitTorrent or from a Usenet binary newsgroup is unsafe.
  • Software that purports to help you do something that's illegal or that infringes copyright, such as saving streamed audio or video for reuse without permission, is unsafe. All YouTube "downloaders," for example, are outside the safe harbor, though not all are malware.
  • Software with a corporate brand, such as Adobe Flash Player, must be downloaded directly from the developer’s website. If it comes from any other source, it's unsafe. For instance, if a web page warns you that Flash is out of date, do not follow an offered link to an update. Go to the Adobe website to download it, if you need it at all.
  • Software attached to email that you didn't request is unsafe, even if it comes (or seems to come) from someone you trust.
  • Software advertised by means of spam is unsafe.
  • Unknown "free" software that a stranger on the Internet is eager for you to download is unsafe.
  • Even signed applications, no matter what the source, should not be trusted if they do something unexpected, such as asking for permission to access your contacts, your location, or the Internet for no obvious reason.
  • "FREE WI-FI !!!" networks in public places are unsafe unless you can verify that the network is not a trap (which you probably can't.) Even then, do not download any software or transmit any private information while connected to such a network, regardless of where it seems to come from or go to.

I don't say that leaving the safe harbor just once will inevitably result in disaster, but making a habit of it will weaken your defenses against malware attack. Doing any of the things alluded to above should make you uncomfortable.

6. Java on the Web ( not to be confused with JavaScript, to which it's not related, despite the similarity of the names) is a weak point in the security of any system. Java is, among other things, a platform for running complex applications in a web page, on the client. That was always a bad idea, and Java's developers have proven themselves incapable of implementing it without also creating a portal for malware to enter. Past Java exploits are the closest thing there has ever been to a Windows-style virus affecting OS X. Merely loading a page with malicious Java content could be harmful.

Fortunately, client-side Java on the Web is obsolete and mostly extinct. Only a few outmoded sites still use it. Try to hasten the process of extinction by avoiding those sites, if you have a choice. Forget about playing games or other non-essential uses of Java.

Java is not included in OS X 10.7 and later. Discrete Java installers are distributed by Apple and by Oracle (the developer of Java.) Don't use either one unless you need it. Most people don't. If Java is installed, disable itnot JavaScript — in your browsers.

Regardless of version, experience has shown that Java on the Web can't be trusted. If you must use a Java applet for a task on a specific site, enable Java only for that site in Safari. Never enable Java for a public website that carries third-party advertising. Use it only on well-known, login-protected, secure websites without ads. In Safari 6 or later, you'll see a lock icon in the address bar with the abbreviation "https" when visiting a secure site.
Stay within the safe harbor, and you’ll be as safe from malware as you can practically be. The rest of this comment concerns what you should not do to protect yourself.

7. Never install any commercial "anti-virus" or "Internet security" products for the Mac, as they all do more harm than good, if they do any good at all. If you need to be able to detect Windows malware in your files, use one of the free security apps in the Mac App Store — nothing else.

Why shouldn't you use commercial "anti-virus" products?
  • To recognize malware, the software depends on a database of known threats, which is always at least a day out of date. New threats are emerging on a daily basis. Research has shown that most successful attacks are "zero-day" — that is, previously unknown. Recognition-based malware scanners do not defend against such attacks.
  • Their design is predicated on the nonexistent threat that malware may be injected at any time, anywhere in the file system. Malware is downloaded from the network; it doesn't materialize from nowhere.
  • In order to meet that nonexistent threat, the software modifies or duplicates low-level functions of the operating system, which is a waste of resources and a common cause of instability, bugs, and poor performance.
  • By modifying the operating system, the software itself may create weaknesses that could be exploited by malware attackers.

8. An anti-malware product from the App Store, such as "ClamXav," has the same drawback as the commercial suites of being always a day behind, but it does not inject code into the operating system. That doesn't mean it's entirely harmless. It may report email messages that have "phishing" links in the body, or Windows malware in attachments, as infected files, and offer to delete or move them. Doing so will corrupt the Mail database. The messages should be deleted from within the Mail application.

An anti-virus app is not needed, and should not be relied upon, for protection against OS X malware. It's useful only for detecting Windows malware, and even for that use it's not completely effective. Windows malware can't harm you directly (unless, of course, you use Windows.) Just don't pass it on to anyone else.

A Windows malware attachment in email is usually easy to recognize. The file name will often be targeted at people who aren't very bright; for example:

♥♥♥♥♥♥♥♥♥♥♥♥♥♥!!!!!!!H0TBABEZ4U!!!!!!!.AVI♥♥♥♥♥♥♥♥♥♥♥♥♥♥.exe

Anti-virus software may be able to tell you which particular trojan it is, but do you really care? In practice, there's seldom a reason to use the software unless an institutional policy requires it. Windows malware is so widespread that you should assume it's in every unknown email attachment until proven otherwise.

The ClamXav developer won't try to "upsell" you to a paid version of the product. Other developers may do that. Don't be upsold. For one thing, you should not pay to protect Windows users from the consequences of their choice of computing platform. For another, a paid upgrade from a free app will probably have all the disadvantages mentioned in section 7.

9. It seems to be a common belief that the built-in Application Firewall acts as a barrier to infection, or prevents malware from functioning. It does neither. It blocks inbound connections to certain network services you're running, such as file sharing. It's disabled by default and you should leave it that way if you're behind a router on a private home or office network. Activate it only when you're on an untrusted network, for instance a public Wi-Fi hotspot, where you don't want to provide services. Disable any services you don't use in the Sharing preference pane. All are disabled by default.

10. As a Mac user you don't have to live in fear that your computer may be infected every time you install software, read email, or visit a web page. But neither should you assume that you will always be safe from exploitation, no matter what you do. The greatest harm done by security software is precisely its selling point: it makes people feel safe. They may then feel safe enough to take risks from which the software doesn't protect them. "Hmmmm, this torrent is a crack of that new game I want. I think I'll download it. It could be a trojan, but the antivirus will warn me if it is." Then they wonder why their Mac is so slow all of a sudden. It's slow because it's running flat out mining bitcoins for a hacker who has already sold their credit card number and banking passwords to a criminal gang. Maybe a week later the antivirus does warn them, but what good does that do?

Nothing can lessen the need for safe computing practices.

Jan 8, 2014 5:23 PM in response to jorost

jorost wrote:


Hi,


In OS X XProtect scans only /Downloads directory.

Actually, XProtect scans all files that have been quarantined by some Apple (Safari, Messages, iChat and Mail) and any other quarantine savvy applications, whether in the download folder or elsewhere.


Also, if you are considering the use of ClamXav you need to know that even though the ClamAV® scan engine used by it may be newer than the one Apple provides, it installs it in a different location and having two engines installed will usually result in conflict. I believe that some Server users have been able to work through this, but it wasn't easy, so I don't recommend it's use with the OS X Server. Similarly you should not use the ClamAV® engines that come with Mavericks Cache Cleaner or ProtectMac.

Jan 8, 2014 5:46 PM in response to jorost

I only user my server for filesharing. My approach has been to install AV software on each client, since they are the gateway to possible infections. I avoid installing anything unnescessary on the server itself, so as to avoid any incompatabilities that might affect server reliability or performance. I can scan the server files periodically (from a client), if I suspect a problem.

Jan 9, 2014 3:36 AM in response to fkick1

fkick1 wrote:



We use Sophos Free Antivirus in our office. It's got a live protection feature as well as schedulable scans, and it covers both PC and Mac Malware. It doesn't take a lot of resources, and it has caught problems in the past steming from PC users. Available at http://www.sophos.com/en-us/products/free-tools/sophos-antivirus-for-mac-home-ed ition.aspx

The licensing terms only allow using the free version at home. For the office you should pay for it (licensed per device, although licenses are usable on any supported device).


I have for years and years paid for Sophos at various places I have worked and also use the free version at home.

Dec 5, 2015 12:19 PM in response to Linc Davis

Wow. I don't typically feel the need to rant online, but I read Linc's entire post and found it, well ... demeaning. Especially to Windows users.


I can't disagree with most of the technical information he provided for two reasons:

  1. I'm not a 'schooled' I.T. person, or an Apple developer. I have no background in Unix or OS X security. I do controls and automation, but I tinker with I.T. as I can to make my job easier.
  2. His logic is sound, in that almost all network activity must be treated as unsafe.


But, I find the following statements to be bothersome:

An anti-virus app ... [is] useful only for detecting Windows malware, and even for that use it's not completely effective. Windows malware can't harm you directly (unless, of course, you use Windows.) Just don't pass it on to anyone else.
...For one thing, you should not pay to protect Windows users from the consequences of their choice of computing platform. For another, a paid upgrade from a free app will probably have all the disadvantages mentioned in section 7.


The original post indicated that the user wants to create a Server platform. Typically servers are created to help network multiple devices together. In my opinion, part of the responsibility of anyone creating a network resource (such as a server) is to ensure that their environment is safe for anyone that wishes to access it. You might, hypothetically, distribute files from your website hosted on an internal server. Anyone on any device needs access to these files, and you want them to remain uninfected for their safety (and your reputation). Remember... it might not just be you accessing the server. Consider whatever company assets you might have networked, but also any personal or customer assets you have and what might happen if one (or all of them) inherit a problem.


I speak now from experience: I am an employee of a very small company, and I manage our I.T. as best I can. I chose to run OS X server after two weeks of fighting Windows Server 2012. After less than a week running OS X Server hosting fileshares, I found malicious files injected into the entire fileshare of the server. Admittedly, this was my fault. I had opened a virtual machine at some time and I used it to access files from the servers network storage. It did it's dirty work and I found it the next day. Luckily, since I'm still 'developing' our network, no Windows users had accessed the network and I was able to clean things up quickly and quarantine the corrupted VM.


I don't have the resources or expertise to create 'domain policies' to force every computer to have antivirus, or the latest OS updates. But I want to do everything I can to keep our fileshare accessible and safe. So I installed Sophos. There's a whole other topic for discussion. All I will say at the moment is 1) It seems to be working, and 2. It REALLY slows down filesharing. 100MBps transfers with it off, and only 5MBps transfers when it's running. I'm currently looking at alternatives.


Back on topic, though...

So, before you dismiss antivirus because you think Windows users should deal with the 'consequences of [their] computing platform' think about your responsibility, and the integrity you desire to maintain as an I.T. professional (or whatever you aspire to be). I prefer to do whatever I feasibly can to guard against threats for the security of all parties involved, regardless of their 'choice of computing platform'.

Antivirus on OS X Server 10.9

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple ID.