3
0
forked from pool/libselinux

Accepting request 1067536 from home:jsegitz:branches:security:SELinux_toolchain

- Update to version 3.5:
  * check for truncations
  * avoid newline in avc message
  * bail out on path truncations
  * add getpidprevcon to gather the previous context before the last
    exec of a given process
  * Workaround for heap overhead of pcre
  * fix memory leaks on the audit2why module init
  * ignore invalid class name lookup
- Drop restorecon_pin_file.patch, is upstream
- Added additional developer key (Jason Zaman)

- Update to version 3.5:
  * check for truncations
  * avoid newline in avc message
  * bail out on path truncations
  * add getpidprevcon to gather the previous context before the last
    exec of a given process
  * Workaround for heap overhead of pcre
  * fix memory leaks on the audit2why module init
  * ignore invalid class name lookup
- Drop restorecon_pin_file.patch, is upstream
- Added additional developer key (Jason Zaman)

OBS-URL: https://build.opensuse.org/request/show/1067536
OBS-URL: https://build.opensuse.org/package/show/security:SELinux/libselinux?expand=0&rev=145
This commit is contained in:
Johannes Segitz 2023-02-24 08:43:11 +00:00 committed by Git OBS Bridge
parent e9ab567ff0
commit 5bc0b87998
10 changed files with 195 additions and 167 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:77c294a927e6795c2e98f74b5c3adde9c8839690e9255b767c5fca6acff9b779
size 210061

View File

@ -1,16 +0,0 @@
-----BEGIN PGP SIGNATURE-----
iQIzBAABCAAdFiEE1qW2HJpVNBaCkttnviIJHj72InUFAmKFCEsACgkQviIJHj72
InXlLhAAtklDK8OvcL08fYu8Hw2EYI6wWopn4KctGiZN0axNRxLTqzljWJCU2MjM
jqRDqQ4M1i+Bp4NKDKxYLJSMq8gABoC3L9pvM5Tm24Lw9R/A85FcBtTAr7fSevd1
hu42yDrjZI1pdAY1kSATipo57JiL4O8WA4qJdNGxJepsMNG49dFSezhO2VyBj4Tl
IVG4smxF/5PEPGVJfjH0dorYarRtsXVVQxrzT739x/9jE8YBe0ONbGrnzxL6ga5G
dlAMEyRyHTn1sLBp6mxi3KxvkgkLZ8hFH28JeQ+8zyOs/FjCQOSk/akOewsLOUMV
S/f4ydgaPHSjmN+etv03P1iOPWxiH8DdIez/GA7DRrwY80xfbIfO5M51fNKIBzXM
M2Co24kGHyaythzzFgwClw41SLB3SGkHPQcb0Hm1uFeSVCdIPUCwCWmQcFABZaZ0
SHDC47zZ0E22A4y33tT0/SbYtqEJLPfVCBYGWK+wRnKzGMTdUYzVoW4tr9p+yDhQ
SN0+m84Ryz8cfYWuE3WB53V4z0Pk5alk43XkmtHXNRgI2hGjXs1Q3UxEdB/YEpun
tGh6oA4oMj4brPWXb6PE/egpvYJzW6k6Z1JHAIY8Sj2zx5LtJgf5yfiX3iI9kfSf
2iF9s6Y+eNgTceKkQ55PIOI0NhcArMQxwIlBZb63xsrYqTTA+xw=
=Oane
-----END PGP SIGNATURE-----

BIN
libselinux-3.5.tar.gz (Stored with Git LFS) Normal file

Binary file not shown.

19
libselinux-3.5.tar.gz.asc Normal file
View File

@ -0,0 +1,19 @@
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQKTBAABCgB9FiEE4WLerRzN0RPwSz1JK77Zyxpo71UFAmP3a11fFIAAAAAALgAo
aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldEUx
NjJERUFEMUNDREQxMTNGMDRCM0Q0OTJCQkVEOUNCMUE2OEVGNTUACgkQK77Zyxpo
71Uajg//WGv3IopVYrtph3FgRUU5V+QGwvd0rdsL/+ZhNGYKi/Br1Pqdi8nHzg4j
jXX9B6uek1A9S1WC76uEtoG0pqc3KNXxAgZAVGpJBp29QCXftWbmMEu5obN+cST8
H1HaCm0MUdMB01Yyc8pNSujV7AezsKv60cxLNITdYXGjEFDIM73oYxc61qNrYbpm
dQabXqnGxp0FkzbRbO0JsOiwIMJuLBZEe7UyHPlF6Z9OemDe3ro5YbtyUJrzHIjO
nIyWZ8ApWXZ6Q8vJyk9RGBO1fNiAHlH5UCELK1Mj4vDMNkSmrOUkoz0DWJ8+vnkf
Bb7wC7STzWMXTb8R/Zx0GuQ/3VsM5Y9ebYFz2XV3Brttxrp4WAKZjwXduDOHOSLX
EOMM3/c20z3LYAl6aAvo36DQSYJ7zAm6qF1ZF5JmH0DYBSZevXMRF14x0EZLchgS
TSIzfFlIT7SYlxIGZX54hwN9FQidhlK//onHE16Ri/GyOSJa8/uUhntrJb0lgoh+
5FllC+dgXuLMNpCE7ltqWFHgMLsEaKBi4Z6mOONL54iYJUUzfHHjXoi+cLRO6eUU
9zQhQfQ7+HANcQt691EUBo0efiNT1upI4H4C6CFojobMX4pVUsKouMfjAg8Jl/is
Z63fXRJWBGS6NGR7ZxodV6wF5OzVMH4IDO6Rdf5X6Apcinshs8U=
=NKC3
-----END PGP SIGNATURE-----

View File

@ -1,3 +1,18 @@
-------------------------------------------------------------------
Fri Feb 24 07:42:25 UTC 2023 - Johannes Segitz <jsegitz@suse.com>
- Update to version 3.5:
* check for truncations
* avoid newline in avc message
* bail out on path truncations
* add getpidprevcon to gather the previous context before the last
exec of a given process
* Workaround for heap overhead of pcre
* fix memory leaks on the audit2why module init
* ignore invalid class name lookup
- Drop restorecon_pin_file.patch, is upstream
- Added additional developer key (Jason Zaman)
-------------------------------------------------------------------
Mon May 9 10:23:32 UTC 2022 - Johannes Segitz <jsegitz@suse.com>

View File

@ -1,7 +1,7 @@
#
# spec file for package libselinux-bindings
#
# Copyright (c) 2022 SUSE LLC
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -17,9 +17,9 @@
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define libsepol_ver 3.4
%define libsepol_ver 3.5
Name: libselinux-bindings
Version: 3.4
Version: 3.5
Release: 0
Summary: SELinux runtime library and simple utilities
License: SUSE-Public-Domain
@ -36,7 +36,6 @@ Patch4: readv-proto.patch
# Make linking working even when default pkg-config doesnt provide -lpython<ver>
Patch5: python3.8-compat.patch
Patch6: swig4_moduleimport.patch
Patch7: restorecon_pin_file.patch
BuildRequires: libsepol-devel-static >= %{libsepol_ver}
BuildRequires: python-rpm-macros
BuildRequires: python3-devel

View File

@ -1,3 +1,18 @@
-------------------------------------------------------------------
Fri Feb 24 07:42:25 UTC 2023 - Johannes Segitz <jsegitz@suse.com>
- Update to version 3.5:
* check for truncations
* avoid newline in avc message
* bail out on path truncations
* add getpidprevcon to gather the previous context before the last
exec of a given process
* Workaround for heap overhead of pcre
* fix memory leaks on the audit2why module init
* ignore invalid class name lookup
- Drop restorecon_pin_file.patch, is upstream
- Added additional developer key (Jason Zaman)
-------------------------------------------------------------------
Thu Jul 7 12:16:45 UTC 2022 - Johannes Segitz <jsegitz@suse.com>

View File

