Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bff6b3dc authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "libbinder fuzzer driver: clear calling identity" am: be2bf570 am:...

Merge "libbinder fuzzer driver: clear calling identity" am: be2bf570 am: 288a184e am: 3f115d36 am: 2bcebdab am: 342a472f am: a08bc3f8

Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/2645989



Change-Id: If433fa2bea8b24e49df95523bbf3a9c1e325e7a2
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents c4a56e2c a08bc3f8
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -33,6 +33,10 @@ void fuzzService(const std::vector<sp<IBinder>>& binders, FuzzedDataProvider&& p
            .extraFds = {},
    };

    // always refresh the calling identity, because we sometimes set it below, but also,
    // the code we're fuzzing might reset it
    IPCThreadState::self()->clearCallingIdentity();

    // Always take so that a perturbation of just the one ConsumeBool byte will always
    // take the same path, but with a different UID. Without this, the fuzzer needs to
    // guess both the change in value and the shift at the same time.