Commit Graph

81 Commits

Author SHA1 Message Date
Matt Sarett
7fb08c55f5 Update callers *GifCloseFile for new GIFLIB DO NOT MERGE am: 60519c717e am: 0cf3a7d3ec am: 93facf6314
am: cc1dbfc497  -s ours

Change-Id: I15259006a672182c3d5abab0172eb51d94e64c2b
2017-03-15 16:49:25 +00:00
Matt Sarett
cc1dbfc497 Update callers *GifCloseFile for new GIFLIB DO NOT MERGE am: 60519c717e am: 0cf3a7d3ec
am: 93facf6314

Change-Id: Ib851a4d150690cc4959455dc0f7bc249fbd784c6
2017-03-15 16:45:22 +00:00
Matt Sarett
93facf6314 Update callers *GifCloseFile for new GIFLIB DO NOT MERGE am: 60519c717e
am: 0cf3a7d3ec

Change-Id: I17c2d833878a9e60efc9b65eb5c8d91299d5ea42
2017-03-15 16:39:46 +00:00
Matt Sarett
0cf3a7d3ec Update callers *GifCloseFile for new GIFLIB DO NOT MERGE
am: 60519c717e

Change-Id: I6f3b4664585a35d3177aea9371e283d567044e6e
2017-03-15 16:34:47 +00:00
Matt Sarett
60519c717e Update callers *GifCloseFile for new GIFLIB DO NOT MERGE
Bug:34697653
Test: build; existing CTS tests

Original commit message:
Fix build breakage caused by updating giflib

Change-Id: I085379470620ec4db13f8baf7a9eb069747270b7
2017-03-15 10:15:32 -04:00
Tom Taylor
cc649e4e1e 32764144 Security Vulnerability - heap buffer overflow in libgiftranscode.so in colorMap->Colors[colorIndex] am: 6f763fef7a am: 9f00add2fb am: 71d4913462
am: 82fa311e9a

Change-Id: Ifd7c99312f526e379268f5f12a5ff61d95a90996
2017-01-17 19:51:36 +00:00
Tom Taylor
82fa311e9a 32764144 Security Vulnerability - heap buffer overflow in libgiftranscode.so in colorMap->Colors[colorIndex] am: 6f763fef7a am: 9f00add2fb
am: 71d4913462

Change-Id: I114e41f77d0b7e07a2cf404a1d382451f7d6542f
2017-01-17 19:49:23 +00:00
Tom Taylor
71d4913462 32764144 Security Vulnerability - heap buffer overflow in libgiftranscode.so in colorMap->Colors[colorIndex] am: 6f763fef7a
am: 9f00add2fb

Change-Id: If555818f7f14dcfef35c57c1d3e918ac0f31959a
2017-01-17 19:46:53 +00:00
Tom Taylor
9f00add2fb 32764144 Security Vulnerability - heap buffer overflow in libgiftranscode.so in colorMap->Colors[colorIndex]
am: 6f763fef7a

Change-Id: Ia34564714e00734976099b95594b6ea6501894b9
2017-01-17 19:44:53 +00:00
Tom Taylor
6f763fef7a 32764144 Security Vulnerability - heap buffer overflow in libgiftranscode.so
in colorMap->Colors[colorIndex]

* No range checking was done on a color index. Add range
checking and bail if the color index is out of range.

Test: tested sending a large gif that would invoke the GifTranscoder library
to make the gif smaller.

Bug: 32764144
Change-Id: I44f36274ec333ae1960fa8fc96b2dbde35fbaa66
2017-01-13 14:47:35 -08:00
Tom Taylor
2917015529 33388925 Mismatched new vs delete in framesequence library am: 837474a376 am: b44b56b779 am: cefccea7b4
am: c708e8fb35

Change-Id: Iac2d9f2a4f11f4e0ec70c9aa9aeb8b105729ba7b
2017-01-06 17:51:59 +00:00
Tom Taylor
c708e8fb35 33388925 Mismatched new vs delete in framesequence library am: 837474a376 am: b44b56b779
am: cefccea7b4

Change-Id: Ie7926325beb817a1894a4f966a9053e284258330
2017-01-06 17:48:29 +00:00
Tom Taylor
cefccea7b4 33388925 Mismatched new vs delete in framesequence library am: 837474a376
am: b44b56b779

Change-Id: I18616dc9fff35bdfef460142dbf1b12a3f625a8e
2017-01-06 17:45:00 +00:00
Tom Taylor
b44b56b779 33388925 Mismatched new vs delete in framesequence library
am: 837474a376

