macloader: Stop allowing G and O write perms to the cidfile

* Only macloader should ever write to this, but others (e.g,
  libbt-vendor.so) read from it. 0644 is more than enough.

Change-Id: I3d2fb3dfec1ba81c9c382ed18c93114e641df4a0
tirimbino
Kevin F. Haggerty 6 years ago
parent ea125c30ea
commit 523971c63b
  1. 2
      macloader/macloader.c

@ -230,7 +230,7 @@ int main() {
ALOGD("Change permissions of %s\n", CID_PATH);
fd = fileno(cidfile);
amode = S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH;
amode = S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH;
ret = fchmod(fd, amode);
if (ret != 0) {
ALOGE("Can't set permissions on %s - %s\n",

Loading…
Cancel
Save