AbbVie (ABBV - Get Report) shares are up 7% year to date. But the company faces a patent battle.

TNF inhibiting anti-inflammatory drug Adalimumab was invented in Worcester, Mass., in the early 1990s by a partnership between German chemistry company BASF Knoll and Cambridge Antibody Technology. Later, Abbott Labs (ABT - Get Report) acquired BASF Knoll and renamed the compound Humira. By 2002, the FDA approved Humira for the treatment of rheumatoid arthritis. Humira was approved for the treatment of psoriatic arthritis in 2005 and Crohn's Disease in 2006.

On Jan. 1, 2013, Abbott Labs split into two companies: Abbott Labs and AbbVie. AbbVie took the rights to Humira. In 2014, with annual sales of $13 billion, Humira was named the world's best-selling drug. It took down Lipitor, Plavix, Enbrel, Crestor and Avastin, to name a few.

But Humira's patent expires in 2016. That has set off a rush of biosimilar competition. On July 13, an FDA advisory committee approved Amgen's (AMGN - Get Report) ABP-501 Humira biosimilar compound by a 26 to 0 vote. Analysts expect ABP-501 to receive full FDA approval on Sept. 25.

The FDA panel said Amgen's compound was "highly similar" to Humira and that there were "no clinically meaningful" differences between the treatments. It also said that in terms of safety, purity and potency the data supports biosimilarity. Ouch!

AbbVie is not taking this lying down. The company believes it holds approximately 80 valid U.S. patents on Humira and can protect the medication through 2022. Biosimilar maker Coherus (CHRS - Get Report) has already asked the Patent Office to review AbbVie's 8,889,135 patent, which covers rheumatoid arthritis through 2022. The patent board has one year to make a decision on the patent. Should AbbVie lose at the patent office, the company will launch an appeal.

Meanwhile, AbbVie is litigating everything in sight. Besides Coherus and Amgen, there are at least three other companies hovering over AbbVie's patents.

AbbVie believes even if it looses a few rounds at the patent office or in court, its patent estate is exceptionally strong and it would be very difficult to launch a major drug with only one or two legal victories. If things get dire, it could still file a last-minute injunction to stop any drug launch, figuring no drug company would sell a medication that could be pulled from the market by an adverse court ruling.

The outcome of all of this is highly uncertain. Analysts expect at least five years of litigation before any company can launch a drug. From the looks of it, Amgen will have plenty of time to come up with a catchier name than ABP-501.

The litigation overhang on Humira is important because Humira is about 60% of AbbVie's revenue and 70% of earnings. This year the company is expected to have revenue of $25.8 billion and earnings of $4.81 per share.

Humira is priced at $3,100 per month.

Management has been making the rounds, talking about how it can hold Humira together until 2020 and how it has put out fires with other late-stage treatments. All told, management believes it can squeeze another $18 billion out of Humira and $25 billion to $30 billion out of its other eight late-stage drugs.

AbbVie cites Amgen's treatment for rheumatoid arthritis, Enbrel, as an example of a drug that was rescued by the lawyers. Enbrel's patent was supposed to expire in 2011, but the legal team found a way to extend it another 17 years. 

Obviously all of this headline risk has made long-term investors uneasy. An unexpected court ruling or patent office comment could crush the stock. Traders are attracted to the volatility.

I think I will sit this one out on the sidelines, especially since the full FDA vote on Amgen's ABP-501 approval is coming up on Sept. 25. That could be the start of a battle royale. 

This article is commentary by an independent contributor. At the time of publication, the author held no positions in the stocks mentioned.