Detect discrepancies in subIds

The subIds in network capabilities are stored both in
the network specifier (for telephony) or transportInfo (for
wifi), and in a separate field in NC, which are seeded
differently. These should in principle never diverge if there
is no bug in the network factories code, but since this code
is OEM-specific, it's very hard to know whether it's the case.

Historically CarrierPrivilegeAuthenticator has been using the
specifier / info to find out about the sub id, but reading
from NetworkCapabilities#getSubscriptionIds() would be both
nicer and more future-proof. Log a terrible failure in case
they differ, so we can confidently switch to the latter if
we don't see any such log.

Change-Id: Ifdf67318ceb881349e322591632c18a4dbf218e1
Test: NetworkAgentTest
1 file changed