Chromium Code Reviews| Index: remoting/host/pam_authorization_factory_posix.h |
| diff --git a/remoting/host/pam_authorization_factory_posix.h b/remoting/host/pam_authorization_factory_posix.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..eb9ab5f93f5508c3fc0406bdc5846c4265612ec9 |
| --- /dev/null |
| +++ b/remoting/host/pam_authorization_factory_posix.h |
| @@ -0,0 +1,32 @@ |
| +// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef REMOTING_HOST_PAM_AUTHORIZATION_FACTORY_POSIX_H_ |
| +#define REMOTING_HOST_PAM_AUTHORIZATION_FACTORY_POSIX_H_ |
| + |
| +#include "remoting/protocol/authenticator.h" |
|
Wez
2012/10/26 03:25:43
nit: Blank line between this include and the next.
Jamie
2012/10/26 17:53:30
Done.
|
| +#include "base/memory/scoped_ptr.h" |
| + |
| +// PamAuthorizationFactory abuses the AuthenticatorFactory interface to apply |
| +// PAM-based authorization on top of some underlying authentication scheme. |
| + |
| +namespace remoting { |
| + |
| +class PamAuthorizationFactory : public protocol::AuthenticatorFactory { |
| + public: |
| + PamAuthorizationFactory( |
| + scoped_ptr<protocol::AuthenticatorFactory> underlying); |
| + |
| + virtual scoped_ptr<protocol::Authenticator> CreateAuthenticator( |
| + const std::string& local_jid, |
| + const std::string& remote_jid, |
| + const buzz::XmlElement* first_message) OVERRIDE; |
| + |
| + private: |
| + scoped_ptr<protocol::AuthenticatorFactory> underlying_; |
| +}; |
| + |
| +} // namespace remoting |
| + |
| +#endif |