gnome-lirc-properties r76 - in trunk: . gnome_lirc_properties
- From: hadess svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-lirc-properties r76 - in trunk: . gnome_lirc_properties
- Date: Mon, 27 Oct 2008 17:11:13 +0000 (UTC)
Author: hadess
Date: Mon Oct 27 17:11:12 2008
New Revision: 76
URL: http://svn.gnome.org/viewvc/gnome-lirc-properties?rev=76&view=rev
Log:
2008-10-27 Bastien Nocera <hadess hadess net>
* gnome_lirc_properties/backend.py: Check which actions are
passed to the backend, so we don't launch "stop ; rm -rf /"
by accident (Closes: #558128)
Modified:
trunk/ChangeLog
trunk/gnome_lirc_properties/backend.py
Modified: trunk/gnome_lirc_properties/backend.py
==============================================================================
--- trunk/gnome_lirc_properties/backend.py (original)
+++ trunk/gnome_lirc_properties/backend.py Mon Oct 27 17:11:12 2008
@@ -763,10 +763,15 @@
def ManageLircDaemon(self, action, sender=None):
'''Starts the LIRC daemon.'''
+ permitted_actions = [ 'enable', 'disable', 'stop', 'start', 'restart' ]
+
self._check_permission(sender)
print 'Managing lircd: %s...' % action
+ if action not in permitted_actions:
+ raise AccessDeniedException
+
if 'enable' == action:
self._write_hardware_configuration(start_lircd=True)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]