With a small bash script, it is possible to randomly select an image from a
directory and change the current GNOME wallpaper to that image. It's easy to
forget just how powerful bash can be; more than just a simple command shell,
bash has a whole host of features that make it well-suited for even complex
programming tasks.
To begin this hack, you need to have a directory full of wallpapers somewhere.
Assume this directory is located at /home/foo/Images/Wallpapers/. This script
will take an image from that directory and set it as the current wallpaper.
Tuesday, May 14, 2013
Monday, May 13, 2013
Secure Mount Points in Unix
The primary way of interacting with a Unix machine is through its filesystem.
Thus, when an intruder has gained access to a system, it is desirable to
limit what he can do with the files available to him. One way to accomplish
this is with the use of restrictive mount options.
A mount option is a flag that controls how the file system may be accessed. It
is passed to the operating system kernel’s code when the file system is
brought online. Mount options can be used to prevent files from being interpreted
as device nodes, to disallow binaries from being executed, and to disallow the
SUID bit from taking effect (by using the nodev, noexec, and nosuid
flags). Files ystems can also be mounted read-only with the ro option.
These options are specified from the command line by running mount with
the -o flag. For example, if you have a separate partition for /tmp that is on
the third partition of your first IDE hard disk, you can mount with the
nodev, noexec, and nosuid flags, which are enabled by running the following
Thus, when an intruder has gained access to a system, it is desirable to
limit what he can do with the files available to him. One way to accomplish
this is with the use of restrictive mount options.
A mount option is a flag that controls how the file system may be accessed. It
is passed to the operating system kernel’s code when the file system is
brought online. Mount options can be used to prevent files from being interpreted
as device nodes, to disallow binaries from being executed, and to disallow the
SUID bit from taking effect (by using the nodev, noexec, and nosuid
flags). Files ystems can also be mounted read-only with the ro option.
These options are specified from the command line by running mount with
the -o flag. For example, if you have a separate partition for /tmp that is on
the third partition of your first IDE hard disk, you can mount with the
nodev, noexec, and nosuid flags, which are enabled by running the following
Subscribe to:
Posts (Atom)