15#ifndef GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_STORAGE_OAUTH2_CREDENTIALS_H
16#define GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_STORAGE_OAUTH2_CREDENTIALS_H
18#include "google/cloud/storage/signed_url_options.h"
19#include "google/cloud/storage/version.h"
20#include "google/cloud/status.h"
21#include "google/cloud/status_or.h"
28GOOGLE_CLOUD_CPP_INLINE_NAMESPACE_BEGIN
30
31
32
33
37
38
39
40
41
42
43
44
45
46
52
53
54
55
56
57
58
59
60
61
65
66
67
68
69
70
71
72
73
76 std::string
const& string_to_sign)
const;
79
80
81
82
83 virtual std::string
AccountEmail()
const {
return std::string{}; }
86
87
88
89
90 virtual std::string
KeyId()
const {
return std::string{}; }
94GOOGLE_CLOUD_CPP_INLINE_NAMESPACE_END
Interface for OAuth 2.0 credentials used to access Google Cloud services.
Definition: credentials.h:47
virtual std::string KeyId() const
Return the account's key_id associated with these credentials, if any.
Definition: credentials.h:90
virtual StatusOr< std::string > AuthorizationHeader()=0
Attempts to obtain a value for the Authorization HTTP header.
virtual std::string AccountEmail() const
Return the account's email associated with these credentials, if any.
Definition: credentials.h:83
virtual ~Credentials()=default
virtual StatusOr< std::vector< std::uint8_t > > SignBlob(SigningAccount const &service_account, std::string const &string_to_sign) const
Try to sign string_to_sign using service_account.
Authentication components for Google Cloud Storage.
Definition: anonymous_credentials.h:26
Contains all the Google Cloud Storage C++ client APIs.
Definition: auto_finalize.h:24
Specify the service account used to sign a blob.
Definition: signed_url_options.h:186