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

Unified Diff: remoting/host/gnubby_auth_handler_posix.cc

Issue 382143005: Supports DevTools socket access authentication based on Android permissions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Commented process_id Created 6 years, 4 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
« no previous file with comments | « net/socket/unix_domain_server_socket_posix_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/gnubby_auth_handler_posix.cc
diff --git a/remoting/host/gnubby_auth_handler_posix.cc b/remoting/host/gnubby_auth_handler_posix.cc
index f5673d33dd0efe035c92a164048905de36cb5b6f..04afc74347b572c8cb38b2d87fd670527bc83b26 100644
--- a/remoting/host/gnubby_auth_handler_posix.cc
+++ b/remoting/host/gnubby_auth_handler_posix.cc
@@ -53,10 +53,10 @@ class CompareSocket {
// Socket authentication function that only allows connections from callers with
// the current uid.
-bool MatchUid(uid_t user_id, gid_t) {
- bool allowed = user_id == getuid();
+bool MatchUid(const net::UnixDomainServerSocket::Credentials& credentials) {
+ bool allowed = credentials.user_id == getuid();
if (!allowed)
- HOST_LOG << "Refused socket connection from uid " << user_id;
+ HOST_LOG << "Refused socket connection from uid " << credentials.user_id;
return allowed;
}
« no previous file with comments | « net/socket/unix_domain_server_socket_posix_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698