Change-Id: I1882a0ea4cb061fe39b2a26c7cd77534a609168c
2017-01-06 17:41:33 +00:00
Tom Taylor
837474a376 33388925 Mismatched new vs delete in framesequence library
* The array allocations neglected to include [] so delete, instead
of delete [] would get called.

* Test
Manual
- tested sending a large gif that would invoke the GifTranscoder library
to make the gif smaller.

Bug: 33388925
Change-Id: I1e200e470d66ae615ffe9340ff9c049eaa73f63c
2017-01-04 09:42:37 -08:00
Tom Taylor
518c9798eb Merge "32161610 Security Vulnerability - Information disclosure vulnerability in AOSP Messaging" into mnc-dev am: 3f6e2e2b07 am: 091876853c am: 5cfdea9be6
am: ced2069d1c

Change-Id: I9ddf0377ce1eff5620104cd0a43bb2eba310e469
2016-12-07 02:41:54 +00:00
Tom Taylor
a43c5c5f18 resolve merge conflicts of eafd58a to nyc-dev
Change-Id: I58151ca0c248dd4b84c78c8e7ca73d5a80bbd962
2016-12-06 16:26:14 -08:00
Tom Taylor
313284eee7 32807795 Security Vulnerability - AOSP Messaging App: thirdparty can attach private files from "/data/data/com.android.messaging/" directory to the messaging app. am: a2aa53f83a am: 90bf70396d am: 305a004e19
am: 2397f2fbef

Change-Id: I16b590f76c9856d1407b336973ba86ff681415c6
2016-12-06 22:24:07 +00:00
Tom Taylor
ced2069d1c Merge "32161610 Security Vulnerability - Information disclosure vulnerability in AOSP Messaging" into mnc-dev am: 3f6e2e2b07 am: 091876853c
am: 5cfdea9be6

Change-Id: I1a1351fb195c7d35efc5ca343b966da78e49b71f
2016-12-06 22:20:25 +00:00
Tom Taylor
eafd58a112 32161610 Security Vulnerability - Information disclosure vulnerability in AOSP Messaging am: 69ed579fb8 am: 10dccb12ad
am: a21b8f936e

Change-Id: I5198e8db836d97da6aa05e56958a667af9388076
2016-12-06 22:20:14 +00:00
Tom Taylor
2397f2fbef 32807795 Security Vulnerability - AOSP Messaging App: thirdparty can attach private files from "/data/data/com.android.messaging/" directory to the messaging app. am: a2aa53f83a am: 90bf70396d
am: 305a004e19

Change-Id: I85b2da9eee3e18db7512ee4b4658f696ea619746
2016-12-06 22:20:07 +00:00
Tom Taylor
5cfdea9be6 Merge "32161610 Security Vulnerability - Information disclosure vulnerability in AOSP Messaging" into mnc-dev am: 3f6e2e2b07
am: 091876853c

Change-Id: Icd96de516d5b9512e6f26c7f66f4be7579eb8212
2016-12-06 22:16:51 +00:00
Tom Taylor
a21b8f936e 32161610 Security Vulnerability - Information disclosure vulnerability in AOSP Messaging am: 69ed579fb8
am: 10dccb12ad

Change-Id: Ia9830002762794a35da40daf8cc19f62434fabba
2016-12-06 22:16:44 +00:00
Tom Taylor
305a004e19 32807795 Security Vulnerability - AOSP Messaging App: thirdparty can attach private files from "/data/data/com.android.messaging/" directory to the messaging app. am: a2aa53f83a
am: 90bf70396d

Change-Id: I83792b4135c1e7adaf30f5835742fd1898b1b451
2016-12-06 22:16:36 +00:00
Tom Taylor
091876853c Merge "32161610 Security Vulnerability - Information disclosure vulnerability in AOSP Messaging" into mnc-dev
am: 3f6e2e2b07

Change-Id: I7778bcf83bde4fc352f247984e98d77af1e678f1
2016-12-06 22:13:15 +00:00
Tom Taylor
10dccb12ad 32161610 Security Vulnerability - Information disclosure vulnerability in AOSP Messaging
am: 69ed579fb8

Change-Id: I4be088ae899c6729da2197a9ab23951dc95c238e
2016-12-06 22:13:14 +00:00
Tom Taylor
90bf70396d 32807795 Security Vulnerability - AOSP Messaging App: thirdparty can attach private files from "/data/data/com.android.messaging/" directory to the messaging app.
am: a2aa53f83a

