174880 Commits

Author SHA1 Message Date
Alex Klyubin
499126c433 Merge "Add Keymaster KM_ORIGIN_UNKNOWN constant." 2015-04-16 19:50:12 +00:00
Brian Carlstrom
14a982aa7a Merge "Document hprof-conv -z" 2015-04-16 17:08:00 +00:00
Brian Carlstrom
d7931acf4a Document hprof-conv -z
Bug: 18473132
Change-Id: I3c0fcc2c15d4c590ed852f41aa4fd2a2531a6db8
2015-04-16 10:06:58 -07:00
Alex Klyubin
b9a78c7939 Merge "Add IV-related Keymaster error codes." 2015-04-16 16:39:31 +00:00
Alex Klyubin
216d18b997 Merge "Remove IV auto-generation workaround." 2015-04-16 16:39:10 +00:00
Miao Wang
782b43394e Merge "[RenderScript] typo fix in Allocation.java" 2015-04-16 02:03:32 +00:00
Miao Wang
179e8b5351 [RenderScript] typo fix in Allocation.java
Change-Id: Id0eae76387d18c5bfed6cdbb52781b0dc3e4ae90
2015-04-15 17:44:32 -07:00
Alex Klyubin
a0d2dddc55 Remove IV auto-generation workaround.
This workaround prevents use of keys with randomized encryption
(IND-CPA). Since randomized encryption is on by default, it's better
to keep it working and break non-randomized encryption (until
Keymaster is fixed).

Bug: 18088752
Change-Id: I4b11ce72cff705be41d3e66f28b507d6ddc1da79
2015-04-15 17:20:23 -07:00
Alex Klyubin
37d81d035c Add IV-related Keymaster error codes.
Bug: 18088752
Change-Id: I08daede713f945ad7dd0b21cc41ee12c15d94bad
2015-04-15 17:18:19 -07:00
Tim Murray
7f72f74766 Merge "Add BNNM intrinsic." 2015-04-15 22:30:14 +00:00
Shawn Willden
71ba4e461f Merge "Unbreak obtaining symmetric keys from AndroidKeyStore." 2015-04-15 17:37:37 +00:00
Michael Wright
150e0e87e1 Merge "fix return value scale of notifyANR()" 2015-04-15 10:53:21 +00:00
Martijn Coenen
6a47a86112 Merge "Add getPrefixAids()." 2015-04-15 08:00:13 +00:00
Martijn Coenen
ed3a29ea08 Add getPrefixAids().
Bug: 19144664
Change-Id: Ia49550102ccf1d40cd3f2bf7e5bd64d444a2e8a3
2015-04-15 09:48:57 +02:00
Alex Klyubin
5eacd777fe Unbreak obtaining symmetric keys from AndroidKeyStore.
This tracks 59f977c6988e21b3b8aa6c83428bd6ee1a98816d due to which
AndroidKeyStore is unable to provide symmetric keys because it
assumes that the digest field is not repeating.

Bug: 18088752
Change-Id: Ie8ed01449280b7c759e81aeaf2066953b0abaf2a
2015-04-14 19:02:46 -07:00
baik.han
def340d45e fix return value scale of notifyANR()
fix return value scale of notifyANR()
from milliseconds to nanoseconds when windowState is not null
This prevent unintended frequent method calls of notifyANR()
in a very short time.

