diff options
author | Yang Gao <yangg@google.com> | 2015-03-11 14:51:03 -0700 |
---|---|---|
committer | Yang Gao <yangg@google.com> | 2015-03-11 14:51:03 -0700 |
commit | 0535da306887779adb79f2adcf35910664532a99 (patch) | |
tree | d7d6f5afab443d97fd9d8713a8cfd06c60936c45 /include | |
parent | f859510340d0d13fce24d9c0e69455b6bd205337 (diff) |
The Jwt code was dropped somewhere in a merge. Put it back
Diffstat (limited to 'include')
-rw-r--r-- | include/grpc++/credentials.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/grpc++/credentials.h b/include/grpc++/credentials.h index c677cc3e0a..d480e0819a 100644 --- a/include/grpc++/credentials.h +++ b/include/grpc++/credentials.h @@ -105,6 +105,14 @@ std::unique_ptr<Credentials> ServiceAccountCredentials( const grpc::string& json_key, const grpc::string& scope, std::chrono::seconds token_lifetime); + // Builds JWT credentials. + // json_key is the JSON key string containing the client's private key. + // token_lifetime is the lifetime of each Json Web Token (JWT) created with + // this credentials. It should not exceed grpc_max_auth_token_lifetime or + // will be cropped to this value. +std::unique_ptr<Credentials> JWTCredentials( + const grpc::string& json_key, std::chrono::seconds token_lifetime); + // Builds IAM credentials. std::unique_ptr<Credentials> IAMCredentials( const grpc::string& authorization_token, |