hal/tools Makefile.am, 1.36, 1.37 hal-policy-is-privileged.c, 1.3,
NONE hal-storage-mount.c, 1.1, 1.2 hal-system-power-hibernate,
1.7, 1.8 hal-system-power-reboot, 1.3,
1.4 hal-system-power-shutdown, 1.3,
1.4 hal-system-power-suspend, 1.7,
1.8 hal-system-storage-eject, 1.7,
1.8 hal-system-storage-mount, 1.25,
NONE hal-system-storage-unmount, 1.8, 1.9
David Zeuthen
david at kemper.freedesktop.org
Tue Mar 7 20:14:11 PST 2006
- Previous message: hal/doc/api/tmpl acpi.sgml, 1.1, 1.2 apm.sgml, 1.1,
1.2 blockdev.sgml, 1.1, 1.2 classdev.sgml, 1.1,
1.2 coldplug.sgml, 1.1, 1.2 config.sgml, 1.1, 1.2 device.sgml,
1.1, 1.2 device_info.sgml, 1.1, 1.2 device_store.sgml, 1.1,
1.2 dlist.sgml, 1.1, 1.2 hal_block.sgml, 1.1, 1.2 hal_ide.sgml,
1.1, 1.2 hal_input.sgml, 1.1, 1.2 hal_monitor.sgml, 1.1,
1.2 hal_net.sgml, 1.1, 1.2 hal_pci.sgml, 1.1,
1.2 hal_scsi.sgml, 1.1, 1.2 hal_usb.sgml, 1.1, 1.2 hald.sgml,
1.1, 1.2 hald_dbus.sgml, 1.1, 1.2 hald_marshal.sgml, 1.1,
1.2 hald_runner.sgml, 1.1, 1.2 hotplug.sgml, 1.1,
1.2 hotplug_helper.sgml, 1.1, 1.2 ids.sgml, 1.1,
1.2 libhal-policy.sgml, 1.1, 1.2 libhal-storage.sgml, 1.1,
1.2 libhal.sgml, 1.1, 1.2 libsysfs.sgml, 1.1,
1.2 linux_dvd_rw_utils.sgml, 1.1, 1.2 logger.sgml, 1.1,
1.2 logging.sgml, 1.1, 1.2 main.sgml, 1.1, 1.2 osspec.sgml,
1.1, 1.2 osspec_linux.sgml, 1.1, 1.2 physdev.sgml, 1.1,
1.2 pmu.sgml, 1.1, 1.2 property.sgml, 1.1, 1.2 runner.sgml,
1.1, 1.2 shared.sgml, 1.1, 1.2 sysfs.sgml, 1.1, 1.2 utils.sgml,
1.1, 1.2 volume_id.sgml, 1.1, 1.2
- Next message: hal/doc/spec hal-spec.html,1.80,1.81
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvs/hal/hal/tools
In directory kemper:/tmp/cvs-serv28520/tools
Modified Files:
Makefile.am hal-storage-mount.c hal-system-power-hibernate
hal-system-power-reboot hal-system-power-shutdown
hal-system-power-suspend hal-system-storage-eject
hal-system-storage-unmount
Removed Files:
hal-policy-is-privileged.c hal-system-storage-mount
Log Message:
2006-03-07 David Zeuthen <davidz at redhat.com>
Move libhal-policy to a dedicated package PolicyKit (available in
HAL CVS).
* configure.in: Require PolicyKit (available in hal CVS) and don't
build libhal-policy. Extract some useful POLKIT variables for
user, group and txtsrc for PolicyKit
* Makefile.am: Don't build libhal-policy or hal-policy.pc
* policy/txt/Makefile.am: Use new POLKIT_TXTSRC variable on where
to install policy
* tools/Makefile.am: Don't build hal-policy-is-privileged as it is
obsoleted by PolicyKit's polkit-is-privileged
* tools/hal-storage-mount.c: Use new libpolkit instead of
libhal-policy
* tools/hal-system-power-hibernate,
tools/hal-system-power-suspend, tools/hal-system-power-reboot,
tools/hal-system-power-shutdown: Use polkit-is-privileged instead
of hal-policy-is-privileged
* libhal-policy/libhal-policy.c, libhal-policy/libhal-policy.h,
libhal-policy/libhal-policy-test.c, libhal-policy/Makefile.am,
tools/hal-policy-is-privileged.c, tools/hal-system-storage-mount:
Remove these files.
Index: Makefile.am
===================================================================
RCS file: /cvs/hal/hal/tools/Makefile.am,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -d -r1.36 -r1.37
--- Makefile.am 6 Mar 2006 22:34:29 -0000 1.36
+++ Makefile.am 8 Mar 2006 04:14:09 -0000 1.37
@@ -19,11 +19,7 @@
hal-set-property \
hal-find-by-capability \
hal-find-by-property \
- hal-device \
- hal-policy-is-privileged
-
-hal_policy_is_privileged_SOURCES = hal-policy-is-privileged.c
-hal_policy_is_privileged_LDADD = @GLIB_LIBS@ $(top_builddir)/libhal-policy/libhal-policy.la
+ hal-device
lshal_SOURCES = lshal.c
lshal_LDADD = @PACKAGE_LIBS@ $(top_builddir)/libhal/libhal.la
@@ -48,7 +44,7 @@
hal-system-power-pmu
hal_storage_mount_SOURCES = hal-storage-mount.c
-hal_storage_mount_LDADD = @GLIB_LIBS@ @DBUS_LIBS@ $(top_builddir)/libhal/libhal.la $(top_builddir)/libhal-storage/libhal-storage.la $(top_builddir)/libhal-policy/libhal-policy.la
+hal_storage_mount_LDADD = @GLIB_LIBS@ @POLKIT_LIBS@ @DBUS_LIBS@ $(top_builddir)/libhal/libhal.la $(top_builddir)/libhal-storage/libhal-storage.la
hal_system_power_pmu_SOURCES = hal-system-power-pmu.c
hal_system_power_pmu_LDADD = @DBUS_LIBS@ $(top_builddir)/libhal/libhal.la
@@ -66,7 +62,6 @@
hal-system-lcd-get-brightness \
hal-system-lcd-set-brightness \
hal-system-power-set-power-save \
- hal-system-storage-mount \
hal-system-storage-unmount \
hal-system-storage-eject \
hal-system-storage-cleanup-mountpoint \
--- hal-policy-is-privileged.c DELETED ---
Index: hal-storage-mount.c
===================================================================
RCS file: /cvs/hal/hal/tools/hal-storage-mount.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- hal-storage-mount.c 6 Mar 2006 22:34:29 -0000 1.1
+++ hal-storage-mount.c 8 Mar 2006 04:14:09 -0000 1.2
@@ -35,7 +35,7 @@
#include <libhal/libhal.h>
#include <libhal-storage/libhal-storage.h>
-#include <libhal-policy/libhal-policy.h>
+#include <libpolkit/libpolkit.h>
/*#define DEBUG*/
#define DEBUG
@@ -287,7 +287,7 @@
static void
-handle_mount (LibHalContext *hal_ctx, LibHalPolicyContext *pol_ctx, const char *udi,
+handle_mount (LibHalContext *hal_ctx, LibPolKitContext *pol_ctx, const char *udi,
LibHalVolume *volume, LibHalDrive *drive, const char *device, uid_t invoked_by)
{
int i, j;
@@ -538,11 +538,11 @@
printf ("using policy %s for uid %d\n", policy, invoked_by);
#endif
- if (libhal_policy_is_uid_allowed_for_policy (pol_ctx,
- invoked_by,
- policy,
- udi,
- &allowed_by_policy) != LIBHAL_POLICY_RESULT_OK) {
+ if (libpolkit_is_uid_allowed_for_policy (pol_ctx,
+ invoked_by,
+ policy,
+ udi,
+ &allowed_by_policy) != LIBPOLKIT_RESULT_OK) {
printf ("cannot lookup policy\n");
unknown_error ();
}
@@ -660,7 +660,7 @@
LibHalVolume *volume;
DBusError error;
LibHalContext *hal_ctx = NULL;
- LibHalPolicyContext *pol_ctx = NULL;
+ LibPolKitContext *pol_ctx = NULL;
uid_t invoked_by;
device = getenv ("HAL_PROP_BLOCK_DEVICE");
@@ -679,7 +679,7 @@
usage ();
}
- pol_ctx = libhal_policy_new_context ();
+ pol_ctx = libpolkit_new_context ();
if (pol_ctx == NULL) {
printf ("Cannot get policy context\n");
unknown_error ();
Index: hal-system-power-hibernate
===================================================================
RCS file: /cvs/hal/hal/tools/hal-system-power-hibernate,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- hal-system-power-hibernate 27 Feb 2006 01:12:17 -0000 1.7
+++ hal-system-power-hibernate 8 Mar 2006 04:14:09 -0000 1.8
@@ -12,11 +12,11 @@
POLICY=power-hibernate
if [ "$HAL_METHOD_INVOKED_BY_UID" != "0" ] ; then
- hal-policy-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
+ polkit-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
IS_PRIVILEGED=$?
if [ "$IS_PRIVILEGED" != "0" ] ; then
echo org.freedesktop.Hal.Device.PermissionDeniedByPolicy >&2
- echo uid $HAL_METHOD_INVOKED_BY_UID refused by policy "$POLICY" >&2
+ echo $POLICY refused uid $HAL_METHOD_INVOKED_BY_UID >&2
exit 1
fi
fi
Index: hal-system-power-reboot
===================================================================
RCS file: /cvs/hal/hal/tools/hal-system-power-reboot,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- hal-system-power-reboot 27 Feb 2006 01:12:17 -0000 1.3
+++ hal-system-power-reboot 8 Mar 2006 04:14:09 -0000 1.4
@@ -8,11 +8,11 @@
POLICY=power-reboot
if [ "$HAL_METHOD_INVOKED_BY_UID" != "0" ] ; then
- hal-policy-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
+ polkit-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
IS_PRIVILEGED=$?
if [ "$IS_PRIVILEGED" != "0" ] ; then
echo org.freedesktop.Hal.Device.PermissionDeniedByPolicy >&2
- echo uid $HAL_METHOD_INVOKED_BY_UID refused by policy "$POLICY" >&2
+ echo $POLICY refused uid $HAL_METHOD_INVOKED_BY_UID >&2
exit 1
fi
fi
Index: hal-system-power-shutdown
===================================================================
RCS file: /cvs/hal/hal/tools/hal-system-power-shutdown,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- hal-system-power-shutdown 27 Feb 2006 01:12:17 -0000 1.3
+++ hal-system-power-shutdown 8 Mar 2006 04:14:09 -0000 1.4
@@ -8,11 +8,11 @@
POLICY=power-poweroff
if [ "$HAL_METHOD_INVOKED_BY_UID" != "0" ] ; then
- hal-policy-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
+ polkit-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
IS_PRIVILEGED=$?
if [ "$IS_PRIVILEGED" != "0" ] ; then
echo org.freedesktop.Hal.Device.PermissionDeniedByPolicy >&2
- echo uid $HAL_METHOD_INVOKED_BY_UID refused by policy "$POLICY" >&2
+ echo $POLICY refused uid $HAL_METHOD_INVOKED_BY_UID >&2
exit 1
fi
fi
Index: hal-system-power-suspend
===================================================================
RCS file: /cvs/hal/hal/tools/hal-system-power-suspend,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- hal-system-power-suspend 27 Feb 2006 01:12:17 -0000 1.7
+++ hal-system-power-suspend 8 Mar 2006 04:14:09 -0000 1.8
@@ -18,11 +18,11 @@
POLICY=power-suspend
if [ "$HAL_METHOD_INVOKED_BY_UID" != "0" ] ; then
- hal-policy-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
+ polkit-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
IS_PRIVILEGED=$?
if [ "$IS_PRIVILEGED" != "0" ] ; then
echo org.freedesktop.Hal.Device.PermissionDeniedByPolicy >&2
- echo uid $HAL_METHOD_INVOKED_BY_UID refused by policy "$POLICY" >&2
+ echo $POLICY refused uid $HAL_METHOD_INVOKED_BY_UID >&2
exit 1
fi
fi
Index: hal-system-storage-eject
===================================================================
RCS file: /cvs/hal/hal/tools/hal-system-storage-eject,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- hal-system-storage-eject 27 Feb 2006 01:12:17 -0000 1.7
+++ hal-system-storage-eject 8 Mar 2006 04:14:09 -0000 1.8
@@ -26,11 +26,11 @@
# TODO: need to select storage-[fixed|removable][-change-uid]
#POLICY=storage-fixed-mount
#if [ "$HAL_METHOD_INVOKED_BY_UID" != "0" ] ; then
-# hal-policy-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
+# polkit-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
# IS_PRIVILEGED=$?
# if [ "$IS_PRIVILEGED" != "0" ] ; then
# echo org.freedesktop.Hal.Device.PermissionDeniedByPolicy >&2
-# echo uid $HAL_METHOD_INVOKED_BY_UID refused by policy "$POLICY" >&2
+# echo $POLICY refused uid $HAL_METHOD_INVOKED_BY_UID >&2
# exit 1
# fi
#fi
--- hal-system-storage-mount DELETED ---
Index: hal-system-storage-unmount
===================================================================
RCS file: /cvs/hal/hal/tools/hal-system-storage-unmount,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- hal-system-storage-unmount 27 Feb 2006 01:12:17 -0000 1.8
+++ hal-system-storage-unmount 8 Mar 2006 04:14:09 -0000 1.9
@@ -46,11 +46,11 @@
# TODO: need to select storage-[fixed|removable][-change-uid]
#POLICY=storage-fixed-mount
#if [ "$HAL_METHOD_INVOKED_BY_UID" != "0" ] ; then
-# hal-policy-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
+# polkit-is-privileged --policy $POLICY --uid $HAL_METHOD_INVOKED_BY_UID
# IS_PRIVILEGED=$?
# if [ "$IS_PRIVILEGED" != "0" ] ; then
# echo org.freedesktop.Hal.Device.PermissionDeniedByPolicy >&2
-# echo uid $HAL_METHOD_INVOKED_BY_UID refused by policy "$POLICY" >&2
+# echo $POLICY refused uid $HAL_METHOD_INVOKED_BY_UID >&2
# exit 1
# fi
#fi
- Previous message: hal/doc/api/tmpl acpi.sgml, 1.1, 1.2 apm.sgml, 1.1,
1.2 blockdev.sgml, 1.1, 1.2 classdev.sgml, 1.1,
1.2 coldplug.sgml, 1.1, 1.2 config.sgml, 1.1, 1.2 device.sgml,
1.1, 1.2 device_info.sgml, 1.1, 1.2 device_store.sgml, 1.1,
1.2 dlist.sgml, 1.1, 1.2 hal_block.sgml, 1.1, 1.2 hal_ide.sgml,
1.1, 1.2 hal_input.sgml, 1.1, 1.2 hal_monitor.sgml, 1.1,
1.2 hal_net.sgml, 1.1, 1.2 hal_pci.sgml, 1.1,
1.2 hal_scsi.sgml, 1.1, 1.2 hal_usb.sgml, 1.1, 1.2 hald.sgml,
1.1, 1.2 hald_dbus.sgml, 1.1, 1.2 hald_marshal.sgml, 1.1,
1.2 hald_runner.sgml, 1.1, 1.2 hotplug.sgml, 1.1,
1.2 hotplug_helper.sgml, 1.1, 1.2 ids.sgml, 1.1,
1.2 libhal-policy.sgml, 1.1, 1.2 libhal-storage.sgml, 1.1,
1.2 libhal.sgml, 1.1, 1.2 libsysfs.sgml, 1.1,
1.2 linux_dvd_rw_utils.sgml, 1.1, 1.2 logger.sgml, 1.1,
1.2 logging.sgml, 1.1, 1.2 main.sgml, 1.1, 1.2 osspec.sgml,
1.1, 1.2 osspec_linux.sgml, 1.1, 1.2 physdev.sgml, 1.1,
1.2 pmu.sgml, 1.1, 1.2 property.sgml, 1.1, 1.2 runner.sgml,
1.1, 1.2 shared.sgml, 1.1, 1.2 sysfs.sgml, 1.1, 1.2 utils.sgml,
1.1, 1.2 volume_id.sgml, 1.1, 1.2
- Next message: hal/doc/spec hal-spec.html,1.80,1.81
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the hal-commit
mailing list