diff options
author | Günther Deschner <gdeschner@redhat.com> | 2012-08-29 17:24:48 +0200 |
---|---|---|
committer | Simo Sorce <simo@redhat.com> | 2012-09-14 16:14:15 -0400 |
commit | a782177affad270b965fb483b6ed2e1b41aa4209 (patch) | |
tree | b04e02455c60115761a2cb825724c1528e19cb96 /proxy/tests | |
parent | 8e699123bc7d4b5dd2b085567d64f8f46ee456ae (diff) | |
download | gss-proxy-a782177affad270b965fb483b6ed2e1b41aa4209.tar.gz gss-proxy-a782177affad270b965fb483b6ed2e1b41aa4209.tar.xz gss-proxy-a782177affad270b965fb483b6ed2e1b41aa4209.zip |
Add testcode for gpm_wrap_size_limit().
Diffstat (limited to 'proxy/tests')
-rw-r--r-- | proxy/tests/cli_srv_comm.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/proxy/tests/cli_srv_comm.c b/proxy/tests/cli_srv_comm.c index 0e527cc..4094340 100644 --- a/proxy/tests/cli_srv_comm.c +++ b/proxy/tests/cli_srv_comm.c @@ -210,6 +210,7 @@ void *client_thread(void *pvt) int ret = 0; gss_buffer_desc msg_buf = GSS_C_EMPTY_BUFFER; int conf_state; + uint32_t max_size; data = (struct athread *)pvt; @@ -323,6 +324,18 @@ void *client_thread(void *pvt) goto done; } + ret_maj = gpm_wrap_size_limit(&ret_min, + (gssx_ctx *)ctx, + 1, /* conf_req */ + GSS_C_QOP_DEFAULT, /* qop_req */ + 4096, /* size_req */ + &max_size); + if (ret_maj) { + fprintf(stderr, "gpm_wrap_size_limit failed: %d\n", ret_maj); + gp_log_failure(GSS_C_NO_OID, ret_maj, ret_min); + goto done; + } + fprintf(stdout, "client: Success!\n"); done: |