diff options
author | Simo Sorce <simo@redhat.com> | 2012-06-01 14:26:41 -0400 |
---|---|---|
committer | Günther Deschner <gdeschner@redhat.com> | 2012-06-26 14:44:44 +0200 |
commit | 7ddab16ac7f36f0a2c1ce7cdd9e4ddfeb96d0932 (patch) | |
tree | cd11dacdb7d1b899bfd2048a2615dfa4556b12f5 | |
parent | e7bdf971f148b634b17f4b6c22d30ac99250dfc3 (diff) | |
download | gss-proxy-7ddab16ac7f36f0a2c1ce7cdd9e4ddfeb96d0932.tar.gz gss-proxy-7ddab16ac7f36f0a2c1ce7cdd9e4ddfeb96d0932.tar.xz gss-proxy-7ddab16ac7f36f0a2c1ce7cdd9e4ddfeb96d0932.zip |
Implement cred/context release mechglue wrappers
-rw-r--r-- | proxy/Makefile.am | 1 | ||||
-rw-r--r-- | proxy/src/mechglue/gpp_release_handle.c | 51 |
2 files changed, 52 insertions, 0 deletions
diff --git a/proxy/Makefile.am b/proxy/Makefile.am index 1d202e2..bc11fc0 100644 --- a/proxy/Makefile.am +++ b/proxy/Makefile.am @@ -101,6 +101,7 @@ GP_MECHGLUE_OBJ = \ src/mechglue/gpp_import_and_canon_name.c \ src/mechglue/gpp_indicate_mechs.c \ src/mechglue/gpp_init_sec_context.c \ + src/mechglue/gpp_release_handle.c \ src/mechglue/gss_plugin.c dist_noinst_HEADERS = diff --git a/proxy/src/mechglue/gpp_release_handle.c b/proxy/src/mechglue/gpp_release_handle.c new file mode 100644 index 0000000..bff80c5 --- /dev/null +++ b/proxy/src/mechglue/gpp_release_handle.c @@ -0,0 +1,51 @@ +/* + GSS-PROXY + + Copyright (C) 2012 Red Hat, Inc. + Copyright (C) 2012 Simo Sorce <simo.sorce@redhat.com> + + Permission is hereby granted, free of charge, to any person obtaining a + copy of this software and associated documentation files (the "Software"), + to deal in the Software without restriction, including without limitation + the rights to use, copy, modify, merge, publish, distribute, sublicense, + and/or sell copies of the Software, and to permit persons to whom the + Software is furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING + FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER + DEALINGS IN THE SOFTWARE. +*/ + +#include "gss_plugin.h" + +OM_uint32 gssi_release_cred(OM_uint32 *minor_status, + gss_cred_id_t *cred_handle) +{ + OM_uint32 maj, min; + + maj = gpm_release_cred(&min, cred_handle); + + *minor_status = gpm_map_error(min); + return maj; +} + +OM_uint32 gssi_delete_sec_context(OM_uint32 *minor_status, + gss_ctx_id_t *context_handle, + gss_buffer_t output_token) +{ + OM_uint32 maj, min; + + maj = gpm_delete_sec_context(&min, + context_handle, + output_token); + + *minor_status = gpm_map_error(min); + return maj; +} |