Change-Id: I65590775f92c296b490cdc0fa30815a7f69e1e38
2016-12-06 22:13:07 +00:00
Tom Taylor
3f6e2e2b07 Merge "32161610 Security Vulnerability - Information disclosure vulnerability in AOSP Messaging" into mnc-dev 2016-12-06 22:11:03 +00:00
Tom Taylor
a2aa53f83a 32807795 Security Vulnerability - AOSP Messaging App: thirdparty can
attach private files from "/data/data/com.android.messaging/"
directory to the messaging app.

* This is a manual merge from ag/871758 -- backporting a security fix from
Bugle to Kazoo.
* Don't export the MediaScratchFileProvider or the MmsFileProvider. This
will block external access from third party apps. In addition, make both
providers more robust in handling path names. Make sure the file paths
handled in the providers point to the expected directory.

Change-Id: I9e6b3ae0e122e3f5022243418f2893d4a0859edb
Fixes: 32807795
2016-12-05 16:39:55 -08:00
Tom Taylor
a044afd70d 32322450 Security Vulnerability - heap buffer overflow in libgiftranscode.so am: bcc1f62715 am: 5311a02e27 am: 954e81ed44
am: e215495b3b

Change-Id: I41014416971669f09f0d43b1a548dc56ba570e4e
2016-12-05 23:03:11 +00:00
Tom Taylor
e215495b3b 32322450 Security Vulnerability - heap buffer overflow in libgiftranscode.so am: bcc1f62715 am: 5311a02e27
am: 954e81ed44

Change-Id: I33a015563c7ca0acc011de6e5b30d53d8ae1a7e8
2016-12-05 23:00:12 +00:00
Tom Taylor
954e81ed44 32322450 Security Vulnerability - heap buffer overflow in libgiftranscode.so am: bcc1f62715
am: 5311a02e27

Change-Id: I2afadd0fe76f451304f4aa6d7f6a9b0c35dfaf54
2016-12-05 22:57:11 +00:00
Tom Taylor
5311a02e27 32322450 Security Vulnerability - heap buffer overflow in libgiftranscode.so
am: bcc1f62715

Change-Id: Ia790b66a2d7d26b53463ebb2ebae524a7b4155fc
2016-12-05 22:53:45 +00:00
Tom Taylor
69ed579fb8 32161610 Security Vulnerability - Information disclosure vulnerability
in AOSP Messaging

* Check to make sure the returned uri from the gallery picker does
not point to bugle's data directory (or any subdir).

* Test:
Manual-
* I created the test app in the bug, the one that injects the bad
uri into Bugle. I verified the bad behavior before the fix and the
good behavior after.
* I tested the gallery to make sure picking photos,
from the photos app and drive, still work.
* I verified the behavior in the debugger to be sure the code is
catching the bad uri from the test app.

Change-Id: I3393f3b886c837a49758b91945cf1e17ec9bee41
Fixes: 32161610
2016-12-05 13:57:45 -08:00
Tom Taylor
bcc1f62715 32322450 Security Vulnerability - heap buffer overflow in libgiftranscode.so
* No range checking was done on the background color index. Add range
checking and bail if the color index is out of range.

* Test
Manual
- tested sending the gif attached in the bug.
- tested sending a 3.5mb gif to verify the gif transcoding was taking place.
- tested on arm64, arm, and x86 devices.

Change-Id: Id16ddccf05c8472ddebc1284b2a928dafd1be551
Fixes: 32322450
2016-12-01 12:20:44 -08:00
Tavis Bohne
9de3ed279b Merge "Messenger refuses all file:///data/ uris" into nyc-dev 2016-06-08 16:46:45 +00:00
Bill Yi
f1210c127a Bump targetSdkVersion to 24
This will only affect AOSP build.

BUG:28621267
Change-Id: I13f47b838c743674d371901bed2bb7b0e2cfcfc2
2016-06-02 16:23:08 -07:00
Tavis Bohne
41f3b673f1 Messenger refuses all file:///data/ uris
We've been informed it's possible for an app to create a world
readable hardlink in L in its own /data directory that links to
another apps private data, including Messenger data. The hardlink
bypassed our existing checks. So now we simply refuse all file: uris
in the /data/ directory.
Other apps shouldn't be sending file uris anyway, and we dont know
of any that send file:///data/ uris.

