Home
last modified time | relevance | path

Searched refs:peercred (Results 1 – 5 of 5) sorted by relevance

/external/strace/tests-m32/
Dso_peercred.c76 TAIL_ALLOC_OBJECT_CONST_PTR(struct ucred, peercred); in main()
79 const unsigned int sizeof_pid = sizeof(peercred->pid); in main()
103 *len = sizeof(*peercred); in main()
104 get_peercred(sv[0], peercred, len); in main()
106 PRINT_FIELD_D(", {", *peercred, pid); in main()
107 PRINT_FIELD_UID(", ", *peercred, uid); in main()
108 PRINT_FIELD_UID(", ", *peercred, gid); in main()
113 get_peercred(sv[0], peercred, len); in main()
115 sv[0], so_str(), peercred, errstr); in main()
118 *len = sizeof(*peercred) + 1; in main()
[all …]
/external/strace/tests/
Dso_peercred.c76 TAIL_ALLOC_OBJECT_CONST_PTR(struct ucred, peercred); in main()
79 const unsigned int sizeof_pid = sizeof(peercred->pid); in main()
103 *len = sizeof(*peercred); in main()
104 get_peercred(sv[0], peercred, len); in main()
106 PRINT_FIELD_D(", {", *peercred, pid); in main()
107 PRINT_FIELD_UID(", ", *peercred, uid); in main()
108 PRINT_FIELD_UID(", ", *peercred, gid); in main()
113 get_peercred(sv[0], peercred, len); in main()
115 sv[0], so_str(), peercred, errstr); in main()
118 *len = sizeof(*peercred) + 1; in main()
[all …]
/external/strace/tests-mx32/
Dso_peercred.c76 TAIL_ALLOC_OBJECT_CONST_PTR(struct ucred, peercred); in main()
79 const unsigned int sizeof_pid = sizeof(peercred->pid); in main()
103 *len = sizeof(*peercred); in main()
104 get_peercred(sv[0], peercred, len); in main()
106 PRINT_FIELD_D(", {", *peercred, pid); in main()
107 PRINT_FIELD_UID(", ", *peercred, uid); in main()
108 PRINT_FIELD_UID(", ", *peercred, gid); in main()
113 get_peercred(sv[0], peercred, len); in main()
115 sv[0], so_str(), peercred, errstr); in main()
118 *len = sizeof(*peercred) + 1; in main()
[all …]
/external/libcups/scheduler/
Dauth.c367 cupsd_ucred_t peercred; /* Peer credentials */ in cupsdAuthorize() local
370 peersize = sizeof(peercred); in cupsdAuthorize()
372 if (getsockopt(httpGetFd(con->http), 0, LOCAL_PEERCRED, &peercred, &peersize)) in cupsdAuthorize()
378 if ((pwd = getpwuid(CUPSD_UCRED_UID(peercred))) == NULL) in cupsdAuthorize()
380 …n, CUPSD_LOG_ERROR, "Unable to find UID %d for peer credentials.", (int)CUPSD_UCRED_UID(peercred)); in cupsdAuthorize()
401 cupsd_ucred_t peercred; /* Peer credentials */ in cupsdAuthorize() local
442 peersize = sizeof(peercred); in cupsdAuthorize()
445 if (getsockopt(httpGetFd(con->http), 0, LOCAL_PEERCRED, &peercred, &peersize)) in cupsdAuthorize()
447 if (getsockopt(httpGetFd(con->http), SOL_SOCKET, SO_PEERCRED, &peercred, &peersize)) in cupsdAuthorize()
454 if (pwd->pw_uid != CUPSD_UCRED_UID(peercred)) in cupsdAuthorize()
[all …]
/external/selinux/mcstrans/src/
Dmcstransd.c127 struct ucred peercred; in get_peer_pid() local
130 ret = getsockopt(fd, SOL_SOCKET, SO_PEERCRED, &peercred, &size); in get_peer_pid()
135 *pid = peercred.pid; in get_peer_pid()