@ -167,3 +167,139 @@ et3lz04U61v8ajHBqX/pRfPtrraNnvAM2knD3E58Lf95f/nr7p0tV59EWP8s4i72
t4zhuhOJjZ2YaPVALQ==
=UVQc
-----END PGP PUBLIC KEY BLOCK-----
-----BEGIN PGP PUBLIC KEY BLOCK-----
mQINBFMyh7gBEADHbVdNWxivgqISiinIAE7gOl9vFemvnqfzn7hdfw2y02hUzojd
0HzEJsyqxGBYHpdNYoiLbCYNubMDA/Xd0Att2D7fIAuNFo3gnKEm27xLSzjC02bk
h2Pxp9d92dxPXsk+zDvY74Vwem74Yon824ESurH4gTK/HsiX2Y+7+5z3Ep07xC7p
IA0RzD3zlKhfT9dpS0QR2LP1utFcT40eEjSZY8QK3iKapNtyvIrpKpkWx0tZTWwX
+F8IoL9MzJBi5L/pS8fyUOkyBVIwdRXLNuX+sle+llH7i+6DWsWHEphiZ3ObiXDm
iXKBu/I0useEE4K7TmOLqqeEZl+CTU6YWJLPpD38pq+p64TlAcT7rZSmRUr7zY0a
X1gsXqm7e95Txm6UYy3Xth1jmZ0PuHjCBIvy8foxZVKGsR34ntAYcZzZhDca+J2S
WyL/YcQbSFhad1N1ZpCXj4eYGQIg57b1OLrabopdSQ73s8uGdS12aNQKcehkAvKs
Pab45Qxk7PWGNXuvHGYFCvedl8Gh/MUy3UqlXE58GBob9ldB+7eaO5VgR0GydSF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r4LI9iN28wKmSxTOvCHN+QaQZ5adlDquhGwFm8TRRsm1
FDsVcmrjPTcGUsKfIAOyeiSHZO2tMU/CTvEYRNw09geVeOvIwNSXS8oblC1b3P1j
UP67CKVAYBnBFx7bMujlGyNJY8jGNEEBrDqxfYEAIEhyKNd0tWc86B1tqz/ArRvc
XfPof/cQcFVHpfpJ/NS+b4KrRvJHzV884N709JmrFZVVAR/2I/GmZ0wdCmBoZtH8
+IpwyMey0HIfa5dOtZw6jAAB5mkCBEs/P7VPrwzTpXcPBKFfj1R/iqpT7YvNk8Gh
l4xDVhZI8IpQ7j1RtJoULvAwmH0z/M5kS2N0ADxEo3mPgm1CaFudP4JijV3HX7Rx
IuOUseqwzF197kqA16in1P25
=f80i
-----END PGP PUBLIC KEY BLOCK-----

View File

