Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
Grpc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tci-gateway-module
Grpc
Commits
7264f14b
Commit
7264f14b
authored
8 years ago
by
Craig Tiller
Browse files
Options
Downloads
Patches
Plain Diff
Cleanup spam
parent
bc4c3e3a
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/core/lib/security/transport/handshake.c
+0
-23
0 additions, 23 deletions
src/core/lib/security/transport/handshake.c
with
0 additions
and
23 deletions
src/core/lib/security/transport/handshake.c
+
0
−
23
View file @
7264f14b
...
...
@@ -66,17 +66,6 @@ typedef struct {
gpr_refcount
refs
;
}
grpc_security_handshake
;
static
void
dump_state
(
const
char
*
state
,
grpc_security_handshake
*
h
,
grpc_error
*
error
)
{
gpr_timespec
ttl
=
gpr_time_sub
(
h
->
timer
.
deadline
,
gpr_now
(
h
->
timer
.
deadline
.
clock_type
));
const
char
*
msg
=
grpc_error_string
(
error
);
gpr_log
(
GPR_DEBUG
,
"%p: %s ttl=%"
PRId64
".%09d err=%s"
,
h
,
state
,
ttl
.
tv_sec
,
ttl
.
tv_nsec
,
msg
);
grpc_error_free_string
(
msg
);
GRPC_ERROR_UNREF
(
error
);
}
static
void
on_handshake_data_received_from_peer
(
grpc_exec_ctx
*
exec_ctx
,
void
*
setup
,
grpc_error
*
error
);
...
...
@@ -127,7 +116,6 @@ static void unref_handshake(grpc_security_handshake *h) {
static
void
security_handshake_done
(
grpc_exec_ctx
*
exec_ctx
,
grpc_security_handshake
*
h
,
grpc_error
*
error
)
{
dump_state
(
"done"
,
h
,
GRPC_ERROR_REF
(
error
));
grpc_timer_cancel
(
exec_ctx
,
&
h
->
timer
);
if
(
!
h
->
is_client_side
)
{
security_connector_remove_handshake
(
h
);
...
...
@@ -156,9 +144,6 @@ static void on_peer_checked(grpc_exec_ctx *exec_ctx, void *user_data,
grpc_security_status
status
,
grpc_auth_context
*
auth_context
)
{
grpc_security_handshake
*
h
=
user_data
;
dump_state
(
"on_peer_checked"
,
h
,
grpc_error_set_int
(
GRPC_ERROR_CREATE
(
"on_peer_checked"
),
GRPC_ERROR_INT_SECURITY_STATUS
,
status
));
tsi_frame_protector
*
protector
;
tsi_result
result
;
if
(
status
!=
GRPC_SECURITY_OK
)
{
...
...
@@ -191,9 +176,6 @@ static void check_peer(grpc_exec_ctx *exec_ctx, grpc_security_handshake *h) {
tsi_peer
peer
;
tsi_result
result
=
tsi_handshaker_extract_peer
(
h
->
handshaker
,
&
peer
);
dump_state
(
"check_peer"
,
h
,
grpc_set_tsi_error_result
(
GRPC_ERROR_CREATE
(
"peer_extraction"
),
result
));
if
(
result
!=
TSI_OK
)
{
security_handshake_done
(
exec_ctx
,
h
,
grpc_set_tsi_error_result
(
...
...
@@ -210,7 +192,6 @@ static void send_handshake_bytes_to_peer(grpc_exec_ctx *exec_ctx,
tsi_result
result
=
TSI_OK
;
gpr_slice
to_send
;
dump_state
(
"send_handshake_bytes_to_peer"
,
h
,
GRPC_ERROR_NONE
);
do
{
size_t
to_send_size
=
h
->
handshake_buffer_size
-
offset
;
result
=
tsi_handshaker_get_bytes_to_send_to_peer
(
...
...
@@ -250,7 +231,6 @@ static void on_handshake_data_received_from_peer(grpc_exec_ctx *exec_ctx,
size_t
num_left_overs
;
int
has_left_overs_in_current_slice
=
0
;
dump_state
(
"on_handshake_data_received_from_peer"
,
h
,
GRPC_ERROR_REF
(
error
));
if
(
error
!=
GRPC_ERROR_NONE
)
{
security_handshake_done
(
exec_ctx
,
h
,
...
...
@@ -314,7 +294,6 @@ static void on_handshake_data_sent_to_peer(grpc_exec_ctx *exec_ctx,
void
*
handshake
,
grpc_error
*
error
)
{
grpc_security_handshake
*
h
=
handshake
;
dump_state
(
"on_handshake_data_sent_to_peer"
,
h
,
GRPC_ERROR_REF
(
error
));
/* Make sure that write is OK. */
if
(
error
!=
GRPC_ERROR_NONE
)
{
if
(
handshake
!=
NULL
)
...
...
@@ -337,7 +316,6 @@ static void on_handshake_data_sent_to_peer(grpc_exec_ctx *exec_ctx,
static
void
on_timeout
(
grpc_exec_ctx
*
exec_ctx
,
void
*
arg
,
grpc_error
*
error
)
{
grpc_security_handshake
*
h
=
arg
;
dump_state
(
"on_timeout"
,
h
,
GRPC_ERROR_REF
(
error
));
if
(
error
==
GRPC_ERROR_NONE
)
{
grpc_endpoint_shutdown
(
exec_ctx
,
h
->
wrapped_endpoint
);
}
...
...
@@ -368,7 +346,6 @@ void grpc_do_security_handshake(
gpr_slice_buffer_init
(
&
h
->
left_overs
);
gpr_slice_buffer_init
(
&
h
->
outgoing
);
gpr_slice_buffer_init
(
&
h
->
incoming
);
dump_state
(
"grpc_do_security_handshake"
,
h
,
GRPC_ERROR_NONE
);
if
(
!
is_client_side
)
{
grpc_server_security_connector
*
server_connector
=
(
grpc_server_security_connector
*
)
connector
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment