Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1814)

Unified Diff: net/socket/unix_domain_server_socket_posix.h

Issue 382143005: Supports DevTools socket access authentication based on Android permissions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merged Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/socket/unix_domain_server_socket_posix.h
diff --git a/net/socket/unix_domain_server_socket_posix.h b/net/socket/unix_domain_server_socket_posix.h
index 06fb8d32c47bc4b0e700fa70f51d3f2ab80aa36d..b76280aa96af21307aff79916b821004b75b4d8d 100644
--- a/net/socket/unix_domain_server_socket_posix.h
+++ b/net/socket/unix_domain_server_socket_posix.h
@@ -26,10 +26,11 @@ class SocketLibevent;
class NET_EXPORT UnixDomainServerSocket : public ServerSocket {
public:
// Callback that returns whether the already connected client, identified by
- // its process |user_id| and |group_id|, is allowed to keep the connection
- // open. Note that the socket is closed immediately in case the callback
- // returns false.
- typedef base::Callback<bool (uid_t user_id, gid_t group_id)> AuthCallback;
+ // its |process_id|, |user_id| and |group_id|, is allowed to keep
+ // the connection open. Note that the socket is closed immediately in case
+ // the callback returns false.
+ typedef base::Callback<
+ bool (pid_t process_id, uid_t user_id, gid_t group_id)> AuthCallback;
UnixDomainServerSocket(const AuthCallback& auth_callack,
bool use_abstract_namespace);
@@ -37,6 +38,7 @@ class NET_EXPORT UnixDomainServerSocket : public ServerSocket {
// Gets UID and GID of peer to check permissions.
static bool GetPeerIds(SocketDescriptor socket_fd,
+ pid_t* process_id,
uid_t* user_id,
gid_t* group_id);

Powered by Google App Engine
This is Rietveld 408576698