|
|
47b511b |
diff --exclude-from=exclude -N -u -r nsalibselinux/man/man8/matchpathcon.8 libselinux-2.0.9/man/man8/matchpathcon.8
|
|
|
47b511b |
--- nsalibselinux/man/man8/matchpathcon.8 2007-01-17 11:11:35.000000000 -0500
|
|
|
47b511b |
+++ libselinux-2.0.9/man/man8/matchpathcon.8 2007-04-05 13:20:43.000000000 -0400
|
|
|
47b511b |
@@ -28,4 +28,4 @@
|
|
|
47b511b |
|
|
|
47b511b |
.SH "SEE ALSO"
|
|
|
47b511b |
.BR selinux "(8), "
|
|
|
47b511b |
-.BR mathpathcon "(3), "
|
|
|
47b511b |
+.BR matchpathcon "(3), "
|
|
|
ff4b4da |
diff --exclude-from=exclude -N -u -r nsalibselinux/src/selinuxswig.i libselinux-2.0.9/src/selinuxswig.i
|
|
|
ff4b4da |
--- nsalibselinux/src/selinuxswig.i 2007-02-22 08:53:23.000000000 -0500
|
|
|
47b511b |
+++ libselinux-2.0.9/src/selinuxswig.i 2007-04-05 16:47:42.000000000 -0400
|
|
|
47b511b |
@@ -115,9 +115,38 @@
|
|
|
ff4b4da |
extern const char *selinux_path(void);
|
|
|
ff4b4da |
extern int selinux_check_passwd_access(access_vector_t requested);
|
|
|
ff4b4da |
extern int checkPasswdAccess(access_vector_t requested);
|
|
|
ff4b4da |
+
|
|
|
ff4b4da |
+// This tells SWIG to treat char ** as a special case
|
|
|
47b511b |
+%typemap(python,in) char ** {
|
|
|
ff4b4da |
+ /* Check if is a list */
|
|
|
ff4b4da |
+ if (PyList_Check($input)) {
|
|
|
ff4b4da |
+ int size = PyList_Size($input);
|
|
|
ff4b4da |
+ int i = 0;
|
|
|
ff4b4da |
+ $1 = (char **) malloc((size+1)*sizeof(char *));
|
|
|
47b511b |
+ if ($1 == NULL) {
|
|
|
47b511b |
+ PyErr_SetString(PyExc_MemoryError,"Out of memory");
|
|
|
47b511b |
+ return NULL;
|
|
|
47b511b |
+ }
|
|
|
ff4b4da |
+ for (i = 0; i < size; i++) {
|
|
|
ff4b4da |
+ PyObject *o = PyList_GetItem($input,i);
|
|
|
ff4b4da |
+ if (PyString_Check(o))
|
|
|
ff4b4da |
+ $1[i] = PyString_AsString(PyList_GetItem($input,i));
|
|
|
ff4b4da |
+ else {
|
|
|
ff4b4da |
+ PyErr_SetString(PyExc_TypeError,"list must contain strings");
|
|
|
ff4b4da |
+ free($1);
|
|
|
ff4b4da |
+ return NULL;
|
|
|
ff4b4da |
+ }
|
|
|
ff4b4da |
+ }
|
|
|
ff4b4da |
+ $1[i] = 0;
|
|
|
ff4b4da |
+ } else {
|
|
|
ff4b4da |
+ PyErr_SetString(PyExc_TypeError,"not a list");
|
|
|
ff4b4da |
+ return NULL;
|
|
|
ff4b4da |
+ }
|
|
|
ff4b4da |
+}
|
|
|
ff4b4da |
+
|
|
|
ff4b4da |
extern int rpm_execcon(unsigned int verified,
|
|
|
ff4b4da |
const char *filename,
|
|
|
ff4b4da |
- char *const argv[], char *const envp[]);
|
|
|
ff4b4da |
+ char **, char **);
|
|
|
ff4b4da |
|
|
|
ff4b4da |
extern int is_context_customizable (security_context_t scontext);
|
|
|
ff4b4da |
|
|
|
ff4b4da |
diff --exclude-from=exclude -N -u -r nsalibselinux/utils/getsebool.c libselinux-2.0.9/utils/getsebool.c
|
|
|
c7862e5 |
--- nsalibselinux/utils/getsebool.c 2006-11-16 17:15:17.000000000 -0500
|
|
|
47b511b |
+++ libselinux-2.0.9/utils/getsebool.c 2007-04-05 16:57:51.000000000 -0400
|
|
|
47b511b |
@@ -14,7 +14,7 @@
|
|
|
47b511b |
|
|
|
47b511b |
int main(int argc, char **argv)
|
|
|
47b511b |
{
|
|
|
47b511b |
- int i, rc = 0, active, pending, len = 0, opt;
|
|
|
47b511b |
+ int i, get_all = 0, rc = 0, active, pending, len = 0, opt;
|
|
|
47b511b |
char **names;
|
|
|
47b511b |
|
|
|
47b511b |
while ((opt = getopt(argc, argv, "a")) > 0) {
|
|
|
47b511b |
@@ -39,6 +39,7 @@
|
|
|
47b511b |
printf("No booleans\n");
|
|
|
47b511b |
return 0;
|
|
|
47b511b |
}
|
|
|
47b511b |
+ get_all = 1;
|
|
|
47b511b |
break;
|
|
|
47b511b |
default:
|
|
|
47b511b |
usage(argv[0]);
|
|
|
47b511b |
@@ -72,6 +73,8 @@
|
|
|
22298b4 |
for (i = 0; i < len; i++) {
|
|
|
22298b4 |
active = security_get_boolean_active(names[i]);
|
|
|
22298b4 |
if (active < 0) {
|
|
|
47b511b |
+ if (get_all && errno == EACCES)
|
|
|
47b511b |
+ continue;
|
|
|
47b511b |
fprintf(stderr, "Error getting active value for %s\n",
|
|
|
47b511b |
names[i]);
|
|
|
47b511b |
rc = -1;
|