@ -1,7 +1,7 @@
#
# spec file for package libselinux
#
# Copyright (c) 2022 SUSE LLC
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -16,9 +16,9 @@
#
%define libsepol_ver 3.4
%define libsepol_ver 3.5
Name: libselinux
Version: 3.4
Version: 3.5
Release: 0
Summary: SELinux runtime library and utilities
License: SUSE-Public-Domain
@ -32,7 +32,6 @@ Source4: baselibs.conf
# PATCH-FIX-UPSTREAM Include <sys/uio.h> for readv prototype
Patch4: readv-proto.patch
Patch5: skip_cycles.patch
Patch7: restorecon_pin_file.patch
BuildRequires: fdupes
BuildRequires: libsepol-devel >= %{libsepol_ver}
BuildRequires: pkgconfig
@ -102,7 +101,6 @@ necessary to develop your own software using libselinux.
%setup -q -n libselinux-%{version}
%patch4 -p1
%patch5 -p1
%patch7 -p1
%build
%define _lto_cflags %{nil}
@ -150,6 +148,7 @@ install -m 0755 %{SOURCE3} %{buildroot}%{_sbindir}/selinux-ready
%{_sbindir}/selinux_check_securetty_context
%{_sbindir}/selabel_get_digests_all_partial_matches
%{_sbindir}/validatetrans
%{_sbindir}/getpidprevcon
%{_mandir}/man5/*
%{_mandir}/ru/man5/*
%{_mandir}/man8/*

View File

@ -1,139 +0,0 @@
Index: libselinux-3.4/src/selinux_restorecon.c
===================================================================
--- libselinux-3.4.orig/src/selinux_restorecon.c
+++ libselinux-3.4/src/selinux_restorecon.c
@@ -623,13 +623,13 @@ out:
return rc;
}
-static int restorecon_sb(const char *pathname, struct rest_flags *flags, bool first)
+static int restorecon_sb(const char *pathname, const struct stat *sb,
+ struct rest_flags *flags, bool first)
{
char *newcon = NULL;
char *curcon = NULL;
char *newtypecon = NULL;
- int fd = -1, rc;
- struct stat stat_buf;
+ int rc;
bool updated = false;
const char *lookup_path = pathname;
float pc;
@@ -644,21 +644,13 @@ static int restorecon_sb(const char *pat
lookup_path += rootpathlen;
}
- fd = open(pathname, O_PATH | O_NOFOLLOW | O_EXCL);
- if (fd < 0)
- goto err;
-
- rc = fstat(fd, &stat_buf);
- if (rc < 0)
- goto err;
-
if (rootpath != NULL && lookup_path[0] == '\0')
/* this is actually the root dir of the alt root. */
rc = selabel_lookup_raw(fc_sehandle, &newcon, "/",
- stat_buf.st_mode);
+ sb->st_mode);
else
rc = selabel_lookup_raw(fc_sehandle, &newcon, lookup_path,
- stat_buf.st_mode);
+ sb->st_mode);
if (rc < 0) {
if (errno == ENOENT) {
@@ -667,10 +659,10 @@ static int restorecon_sb(const char *pat
"Warning no default label for %s\n",
lookup_path);
- goto out; /* no match, but not an error */
+ return 0; /* no match, but not an error */
}
- goto err;
+ return -1;
}
if (flags->progress) {
@@ -690,17 +682,19 @@ static int restorecon_sb(const char *pat
}
if (flags->add_assoc) {
- rc = filespec_add(stat_buf.st_ino, newcon, pathname, flags);
+ rc = filespec_add(sb->st_ino, newcon, pathname, flags);
if (rc < 0) {
selinux_log(SELINUX_ERROR,
"filespec_add error: %s\n", pathname);
- goto out1;
+ freecon(newcon);
+ return -1;
}
if (rc > 0) {
/* Already an association and it took precedence. */
- goto out;
+ freecon(newcon);
+ return 0;
}
}
@@ -708,7 +702,7 @@ static int restorecon_sb(const char *pat
selinux_log(SELINUX_INFO, "%s matched by %s\n",
pathname, newcon);
- if (fgetfilecon_raw(fd, &curcon) < 0) {
+ if (lgetfilecon_raw(pathname, &curcon) < 0) {
if (errno != ENODATA)
goto err;
@@ -741,7 +735,7 @@ static int restorecon_sb(const char *pat
}
if (!flags->nochange) {
- if (fsetfilecon(fd, newcon) < 0)
+ if (lsetfilecon(pathname, newcon) < 0)
goto err;
updated = true;
}
@@ -766,8 +760,6 @@ static int restorecon_sb(const char *pat
out:
rc = 0;
out1:
- if (fd >= 0)
- close(fd);
freecon(curcon);
freecon(newcon);
return rc;
@@ -865,6 +857,7 @@ static void *selinux_restorecon_thread(v
FTSENT *ftsent;
int error;
char ent_path[PATH_MAX];
+ struct stat ent_st;
bool first = false;
if (state->parallel)
@@ -963,11 +956,11 @@ loop_body:
/* fall through */
default:
strcpy(ent_path, ftsent->fts_path);
-
+ ent_st = *ftsent->fts_statp;
if (state->parallel)
pthread_mutex_unlock(&state->mutex);
- error = restorecon_sb(ent_path, &state->flags,
+ error = restorecon_sb(ent_path, &ent_st, &state->flags,
first);
if (state->parallel) {
@@ -1163,7 +1156,7 @@ static int selinux_restorecon_common(con
goto cleanup;
}
- error = restorecon_sb(pathname, &state.flags, true);
+ error = restorecon_sb(pathname, &sb, &state.flags, true);
goto cleanup;
}