Encode values when serializing android-app Intent
And decodes them when reconstructing the Intent. Also adds methods to Uri to check whether a string is already encoded (whether it does not contain any non-allowed characters) which are used to enforce that values are encoded when serializing. This does not solve the problem for generic URIs that were not serialized using the framework APIs, as it's not possible to tell whether or not a particular string containing invalid characters should be encoded or not. For example, in a query string, `key=value` might accidentally encode the `=`, which might break some usages of Uri.Part. This is a high risk that this will break the parsing of arbitrary URIs which do not conform to the encoding structure the framework APIs expect, but would otherwise work before this change. Bug: 281848623 Bug: 281849097 Bug: 281849163 Test: atest android.content.cts.IntentEncodingParameterizedTest Change-Id: I6e3e93247a8ac02e661d267976c7b6e7093a47c1
Loading
Please register or sign in to comment