It seems to be an annual rite of spring: Microsoft (NASDAQ:MSFT) slaps down upstart Sun Microsystems (NASDAQ:SUNW) and the New York Yankees get ready to break the hearts of each and every Boston Red Sox fan.

Long-standing underdogs received a huge shot in the armearlier this month when Sun Micro's general, Scott McNealy, decided to give peace a chance by settling the company's David vs. Goliath lawsuit against Microsoft. That historic accord, combined with the Yankees splitting games with the lowly Tampa Bay Devil Rays in Japan, must have given pause to Evil Empire leaders George Steinbrenner and Bill Gates.

Maybe this will finally be the year that a pair of curses will be broken. Ever since the Big Blue Machine at IBM (NYSE:IBM) turned the other cheek and gave Bill Gates and friends some daylight, Microsoft has been a cash-generating, R&D-driven, world-dominating (dare I say monopolistic?) machine. Could this historic Sun-Microsoft settlement finally give Scott McNealy the opening he's been fighting for for years?

In short, Microsoft agreed to pay Sun $1.6 billion to resolve pending patent and antitrust matters (it was allegedly looking over Sun's shoulder and copying technology). Additionally, Microsoft will also make a $350 million royalty payment to Sun. In return, Sun will drop its pending domestic litigation against Microsoft. The real opportunity for Sun is in its proprietary technology; it has produced many cutting-edge products and had the industry leader make replicas of that technology, which has negatively impacted both revenues and profit.

Sun not only gets some much-needed cash from Microsoft, it has also set the precedent that whatever it produces in-house will stay in-house. The two companies will also work to make Sun's Java and Microsoft's Windows platforms compatible for all PC users, which will give Sun an opportunity to tap into a previously unavailable customer base. It was also good for Sun to get rid of all that anger toward Microsoft, which included a hefty legal bill for years of litigation. The Red Sox, however, still have to deal with the Curse of the Bambino, which is probably as much of a loser's mentality than a real curse.

With Microsoft and fellow behemoth Intel (NASDAQ:INTC) dominating the technology and computer industry for much of the past decade, it's been quite difficult for companies such as Sun Microsystems and Advanced Micro Devices (NYSE:AMD) to gain any type of strong footing. One quick look at some key financial statement numbers of Sun and Microsoft reveal an obvious trail of the toll that the technology war has taken on Sun. Microsoft has nearly $53 billion in cash ($2.2 billion for Sun), virtually no debt ($1.5 billion for Sun), cash flow from operations of nearly $15 billion ($383 million for Sun), and free cash flow of $14 billion (minus $64 million for Sun).

While I don't see Sun turning around its slightly sinking ship over night, I do see some heightened upside potential over the next six months to a year. The company has always wisely plowed much cash back into research and development and has come up with many good products, including the world-famous Java platform.

Sun has been hit quite hard since the Internet bust three years ago. The shares, which had been trading over $80 per stub, have tumbled back down to earth and recently settled below the $5 mark. Conversely, Microsoft shares have only been sliced in half from January 2000 levels, held up largely by the company's dominant share of the software market and its stranglehold over any and all competition.

Sun's Scott McNealy must have felt like he and his company had a 14,000-pound elephant on their chest all of these years. McNealy made a smart move in settling with Microsoft, but don't bet on him giving up his fight anytime soon. I also wouldn't count on Microsoft's puppet-master Gates and CEO Steve Ballmer easing their feet off the gas going forward. While a huge weight has been lifted from Sun Micro's chest, I'm sure the Microsoft brass has quickly slid a 400-pound baby elephant back on Sun's fragile chest.

This development will give Sun a little more freedom to eat a slightly bigger slice of the software industry pie, but it will certainly not enable it to capture a significant share of the market. Stranger things have happened, but Sun must first cut costs in order to maximize efficiency. Sun's concurrent announcement of 3,300 job cuts should put it on the road to achieving a more fiscally responsible operating platform, as long as it doesn't slice a material amount of positions from its vitally important R&D division.

So, you might ask: "Phil, all of this information is great, but which stock should I buy?" Well, thanks for asking. When you combine the job cuts with a fundamental driver such as the Sun/Microsoft agreement, you have the makings of a spark that could ignite a flame. Sun's cost-cutting efforts and heightened revenue prospects (partly due to a 10-year alliance with Microsoft) should more than double the expected earnings per share (EPS) for the years of 2005 and 2006. Even though earnings are expected to be only $0.04 and $0.10 for those years, respectively, Sun has come a long way from its days of living in the red. With a five-year EPS growth rate projected in excess of 20%, it just may have returned to its roots as a formidable growth company

Given all this, and with Sun trading under $5 per share, I see the downside risk for this company being quite minimal. I would venture to guess that Scott McNealy hasn't been in this good of a mood since he broke 70 while playing golf. You have to respect McNealy's undying spirit and competitive nature just as much as you have to appreciate the early days of Gates and his posse at Microsoft. Scott McNealy has always been an admirable battler, but his company's results have been on the steady decline over the past few years. However, judging from the recent events, McNealy has decided to dislodge his head from beneath the ground and breathe some of that clean, crisp, big-company air. There are now many reasons to buy shares of Sun, with the primary fundamental drivers being its leaner cost structure, enhanced revenue prospects, and having a big buddy in industry leader Microsoft.

Conversely, the settlement should be seen as a curious misstep for Microsoft, which previously held onto its competitive advantage like a kid clutching onto the last Twinkie in the box. It was obvious that Microsoft was in danger of losing a lot more than just a little ground if it remained stubborn about its alleged monopoly. With steady pressure from domestic as well as international regulators to diminish the company's dominance, it was finally time for Microsoft to let a little air out of the balloon.

Fundamentally, Sun appears to be a patient who came off life support and ran out of the hospital. I've always been a fan of the underdog, or the long shot, and would like to think that both Sun Microsystems and the Boston Red Sox have legitimate shots at making a dent in the Evil Empires of both Microsoft and the New York Yankees this year. After all, it's spring, the time when all hope springs eternal.

Now what?
Join the discussion on our Sun Microsystems or Microsoft discussion boards. Do you think Sun has been beaten down enough to be a Hidden Gem? Let us know, and take a free trial to Tom Gardner's Motley Fool Hidden Gems newsletter.

The Red Sox and the Yankees meet for the first time this season tomorrow night. Fool contributor Phil Wohl doesn't own any of the companies mentioned in this article, but welcomes your feedback. The Motley Fool is investors writing for investors.