#include <grpc/support/port_platform.h>
#include <grpc/grpc.h>
#include "src/core/lib/iomgr/pollset_set.h"
#include "src/core/lib/security/credentials/alts/grpc_alts_credentials_options.h"
#include "src/core/tsi/alts/handshaker/alts_handshaker_client.h"
#include "src/core/tsi/transport_security.h"
#include "src/core/tsi/transport_security_interface.h"
#include "src/proto/grpc/gcp/altscontext.upb.h"
#include "src/proto/grpc/gcp/handshaker.upb.h"
Go to the source code of this file.
Macros | |
#define | TSI_ALTS_CERTIFICATE_TYPE "ALTS" |
#define | TSI_ALTS_CONTEXT "alts_context" |
#define | TSI_ALTS_RPC_VERSIONS "rpc_versions" |
#define | TSI_ALTS_SERVICE_ACCOUNT_PEER_PROPERTY "service_account" |
Typedefs | |
typedef struct alts_tsi_handshaker | alts_tsi_handshaker |
Functions | |
tsi_result | alts_tsi_handshaker_create (const grpc_alts_credentials_options *options, const char *target_name, const char *handshaker_service_url, bool is_client, grpc_pollset_set *interested_parties, tsi_handshaker **self, size_t user_specified_max_frame_size) |
bool | alts_tsi_handshaker_has_shutdown (alts_tsi_handshaker *handshaker) |
tsi_result | alts_tsi_handshaker_result_create (grpc_gcp_HandshakerResp *resp, bool is_client, tsi_handshaker_result **result) |
void | alts_tsi_handshaker_result_set_unused_bytes (tsi_handshaker_result *result, grpc_slice *recv_bytes, size_t bytes_consumed) |
Variables | |
const size_t | kTsiAltsMaxFrameSize = 1024 * 1024 |
const size_t | kTsiAltsMinFrameSize = 16 * 1024 |
const size_t | kTsiAltsNumOfPeerProperties = 5 |
#define TSI_ALTS_CERTIFICATE_TYPE "ALTS" |
Definition at line 35 of file alts_tsi_handshaker.h.
#define TSI_ALTS_CONTEXT "alts_context" |
Definition at line 37 of file alts_tsi_handshaker.h.
#define TSI_ALTS_RPC_VERSIONS "rpc_versions" |
Definition at line 36 of file alts_tsi_handshaker.h.
#define TSI_ALTS_SERVICE_ACCOUNT_PEER_PROPERTY "service_account" |
Definition at line 34 of file alts_tsi_handshaker.h.
typedef struct alts_tsi_handshaker alts_tsi_handshaker |
Definition at line 46 of file alts_tsi_handshaker.h.
tsi_result alts_tsi_handshaker_create | ( | const grpc_alts_credentials_options * | options, |
const char * | target_name, | ||
const char * | handshaker_service_url, | ||
bool | is_client, | ||
grpc_pollset_set * | interested_parties, | ||
tsi_handshaker ** | self, | ||
size_t | user_specified_max_frame_size | ||
) |
This method creates a ALTS TSI handshaker instance.
It returns TSI_OK on success and an error status code on failure. Note that if interested_parties is nullptr, a dedicated TSI thread will be created and used.
Definition at line 639 of file alts_tsi_handshaker.cc.
bool alts_tsi_handshaker_has_shutdown | ( | alts_tsi_handshaker * | handshaker | ) |
This method returns a boolean value indicating if an ALTS TSI handshaker has been shutdown or not.
Definition at line 633 of file alts_tsi_handshaker.cc.
tsi_result alts_tsi_handshaker_result_create | ( | grpc_gcp_HandshakerResp * | resp, |
bool | is_client, | ||
tsi_handshaker_result ** | result | ||
) |
This method creates an ALTS TSI handshaker result instance.
Definition at line 265 of file alts_tsi_handshaker.cc.
void alts_tsi_handshaker_result_set_unused_bytes | ( | tsi_handshaker_result * | result, |
grpc_slice * | recv_bytes, | ||
size_t | bytes_consumed | ||
) |
This method sets unused bytes of ALTS TSI handshaker result instance.
Definition at line 669 of file alts_tsi_handshaker.cc.
const size_t kTsiAltsMaxFrameSize = 1024 * 1024 |
Definition at line 44 of file alts_tsi_handshaker.h.
const size_t kTsiAltsMinFrameSize = 16 * 1024 |
Definition at line 43 of file alts_tsi_handshaker.h.
const size_t kTsiAltsNumOfPeerProperties = 5 |
Definition at line 39 of file alts_tsi_handshaker.h.