Add source dimension to TlsHandshakeReported.
See also cl/479554194 - already approved.
There are potentially multiple versions of Conscrypt on
a device. Mainline, GMS, or included with an app by its
developer. A single app could conceivably contain and use
all three, and all three may be different versions.
This change adds a source dimension to allow us to differentiate
which version is used and monitor release quality of each
separately. Until the logging code in GMS and Mainline is
updated, everything will appear to be UNKNOWN.
Obviously this will require us to change our metric definitions
to pick out the different sources but as these metrics are
still in modulefood this shouldn't be problematic.
No privacy impact as there is no way to identify the user,
device or app from the flavour of Conscrypt in use. So assuming
this is covered by our existing PDD?
For storage, this Atoms is still in modulefood so assuming a
very small increase in storage required.
Test: m
Change-Id: I7b995531ee73a71925077d1498f63559e70fc5af
diff --git a/stats/atoms.proto b/stats/atoms.proto
index bcf8e76..93dbc53 100644
--- a/stats/atoms.proto
+++ b/stats/atoms.proto
@@ -17263,6 +17263,8 @@
optional android.stats.tls.CipherSuite cipher_suite = 3;
optional int32 handshake_duration_millis = 4;
+
+ optional android.stats.tls.Source source = 5;
}
/**
diff --git a/stats/enums/stats/tls/enums.proto b/stats/enums/stats/tls/enums.proto
index a64137d..aa9a833 100644
--- a/stats/enums/stats/tls/enums.proto
+++ b/stats/enums/stats/tls/enums.proto
@@ -68,3 +68,21 @@
TLS_CHACHA20_POLY1305_SHA256 = 0x1303;
}
+// Log source: Which flavour of Conscrypt is being used
+//
+// Keep in sync with
+// external/conscrypt/{android,platform}/src/main/java/org/conscrypt/Platform.java
+enum Source {
+ // Unknown - could be either GMS or Mainline.
+ SOURCE_UNKNOWN = 0;
+
+ // Conscrypt Mainline module.
+ SOURCE_MAINLINE = 1;
+
+ // GMS Conscrypt, as installed by the Play ProviderInstaller API.
+ SOURCE_GMS = 2;
+
+ // Conscrypt unbundled from the platform and included
+ // by app developer from Maven Central.
+ SOURCE_UNBUNDLED = 3;
+}