
CVE-2017-13286 Poc (لا يمكن استخدامه)
CVE-2017-13286 Poc(لا يمكن استخدامه)
جميع الموارد مأخوذة من هذه المقالة https://bbs.kanxue.com/thread-268506.htm
public void writeToParcel(Parcel dest, int flags) {
if (dest == null) {
throw new IllegalArgumentException("dest must not be null");
}
dest.writeInt(mRotation);
dest.writeInt(mSurfaceGroupId);
dest.writeInt(mSurfaceType);
dest.writeInt(mConfiguredSize.getWidth());
dest.writeInt(mConfiguredSize.getHeight());
dest.writeInt(mIsDeferredConfig ? 1 : 0);
dest.writeInt(mIsShared ? 1 : 0);
dest.writeTypedList(mSurfaces);
}
private OutputConfiguration(@NonNull Parcel source) {
int rotation = source.readInt();
int surfaceSetId = source.readInt();
int surfaceType = source.readInt();
int width = source.readInt();
int height = source.readInt();
boolean isDeferred = source.readInt() == 1;
// missing write mIsShared
ArrayList<Surface> surfaces = new ArrayList<Surface>();
source.readTypedList(surfaces, Surface.CREATOR);
checkArgumentInRange(rotation, ROTATION_0, ROTATION_270, "Rotation constant");
...
...
...
}
يمكن ملاحظة أنه في هذا الإصدار من AOSP، لم يتم قراءة mIsShared، ولكن تم كتابته.
باستخدام هذا، يمكننا بناء بيانات تسلسل Parcel ضارة لجعل النظام ينفذ بعض الأشياء.
مسار كود الثغرة في AOSP هو: frameworks/base/core/java/android/hardware/camera2/params/OutputConfiguration.java
لم يتم إصلاح هذا فقط، بل تمت إضافة المزيد من العناصر الافتراضية إلى كائن التسلسل الحالي.