AT&T and the Justice Department could be on their way to a major court battle, which one analyst believes the company stands a strong chance of winning.

The fight centers on AT&T's hopes to acquire Time Warner and news Wednesday that the government wants the company to first sell Turner Broadcasting, which includes CNN, or sell DirecTV. AT&T CEO Randall Stephenson said the company has no intentions of divesting itself of those holdings.

Paul Gallant, a Washington analyst at Cowen Research, thinks the company won't have to.

"If this does go to court, we think AT&T holds a strong position and would likely prevail," Cowen said Thursday in a note to clients.

The company has three advantages, according to Gallant: The deal is "vertical" so it would be difficult to prove harm to the marketplace as it does not eliminate a rival; the DOJ would bear the burden of proof that the deal is anti-competitive; and the department's earlier attempts to negotiate behavioral conditions for approval indicate that it knows a legal case isn't strong.