Announcement

Collapse
No announcement yet.

Running a script on certain events...

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Running a script on certain events...

    I want the system to execute a certain command (asynchronously) in these events:

    * When KDM starts up
    * Whenever the laptop lid is opened
    * Whenever someone inputs an incorrect password

    As you can probably guess, it's a security related thing (details for anyone interested). Currently on 10.04, but as soon as the stable repo gets updated I will be moving to 10.10. I have a pretty large amount of experience with Linux and am right at home in a terminal or the /etc directory.

    How do I do this? Should I write a daemon which checks logs? Or are there callbacks I can configure someplace? TIA.

    #2
    Re: Running a script on certain events...

    D-Bus is probably the way to go. Sorry I cannot give you a recipe for your problems, here's the documentation:
    http://www.freedesktop.org/wiki/Software/dbus

    You can examine D-bus objects with qdbusviewer (part of qt4-dev-tools) and qdbus

    Comment

    Working...
    X