19 #ifndef GRPC_CORE_TSI_TRANSPORT_SECURITY_INTERFACE_H
20 #define GRPC_CORE_TSI_TRANSPORT_SECURITY_INTERFACE_H
134 const unsigned char* unprotected_bytes,
135 size_t* unprotected_bytes_size,
136 unsigned char* protected_output_frames,
137 size_t* protected_output_frames_size);
149 size_t* protected_output_frames_size,
size_t* still_pending_size);
175 size_t* protected_frames_bytes_size,
unsigned char* unprotected_bytes,
176 size_t* unprotected_bytes_size);
186 #define TSI_CERTIFICATE_TYPE_PEER_PROPERTY "certificate_type"
351 unsigned char* bytes,
365 const unsigned char* bytes,
378 #define tsi_handshaker_is_in_progress(h) \
379 (tsi_handshaker_get_result((h)) == TSI_HANDSHAKE_IN_PROGRESS)
442 size_t received_bytes_size,
const unsigned char** bytes_to_send,
grpc_linked_mdelem status
Definition: lame_client.cc:44
Definition: transport_security.h:51
Definition: transport_security.h:109
Definition: transport_security.h:79
Definition: transport_security_interface.h:190
struct tsi_peer_property::@38 value
char * name
Definition: transport_security_interface.h:191
size_t length
Definition: transport_security_interface.h:194
char * data
Definition: transport_security_interface.h:193
Definition: transport_security_interface.h:198
tsi_peer_property * properties
Definition: transport_security_interface.h:199
size_t property_count
Definition: transport_security_interface.h:200
Definition: transport_security_grpc.h:76
void tsi_handshaker_result_destroy(tsi_handshaker_result *self)
Definition: transport_security.cc:261
void tsi_handshaker_shutdown(tsi_handshaker *self)
Definition: transport_security.cc:214
tsi_result tsi_handshaker_result_get_unused_bytes(const tsi_handshaker_result *self, const unsigned char **bytes, size_t *byte_size)
Definition: transport_security.cc:250
tsi_result tsi_handshaker_get_bytes_to_send_to_peer(tsi_handshaker *self, unsigned char *bytes, size_t *bytes_size)
Definition: transport_security.cc:131
void tsi_peer_destruct(tsi_peer *self)
Definition: transport_security.cc:293
tsi_result
Definition: transport_security_interface.h:31
@ TSI_HANDSHAKE_SHUTDOWN
Definition: transport_security_interface.h:46
@ TSI_INCOMPLETE_DATA
Definition: transport_security_interface.h:36
@ TSI_UNIMPLEMENTED
Definition: transport_security_interface.h:38
@ TSI_INVALID_ARGUMENT
Definition: transport_security_interface.h:34
@ TSI_UNKNOWN_ERROR
Definition: transport_security_interface.h:33
@ TSI_INTERNAL_ERROR
Definition: transport_security_interface.h:39
@ TSI_OK
Definition: transport_security_interface.h:32
@ TSI_OUT_OF_RESOURCES
Definition: transport_security_interface.h:44
@ TSI_PROTOCOL_FAILURE
Definition: transport_security_interface.h:42
@ TSI_ASYNC
Definition: transport_security_interface.h:45
@ TSI_NOT_FOUND
Definition: transport_security_interface.h:41
@ TSI_HANDSHAKE_IN_PROGRESS
Definition: transport_security_interface.h:43
@ TSI_DATA_CORRUPTED
Definition: transport_security_interface.h:40
@ TSI_FAILED_PRECONDITION
Definition: transport_security_interface.h:37
@ TSI_PERMISSION_DENIED
Definition: transport_security_interface.h:35
tsi_result tsi_handshaker_result_create_frame_protector(const tsi_handshaker_result *self, size_t *max_output_protected_frame_size, tsi_frame_protector **protector)
Definition: transport_security.cc:239
tsi_result tsi_handshaker_create_frame_protector(tsi_handshaker *self, size_t *max_output_protected_frame_size, tsi_frame_protector **protector)
Definition: transport_security.cc:181
tsi_result tsi_frame_protector_protect(tsi_frame_protector *self, const unsigned char *unprotected_bytes, size_t *unprotected_bytes_size, unsigned char *protected_output_frames, size_t *protected_output_frames_size)
Definition: transport_security.cc:74
tsi_result tsi_frame_protector_protect_flush(tsi_frame_protector *self, unsigned char *protected_output_frames, size_t *protected_output_frames_size, size_t *still_pending_size)
Definition: transport_security.cc:91
struct tsi_peer_property tsi_peer_property
void tsi_handshaker_destroy(tsi_handshaker *self)
Definition: transport_security.cc:222
const char * tsi_result_to_string(tsi_result result)
Definition: transport_security.cc:35
tsi_result tsi_handshaker_get_result(tsi_handshaker *self)
Definition: transport_security.cc:159
tsi_client_certificate_request_type
Definition: transport_security_interface.h:49
@ TSI_REQUEST_CLIENT_CERTIFICATE_BUT_DONT_VERIFY
Definition: transport_security_interface.h:52
@ TSI_DONT_REQUEST_CLIENT_CERTIFICATE
Definition: transport_security_interface.h:51
@ TSI_REQUEST_AND_REQUIRE_CLIENT_CERTIFICATE_AND_VERIFY
Definition: transport_security_interface.h:55
@ TSI_REQUEST_AND_REQUIRE_CLIENT_CERTIFICATE_BUT_DONT_VERIFY
Definition: transport_security_interface.h:54
@ TSI_REQUEST_CLIENT_CERTIFICATE_AND_VERIFY
Definition: transport_security_interface.h:53
tsi_result tsi_handshaker_extract_peer(tsi_handshaker *self, tsi_peer *peer)
Definition: transport_security.cc:167
void(* tsi_handshaker_on_next_done_cb)(tsi_result status, void *user_data, const unsigned char *bytes_to_send, size_t bytes_to_send_size, tsi_handshaker_result *handshaker_result)
Definition: transport_security_interface.h:417
tsi_result tsi_handshaker_process_bytes_from_peer(tsi_handshaker *self, const unsigned char *bytes, size_t *bytes_size)
Definition: transport_security.cc:145
void tsi_frame_protector_destroy(tsi_frame_protector *self)
Definition: transport_security.cc:122
grpc_core::TraceFlag tsi_tracing_enabled
tsi_result tsi_handshaker_next(tsi_handshaker *self, const unsigned char *received_bytes, size_t received_bytes_size, const unsigned char **bytes_to_send, size_t *bytes_to_send_size, tsi_handshaker_result **handshaker_result, tsi_handshaker_on_next_done_cb cb, void *user_data)
Definition: transport_security.cc:200
tsi_result tsi_frame_protector_unprotect(tsi_frame_protector *self, const unsigned char *protected_frames_bytes, size_t *protected_frames_bytes_size, unsigned char *unprotected_bytes, size_t *unprotected_bytes_size)
Definition: transport_security.cc:106
tsi_result tsi_handshaker_result_extract_peer(const tsi_handshaker_result *self, tsi_peer *peer)
Definition: transport_security.cc:229