Change-Id: Icc1f363b3ed3538821a42c080809567473bfb833
Signed-off-by: Baik Han <baik.han@lge.com>
2015-04-15 10:21:05 +09:00
Hiroshi Yamauchi
82992b7270 Merge "Fix javadoc error in Debug.getRuntimeStats()." 2015-04-14 23:49:03 +00:00
Dan Albert
571c5a26f7 Merge "Fix UB in ResourceTable::stringToInt." 2015-04-14 23:25:27 +00:00
Hiroshi Yamauchi
d8001676ea Fix javadoc error in Debug.getRuntimeStats().
Bug: 19825248
Change-Id: Id7131732d30f01c3edd01c6d4c7c391095ffd054
2015-04-14 16:08:49 -07:00
Tim Murray
9cb16a2f91 Add BNNM intrinsic.
Change-Id: I05fc9835786455e28d69f2b4ffe70c3292a01404
2015-04-14 15:10:19 -07:00
Alex Klyubin
d693690aee Merge "No need to specify EC curve name in EcIesParameterSpec." 2015-04-14 20:22:52 +00:00
Alex Klyubin
ecfda06461 Merge "Make specifying self-signed cert parameters optional." 2015-04-14 19:59:03 +00:00
Alex Klyubin
67d21aef98 Make specifying self-signed cert parameters optional.
This removes the need to specify the three parameters of the
self-signed certificate (serial number, subject, validity range) when
generating key pairs in AndroidKeyStore. This is achieved by
providing sensible defaults for these parameters:
* serial number: 1
* subject: CN=fake
* validity range: Jan 1 1970 to Jan 1 2048.

Bug: 18088752
Change-Id: I5df918b1ef8b26ed3ddd43828c4c78c9fa58cd43
2015-04-14 12:56:17 -07:00
Hiroshi Yamauchi
e38ee9df26 Merge "Add Debug.getRuntimeStat()." 2015-04-14 19:08:30 +00:00
Alex Klyubin
45d27836bd Add Keymaster KM_ORIGIN_UNKNOWN constant.
This tracks d359b044830b292f492f8a8df5471f869e358399 from
hardware/libhardware.

Bug: 18088752
Change-Id: I9a7bd8bdee51c18ae0427eff4efe036213d2b175
2015-04-14 10:52:34 -07:00
Hiroshi Yamauchi
8b5a293d09 Add Debug.getRuntimeStat().
Export runtime stats (currently GC stats) through this method.

Bug: 19825248
Change-Id: I147a0e9bc6bdfe4dc29d74e44f0af6349c51d9f8
2015-04-14 10:33:10 -07:00
Yang Ni
8704ae464a Merge "Add name to ScriptGroup2.Builder.create() method" 2015-04-14 16:15:54 +00:00
Erik Kline
3312c6b9f3 Merge "Add android.net.IpPrefix#contains()" 2015-04-14 07:58:33 +00:00
Erik Kline
acc8c09d3a Add android.net.IpPrefix#contains()
This was originally to avoid RuntimeException in RouteInfo#matches():
    When an IPv6 prefix with a length greater than the max permitted
    for IPv4 is matched against an Inet4Address, the call to
    NetworkUtils throws RuntimeException.

Change-Id: I92e2bd19a4e7d656cf682fd27678da07e211850d
2015-04-14 16:19:11 +09:00
Yang Ni
35be56cce8 Add name to ScriptGroup2.Builder.create() method
This name will be used to name the .so file generated for the
script group with fused kernels.

Change-Id: I46e351c8412740512f56b7915b14f36183c6eeaf
2015-04-13 17:24:44 -07:00
Ruchi Kandoi
3afca74a2a Merge "BatteryStats: Adds an additional condition to avoid ArrayIndexOutOfBounds." 2015-04-14 00:17:14 +00:00
Yang Ni
07cd641b6f Merge "Add a name to ScriptGroup2.Builder.create method" 2015-04-13 22:52:31 +00:00
Yang Ni
ad6b44aaa1 Add a name to ScriptGroup2.Builder.create method
The name is not used in any meaningful way yet, but would be used
to name the file for generated code for fused kernels in other
coming CLs.

A script group name cannot be null or empty, or longer than 100
characters. It can only contain letters, digits, '-', or '_'.

Change-Id: I95fdbf58e6689da91ca98c2057dfa1a803d3b27b
2015-04-13 14:32:18 -07:00
Alex Klyubin
33454dd569 No need to specify EC curve name in EcIesParameterSpec.
EC curve parameters will be obtained from the provided EC key.

