Sourcefire's (NASDAQ:FIRE) shareholders have mostly endured bad news since the company's IPO in March. The network-security specialist had two disappointing quarterly reports, leaving the stock worth 46% less than when it debuted. But management is trying to get things back on track. Late last week, it agreed to purchase privately held ClamAV, in what looks like a savvy deal.

Both Sourcefire and ClamAV use an open-source software model, posting the source code to their projects on the Internet, and enlisting the contributions of thousands of volunteer programmers. While that seems dicey, it has resulted in some top-notch programs, including the various flavors of the Linux operating system, and it doesn't require the huge overhead costs of traditional software companies.

Sourcefire controls Snort, an open-source intrusion security system that counts more than 100,000 registered users. While Snort itself is free, the company has found a way to develop proprietary products based on Snort, which it sells using the traditional enterprise license model. Sourcefire expects to generate $55 million-$58 million in revenue for the year.

ClamAV, which develops software to defend computers against viruses and other malicious programs, also has a thriving global community, with about 1 million daily downloads for updates. Based on various surveys, its software stacks up well against traditional offerings from rivals such as Symantec (NASDAQ:SYMC) and McAfee (NYSE:MFE).

Sourcefire did not disclose the price tag on the deal. Then again, ClamAV has only five employees and consists mostly of intellectual property. Sourcefire estimates a fiscal Q3 write-off of $0.09-$0.12 per share, because of in-process R&D.

To crank out cash from the deal, Sourcefire plans to offer premium training and support services for ClamAV, in addition to developing new commercial products.

Sourcefire undoubtedly knows how to pull off a deal like this, but it'll need at least a year to get new products on the market. In the meantime, the company must still compete with fierce rivals like IBM (NYSE:IBM), Cisco (NASDAQ:CSCO), and Symantec. Another issue has been the weakness in the federal government market, a key source of revenue for Sourcefire. As I've mentioned before, investors should still remain cautious for now.

Further Foolish pearls of wisdom:

Symantec is a  Motley Fool Inside Value pick. Discover more of the market's best bargains with a free 30-day trial subscription

Fool contributor Tom Taulli, author of The Complete M&A Handbook, does not own shares mentioned in this article. He is currently ranked 2,111 out of more than 60,000 total participants in CAPS.