| // Copyright 2015 The Weave 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 LIBWEAVE_SRC_PRIVET_AUTH_MANAGER_H_ |
| #define LIBWEAVE_SRC_PRIVET_AUTH_MANAGER_H_ |
| #include <base/time/time.h> |
| #include "src/privet/privet_types.h" |
| AuthManager(const std::vector<uint8_t>& secret, |
| const std::vector<uint8_t>& certificate_fingerprint); |
| std::vector<uint8_t> CreateAccessToken(const UserInfo& user_info, |
| UserInfo ParseAccessToken(const std::vector<uint8_t>& token, |
| const std::vector<uint8_t>& GetSecret() const { return secret_; } |
| const std::vector<uint8_t>& GetCertificateFingerprint() const { |
| return certificate_fingerprint_; |
| std::vector<uint8_t> secret_; |
| std::vector<uint8_t> certificate_fingerprint_; |
| DISALLOW_COPY_AND_ASSIGN(AuthManager); |
| #endif // LIBWEAVE_SRC_PRIVET_AUTH_MANAGER_H_ |