Bug: 18088752
Change-Id: Ic99353a6566c8d4ce2b6b73d0309edaa40f84fa6
2015-04-13 10:20:24 -07:00
Alex Klyubin
d1af38a478 Merge "Use JCA names for block modes, paddings, and digests." 2015-04-13 17:01:30 +00:00
Alex Klyubin
5927c9f1b1 Use JCA names for block modes, paddings, and digests.
This replaces int-based enums from KeyStoreKeyConstraints with
String values commonly used in JCA API.

As part of under the hood refactoring:
* KeyStoreKeyCharacteristics and KeyStoreKeyConstraints have been
  merged into KeyStoreKeyProperties.
* KeymasterUtils methods operating on KeymasterArguments and
  KeymasterCharacteristics have been moved to their respective
  classes.

Bug: 18088752
Change-Id: I9c8b984cb3c28184adb617e34d87f2837bd1d3a1
2015-04-13 09:59:04 -07:00
Wale Ogunwale
8f0e0c1f3d Merge "Clean-up state if we have an exception when acquiring provider" 2015-04-13 04:25:29 +00:00
Alex Klyubin
c1c6528d2b Merge "Add EcIesParameterSpec to enable ECIES crypto." 2015-04-11 02:17:01 +00:00
Alex Klyubin
0ee9376ef4 Add EcIesParameterSpec to enable ECIES crypto.
Bug: 18088752
Change-Id: I597b019106c500188e0fbbc9608722668c08b421
2015-04-10 14:57:28 -07:00
Chad Brubaker
386c4e9ea9 Merge "Fix testSaw_ungrantedUid_Bluetooth" 2015-04-10 21:42:23 +00:00
Shawn Willden
97fce66f7d Merge "Make several key crypto parameters repeatable" 2015-04-10 21:21:37 +00:00
Chad Brubaker
6a5af8cf14 Fix testSaw_ungrantedUid_Bluetooth
Keystore.saw returns [] on no result, not null, so the test was
incorrectly failing.

Change-Id: I22dcf85c5d6c5c0368848bc784c3215c092d9ea8
2015-04-10 14:15:17 -07:00
Olawale Ogunwale
4406568eba Merge "Check caller status precisely when registering receiver." 2015-04-10 20:14:54 +00:00
Chad Brubaker
59f977c698 Make several key crypto parameters repeatable
Bug: 19509156
Change-Id: Ic584d8a6bf5601f9754563b67b3cc6b3ca6b5ff9
2015-04-10 12:20:04 -06:00
Alex Klyubin
a270264c61 Merge "Track more changes to keymaster_defs.h" 2015-04-10 17:51:49 +00:00
Wale Ogunwale
73e239bdc9 Clean-up state if we have an exception when acquiring provider
We can get a number of exceptions (e.g. SecurityException) when
a process is acquiring a provider. We need to clean-up correctly
so that other threads that try to acquire the provider the progress.

Bug: 20122809
Change-Id: Icac1d391df7e8c24198be89035b1c5a23da834cf
2015-04-10 09:32:26 -07:00
Nick Kralevich
08d76a946b Merge "Impose an ordering on created SELinuxMMAC Policy objects." 2015-04-10 16:10:27 +00:00
Alex Klyubin
55f7c2770f Track more changes to keymaster_defs.h
KeyStoreTest needed to be adjusted because OCB is no longer supported.

Bug: 18088752
Change-Id: I7594daaa5e97423d34726b07cc79e3ee28418d95
2015-04-10 08:58:38 -07:00
riddle_hsu
b15506f95e Check caller status precisely when registering receiver.
Fine tune commit 9ac9609f.
Because process may reuse same process record to restart.
It is better to check below conditions to skip:
1. Simple dead and has been cleaned.
 => .thread will be null
2.The process has restarted with new pid but has not attached yet.
 => .thread will be null
3.The process has restarted and attached.
 => The IBinder will be different

Change-Id: Ic052f5025558ca93e1a6ab11bca61fe995126bb9
2015-04-10 15:41:19 +00:00
John Reck
a08f6a66e9 Merge "Fix GL_INVALID_OPERATION in font renderer when font cache is limited." 2015-04-10 15:32:01 +00:00