Bug: 28793303
Change-Id: I778bb2bcb9e11185357093c59fc1fa3f6caa26a1
2016-05-17 17:36:51 -07:00
Tavis Bohne
ca5fc9fa7d Merge "Messaging doesn't allow sharing of its own files" into nyc-dev 2016-05-16 18:14:20 +00:00
Tony Mak
c4073ff4ce Add badge icon for work contact in search result
BUG=26021888
BUG=28016344
(cherry picked from commit 6e00763823cd1b27ff88d25d0eb11f8addc3b2e6)

Change-Id: If0e2f7b1c58cd064ebfdae8a9b735b391c5009fc
2016-05-16 16:35:06 +01:00
Tony Mak
e2ccf8bff5 Cleanup enterprise feature in ContactUtil
1. Remove isWorkProfileSupported checking, api level checking is enough.
2. Replace the hardcoded uri with the corresponding api.

BUG=26797244
BUG=28016344
(cherry picked from commit 0d7a1cce157e4ffb26d5fefb9908bbeffcb1d03c)

Change-Id: I76edad19dc6a19aa77b523cb960f716fca08944d
2016-05-16 16:34:58 +01:00
Tony Mak
9045160771 Separate work and personal contacts search result
This change allows sms app to show search result of different directories
in different partitions.
Currently, only personal default and enterprise default directory are
searched.

BUG=26021888
BUG=28016344
(cherry picked from commit 59666b32c192bd28807ccd2f9153c796668bdf13)

Change-Id: I733ceaae806d13661861126ce61c34108ac7e662
2016-05-16 16:34:43 +01:00
Tony Mak
b7fc988f23 Search enterprise directory as well in SMS app
TODO: Update the UI to show enterprise result separately (b/26021888)

Bug: 28016344, 25977180
(cherry picked from commit 5c621e57256f5068a43f1456f9bab1194f0d27b2)

Change-Id: I7130ae5e057ed750a29f64c5497a04b868613579
2016-05-16 16:34:24 +01:00
Victor Chang
0a85b81c9f Add isAtLeastN in OsUtil
Bug: 28016344
Change-Id: I431b4fed3f2114d1f1b311416a892f608a846e4c
2016-05-11 18:07:38 +01:00
Tavis Bohne
30fb338539 Messaging doesn't allow sharing of its own files
-Previously, Messaging allowed sharing of any file it had permission
 to reach. This meant that bad apps could share a link to
 file:///data/data/com.android.messaging/databases/bugle_db
 and Messaging would happily send all this sensitive information to
 the target. Worse, a bad app could share a softlink to this file,
 where the symlink was picture.jpg with the image/jpg type.
-Now, when sanitizing attachments, we make sure any filepaths don't
 lead to any Bugle-specific directories.
-getApplicationInfo().dataDir is a symlink to
 /data/data/com.android.messaging, and appears to be the
 only directory where we store personal data.
-Most apps share as contentUris, including Messaging, so Messaging
 can still share to itself.

Change-Id: Ic464bc1f099029a030793c478aaf88b957d8bad1
Fixes:28076752
2016-04-29 14:39:59 -07:00
Tom Taylor
7fe2fc9b2f Messaging app ClassCastException (DecorContext -> Activity) when SMSoIMS is initiated
Bug 27649619

Change-Id: I1c0de7c14abd255ceb9d61a377db3276c32fede0
2016-03-21 13:44:13 -07:00
Yohann Roussel
49528d492f Revert "Pin messaging to use Jack with 1.7 language"
This reverts commit 445d7baabc.

Bug: 27333568
Bug: 27305482
Bug: 26753820
Change-Id: I44c126c3a54de332c0032e1d7d158f95099bfc03
2016-02-26 15:26:55 +00:00
Neil Fuller
445d7baabc Pin messaging to use Jack with 1.7 language
There is a bug in the current version of Jack
that causes problems when the default is changed to
1.8. Pinning to 1.7 appears to help.

Bug: 27305482
Bug: 26753820
Change-Id: Ia29bf5cb14c754be4c4b453aa89a9d9c369d9e52
2016-02-23 12:00:42 +00:00
Yohann Roussel
280a2fbe41 Re-enable Jack for Messaging and its tests
Jack was disabled because of bugs in Jack and missing support for testing
obfuscated applications. Both are now fixed so Jack can be enabled.

Bug: 27215871

(cherry picked from commit bf6bd40faa)

Change-Id: I73d3c5a3599640932b2305ffe22bb5ef27814ba3
2016-02-22 11:54:35 +01:00
Ye Wen
ec2fe3006b Remove "_" variable for Java 8
b/27045502

Change-Id: I7ce2bb262fdc2b64f2c6b3cb629a2ec93450b265
2016-02-09 23:33:14 +00:00