Samsung wanted to know how much HTC had paid for its licences. The thinking is that Apple might have charged HTC less than it had been demanding from Samsung for the same licence.
According to Bloomberg. the question of which patents are covered by the Apple-HTC settlement, and licensing details could be instrumental in stuffing up Apple's attempts to ban Samsung products.
US courts are not happy about blocking the sale of products if a licence has been agreed in other cases. They rightly see it as bad because a licensee could be petty and not come up with a viable price with companies that it does not like.
The court ordered Apple to produce a full copy of the settlement agreement "without delay", subject to an Attorneys-Eyes-Only designation.
Just so that Apple felt some legal pressure, Samsung also requested the California court to add the iPod Touch 5, the iPad 4 and the iPad mini to the list of devices that it claims to have infringed on some of its patents.