import gssproxy-0.8.0-21.el8

This commit is contained in:
CentOS Sources 2022-09-27 16:16:01 -04:00 committed by Stepan Oksanichenko
parent d1aa4b7122
commit 7ceece72cf
2 changed files with 47 additions and 1 deletions

View File

@ -0,0 +1,41 @@
From 255188b5e3cfc3be5aebd037389bcf7da686a622 Mon Sep 17 00:00:00 2001
From: Simo Sorce <simo@redhat.com>
Date: Tue, 7 Apr 2020 08:56:53 -0400
Subject: [PATCH] Fix handling of selinux context when NULL
Fixes: #256
Signed-off-by: Simo Sorce <simo@redhat.com>
Merges: #257
Reviewed-by: Robbie Harwood <rharwood@redhat.com>
---
src/gp_socket.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/src/gp_socket.c b/src/gp_socket.c
index 7a19ee5..9070928 100644
--- a/src/gp_socket.c
+++ b/src/gp_socket.c
@@ -122,7 +122,9 @@ void gp_conn_free(struct gp_conn *conn)
close(conn->us.sd);
}
free(conn->program);
- SELINUX_context_free(conn->selinux_ctx);
+ if (conn->selinux_ctx) {
+ SELINUX_context_free(conn->selinux_ctx);
+ }
free(conn);
}
@@ -635,7 +637,8 @@ void accept_sock_conn(verto_ctx *vctx, verto_ev *ev)
conn->creds.ucred.uid,
conn->creds.ucred.gid);
}
- if (conn->creds.type & CRED_TYPE_SELINUX) {
+ if ((conn->creds.type & CRED_TYPE_SELINUX) &&
+ (conn->selinux_ctx != NULL)) {
GPDEBUG(" (context = %s)",
SELINUX_context_str(conn->selinux_ctx));
}
--
2.35.3

View File

@ -1,7 +1,7 @@
Name: gssproxy
Version: 0.8.0
Release: 20%{?dist}
Release: 21%{?dist}
Summary: GSSAPI Proxy
Group: System Environment/Libraries
@ -43,6 +43,7 @@ Patch26: Return-static-oids-for-naming-functions.patch
Patch27: Avoid-unnecessary-allocation-in-gpm_inquire_mechs_fo.patch
Patch28: Use-static-OIDs-in-gss_inquire_context.patch
Patch29: Add-an-option-for-minimum-lifetime.patch
Patch30: Fix-handling-of-selinux-context-when-NULL.patch
### Dependencies ###
Requires: krb5-libs >= 1.12.0
@ -137,6 +138,10 @@ mkdir -p %{buildroot}%{gpstatedir}/rcache
%systemd_postun_with_restart gssproxy.service
%changelog
* Mon Jul 04 2022 Julien Rische <jrische@redhat.com> - 0.8.0-21
- Fix handling of selinux context when NULL
- Resolves: rhbz#2061061
* Wed Nov 17 2021 Antonio Torres <antorres@redhat.com> - 0.8.0-20
- Add an option for minimum lifetime
- Resolves: #1721331