Searched refs:uid (Results 26 - 46 of 46) sorted by relevance

12

/system/core/libcutils/
H A Duevent.c40 * fails due to a bad uid check, the uid_t will be set to the uid of the
76 *user = cred->uid;
77 if (cred->uid != 0) {
H A Dmq.c51 uid_t uid; member in struct:__anon392
628 // Fake gid and uid until we have the real thing. The real creds are
631 credentials.uid = 0;
1050 credentials.uid = ucredentials.uid;
/system/core/init/
H A Ddevices.c78 unsigned int uid; member in struct:perms_
99 mode_t perm, unsigned int uid, unsigned int gid,
116 node->dp.uid = uid;
151 INFO("fixup %s %d %d 0%o\n", buf, dp->uid, dp->gid, dp->perm);
152 chown(buf, dp->uid, dp->gid);
157 static mode_t get_device_perm(const char *path, unsigned *uid, unsigned *gid) argument
178 *uid = dp->uid;
183 *uid
98 add_dev_perms(const char *name, const char *attr, mode_t perm, unsigned int uid, unsigned int gid, unsigned short prefix) argument
192 unsigned uid; local
[all...]
H A Dutil.c45 * android_name_to_id - returns the integer uid/gid associated with the given
63 * numeric or name representation, into the integer uid or gid. Returns -1U on
88 int create_socket(const char *name, int type, mode_t perm, uid_t uid, gid_t gid) argument
133 chown(addr.sun_path, uid, gid);
137 addr.sun_path, perm, uid, gid);
H A Dbuiltins.c91 static int _chown(const char *path, unsigned int uid, unsigned int gid) argument
101 ret = fchown(fd, uid, gid);
315 uid_t uid = decode_uid(args[3]); local
322 if (_chown(args[1], uid, gid) < 0) {
H A Dinit.c279 si->perm, si->uid, si->gid);
316 /* as requested, set our gid, supplemental gids, and uid */
329 if (svc->uid) {
330 if (setuid(svc->uid) != 0) {
H A Dinit_parser.c767 case K_socket: {/* name type perm [ uid gid ] */
787 si->uid = decode_uid(args[4]);
798 svc->uid = decode_uid(args[1]);
/system/core/debuggerd/
H A Ddebuggerd.c54 uid_t uid, gid; member in struct:__anon288
223 out_request->uid = cr.uid;
236 } else if (cr.uid == 0
237 || (cr.uid == AID_SYSTEM && msg.action == DEBUGGER_ACTION_DUMP_BACKTRACE)) {
241 &out_request->uid, &out_request->gid);
257 property_get("debug.db.uid", value, "-1");
259 return debug_uid >= 0 && request->uid <= (uid_t)debug_uid;
270 XLOG("BOOM: pid=%d uid=%d gid=%d tid=%d\n",
271 request.pid, request.uid, reques
[all...]
/system/netd/
H A DFirewallController.cpp132 int FirewallController::setUidRule(int uid, FirewallRule rule) { argument
134 sprintf(uidStr, "%d", uid);
144 res |= execIptables(V4V6, op, LOCAL_INPUT, "-m", "owner", "--uid-owner", uidStr,
146 res |= execIptables(V4V6, op, LOCAL_OUTPUT, "-m", "owner", "--uid-owner", uidStr,
H A DBandwidthController.cpp100 * iptables -A penalty_box -m owner --uid-owner app_3 \
284 std::string BandwidthController::makeIptablesNaughtyCmd(IptOp op, int uid) { argument
301 asprintf(&buff, "%s penalty_box -m owner --uid-owner %d", opFlag, uid);
322 std::list<int /*uid*/>::iterator it;
327 failLogTemplate = "Failed to add app uid %d to penalty box.";
331 failLogTemplate = "Failed to delete app uid %d from penalty box.";
347 int uid = appUids[uidNum]; local
349 if (*it == uid)
356 ALOGE("No such appUid %d to remove", uid);
[all...]
H A DBandwidthController.h115 std::string makeIptablesNaughtyCmd(IptOp op, int uid);
H A DCommandListener.cpp1432 int uid = atoi(argv[2]); local
1435 int res = sFirewallCtrl->setUidRule(uid, rule);
/system/extras/ext4_utils/
H A Dmake_ext4fs.c85 .uid = 0,
93 dentries.uid, dentries.gid, dentries.mtime);
149 unsigned int uid = 0; local
152 fs_config_func(dentries[i].path, dir, &uid, &gid, &mode);
154 dentries[i].uid = uid;
215 dentries[i].uid, dentries[i].gid,
H A Dcontents.c236 int inode_set_permissions(u32 inode_num, u16 mode, u16 uid, u16 gid, u32 mtime) argument
244 inode->i_uid = uid;
/system/core/cpio/
H A Dmkbootfs.c40 int uid, gid, mode; member in struct:fs_config_entry
45 /* Each line in the canned file should be a path plus three ints (uid,
59 // Use the list of file uid/gid/modes loaded from the file
69 s->st_uid = p->uid;
75 s->st_uid = empty_path_config->uid;
302 cc->uid = atoi(strtok(line, " \n"));
305 cc->uid = atoi(strtok(NULL, " \n"));
/system/core/toolbox/
H A Dtop.c57 uid_t uid; member in struct:proc_info
303 proc->uid = cur_proc.uid;
395 unsigned int uid, gid; local
400 sscanf(line, "Uid: %u", &uid);
404 proc->uid = uid; proc->gid = gid;
465 user = getpwuid(proc->uid);
470 snprintf(user_buf, 20, "%d", proc->uid);
H A Dls.c79 static void user2str(unsigned uid, char *out) argument
81 struct passwd *pw = getpwuid(uid);
85 sprintf(out, "%d", uid);
/system/extras/tests/iptables/qtaguid/
H A DsocketTag.cpp43 bool checkTag(uint64_t tag, uid_t uid);
124 * tag + uid. But it is not fool proof.
129 bool SockInfo::checkTag(uint64_t acct_tag, uid_t uid) { argument
154 asprintf(&match_template, "sock=%lx %s", addr, "tag=0x%llx (uid=%u)");
158 asprintf(&match_template, "%s", " tag=0x%llx (uid=%u)");
161 full_tag = acct_tag | uid;
163 asprintf(&buff, match_template, full_tag | uid, uid);
170 "sock=%lx tag=0x%llx (uid=%lu) pid=%u f_count=%lu",
172 if (!(res == 5 && k_tag == full_tag && k_uid == uid)) {
[all...]
/system/core/sdcard/
H A Dfuse.h98 __u32 uid; member in struct:fuse_attr
344 __u32 uid; member in struct:fuse_setattr_in
541 __u32 uid; member in struct:fuse_in_header
H A Dsdcard.c299 attr->uid = 0;
1242 ERROR("usage: sdcard [-t<threads>] <source_path> <dest_path> <uid> <gid>\n"
1248 static int run(const char* source_path, const char* dest_path, uid_t uid, gid_t gid, argument
1266 fd, uid, gid);
1280 res = setuid(uid);
1304 uid_t uid = 0; local
1317 else if (!uid) {
1320 uid = strtoul(arg, &endptr, 10);
1322 ERROR("Invalid uid");
1347 if (!uid || !gi
[all...]
/system/core/libsysutils/src/
H A DSocketClient.cpp41 mUid = creds.uid;

Completed in 227 milliseconds

12