replicant-frameworks_native/libs/binder
Nick Kralevich b6b1423c87 Parcel.cpp: reject size_t arguments greater than INT32_MAX
It's a security best practice for size_t values to be rejected if
they are greater than INT32_SIZE. This is intended to prevent the
common error of inadvertently passing a negative int value to a
function, which after conversion to an unsigned type, becomes a huge
number, defeating the purpose of bounds checking.

This patch also addresses a bug where the call to:
  Parcel::write(buf, (size_t) -1);
would call writeInPlace() which uses PAD_SIZE on the supplied
argument. This would then cause an integer overflow, with PAD_SIZE
returning a small value, but the memcpy in Parcel::write using the
old large length value.

Bug: 19573085
Change-Id: Ib11bfb3dae4f3be91cd17b2c676926700972c7b8
2015-04-02 10:56:12 -07:00
..
tests Replace all instances of intptr_t with uintptr_t. 2015-01-13 21:59:44 +00:00
Android.mk Add ProcessInfoService to activity manager. 2015-02-02 14:56:55 -08:00
AppOpsManager.cpp Replace IInterface::asBinder() with a static 2014-11-17 08:47:01 -08:00
Binder.cpp C++11 compatibility. 2014-11-20 21:04:35 +00:00
BpBinder.cpp Binder: Remove unused functions & variables 2014-11-24 11:39:11 -08:00
BufferedTextOutput.cpp libutils clean-up 2013-05-07 18:28:11 -07:00
Debug.cpp We HAVE_LITTLE_ENDIAN. 2014-11-21 23:35:36 -08:00
IAppOpsCallback.cpp binder: rm utils/Debug.h 2014-05-29 13:10:03 -07:00
IAppOpsService.cpp Replace IInterface::asBinder() with a static 2014-11-17 08:47:01 -08:00
IBatteryStats.cpp add noteResetVideo/Audio to IBatteryStats 2014-07-23 21:51:56 +00:00
IInterface.cpp Add backwards compatible versions of IInterface::asBinder() 2015-03-31 20:32:30 +00:00
IMemory.cpp Replace IInterface::asBinder() with a static 2014-11-17 08:47:01 -08:00
IPCThreadState.cpp Kill HAVE_PTHREADS. 2015-01-26 22:36:36 -08:00
IPermissionController.cpp binder: rm utils/Debug.h 2014-05-29 13:10:03 -07:00
IProcessInfoService.cpp Add ProcessInfoService to activity manager. 2015-02-02 14:56:55 -08:00
IServiceManager.cpp Replace IInterface::asBinder() with a static 2014-11-17 08:47:01 -08:00
MemoryBase.cpp Revert "Second try at adding a compatibility symbol for the MemoryBase constructor." 2013-07-09 22:15:42 +00:00
MemoryDealer.cpp Allow creation of heaps that are read-only to partner 2014-03-18 15:07:43 -07:00
MemoryHeapBase.cpp Remove references to obsolete pmem functionality. 2013-11-21 12:22:39 -08:00
Parcel.cpp Parcel.cpp: reject size_t arguments greater than INT32_MAX 2015-04-02 10:56:12 -07:00
PermissionCache.cpp Rename (IF_)LOGD(_IF) to (IF_)ALOGD(_IF) DO NOT MERGE 2012-01-03 22:38:27 +00:00
ProcessInfoService.cpp Add ProcessInfoService to activity manager. 2015-02-02 14:56:55 -08:00
ProcessState.cpp Remove global variables from ProcessState. 2014-04-03 12:29:44 +00:00
Static.cpp Fix issue #18356768: some app process may hang at Runtime#exit... 2014-11-13 17:09:59 -08:00
TextOutput.cpp Fix output of pointers for 64bit devices. 2014-10-31 11:08:19 -07:00