To cut down on warranty claims, Apple has added a background feature with macOS Sonoma that runs liquid detection analysis on every USB-C port on a Mac.
USB-C ports (plus left, MagSafe, and right, a headphone jack) on a 14-inch MacBook Pro
Back in 2010, Apple was sued over how it uses moisture indicators on iPhones to determine whether a user's insistence they hadn't dropped the device in water was true or not. The suit claimed the indicators weren't accurate, and Apple lost the case, having to ultimately pay a $53 million settlement.
Quite possibly as a result of that, Apple in 2012 filed a patent application for a system to improve its water sensors. That filing specifically noted that it was being done because customers were frequently receiving replacements for products that were damaged in methods not covered under warranty.
That was because Apple Store staff could be unqualified, or not have the facilities, to check whether or not a device has water damage.
Flash forward to 2016, and Apple has the same idea with iPhones, but also makes it a user feature. Starting in iOS 10, not only could the iPhone determine that liquid had been detected in the Lightning port, it would warn the user.
The idea was that the user could then turn off the iPhone and hopefully do so before irreversible water damage.
Now as spotted by 9to5mac, macOS Sonoma has added some similar background liquid detection analysis that checks for liquid in the USB-C ports. As yet, Apple does not use this as a way to warn users to unplug their possibly soaking wet devices, and actually the company does not say what it's for at all.
But given the company's long-standing efforts -- and the wording of its warranties -- water-damaged devices are presumably a significant issue and this is presumably a way in which engineers can detect it.
However, if this is its purpose, the new "Liquid Detection and Corrosion Mitigation Daemon" element of macOS Sonoma is only one of the methods Apple can use to detect water damage. The chief one is the use of Liquid Contact Indicators (LCI), which change color when exposed to liquids, and are used across the Mac and iPhone.