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

Side by Side Diff: remoting/host/pam_authorization_factory_posix.cc

Issue 112353002: Move remoting::GetUsername() from remoting/base to remoting/host (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « remoting/base/util.cc ('k') | remoting/host/remoting_me2me_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "remoting/host/pam_authorization_factory_posix.h" 5 #include "remoting/host/pam_authorization_factory_posix.h"
6 6
7 #include <security/pam_appl.h> 7 #include <security/pam_appl.h>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
11 #include "base/environment.h" 11 #include "base/environment.h"
12 #include "remoting/base/logging.h" 12 #include "remoting/base/logging.h"
13 #include "remoting/base/util.h" 13 #include "remoting/host/username.h"
14 #include "remoting/protocol/channel_authenticator.h" 14 #include "remoting/protocol/channel_authenticator.h"
15 #include "third_party/libjingle/source/talk/xmllite/xmlelement.h" 15 #include "third_party/libjingle/source/talk/xmllite/xmlelement.h"
16 16
17 namespace remoting { 17 namespace remoting {
18 18
19 namespace { 19 namespace {
20 class PamAuthorizer : public protocol::Authenticator { 20 class PamAuthorizer : public protocol::Authenticator {
21 public: 21 public:
22 PamAuthorizer(scoped_ptr<protocol::Authenticator> underlying); 22 PamAuthorizer(scoped_ptr<protocol::Authenticator> underlying);
23 virtual ~PamAuthorizer(); 23 virtual ~PamAuthorizer();
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 const std::string& remote_jid, 165 const std::string& remote_jid,
166 const buzz::XmlElement* first_message) { 166 const buzz::XmlElement* first_message) {
167 scoped_ptr<protocol::Authenticator> authenticator( 167 scoped_ptr<protocol::Authenticator> authenticator(
168 underlying_->CreateAuthenticator(local_jid, remote_jid, first_message)); 168 underlying_->CreateAuthenticator(local_jid, remote_jid, first_message));
169 return scoped_ptr<protocol::Authenticator>( 169 return scoped_ptr<protocol::Authenticator>(
170 new PamAuthorizer(authenticator.Pass())); 170 new PamAuthorizer(authenticator.Pass()));
171 } 171 }
172 172
173 173
174 } // namespace remoting 174 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/base/util.cc ('k') | remoting/host/remoting_me2me_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698