Shares of Nokia gained more than 6 percent early Tuesday morning after the company's rocky-at-best relationship with Apple took a turn for the better; the two are now cooperating on new technologies.

Apple filed an antitrust case against Acacia Research Corp and alleged a conspiracy with Nokia, in which Acacia colluded with Nokia to "obtain from Nokia thousands of patents as part of a plan to extract and extort exorbitant revenues unfairly and anticompetitively from Apple and other innovative suppliers of cell phones, and ultimately from the consumers of those products."

That Was Then, This Is Now

According to a CNBC report, Apple and Nokia appear to have settled prior disputes and are now working together on new "digital health initiatives."

As part of the new collaboration, Apple will pay Nokia an up-front cash payment in exchange for network infrastructure products and services. The agreement also calls for Apple to re-stock Nokia's digital health products [pictured above] in its online and physical stores.

Additional details of the agreement remain scarce and it is not clear how the new agreement will effect Apple's secretive initiative to develop sensors to better treat diabetes.

CNBC noted that the total dollar amount of the agreement will reflected as patent licensing net sales in Nokia's technologies segment, and in other segments. Nokia will begin recognizing revenue in the second quarter of 2017.

"This is a meaningful agreement between Nokia and Apple," CNBC quoted Maria Varsellona, chief legal officer at Nokia as saying. "It moves our relationship with Apple from being adversaries in court to business partners working for the benefit of our customers."

In Tuesday's pre-market session, shares of Nokia were up 6.44 percent at $6.61; shares of Apple were relatively flat prior to the open, up 0.53 percent at $154.80.