Secure Erasing on OS X

OS X comes with the powerful tool “Disk Utility” for any formatting or partition task. But as you may know, formatting a drive does not mean that all the data on it is really erased. What happens is that the information of the file structure is erased. Without this, the drive appears to be empty. In reality though, all the 0s and 1s representing the actual content of your files are still there. After saving new data on it, all the 0s and 1s on the drive get overwritten bit by bit.

To erase everything securely, you have to overwrite the complete disk with new 0s or 1s. Here is how it is done:

diskutil list
diskutil secureErase 0 /dev/disk[N] 

Instead N, use the number of the drive you want to be erased securely. These commands overwrite the selected drive with 0s. After that, the drive can ne formatted and partitioned normally.

Time-Planning in Software Projects

The following information is quoted from the classic software project book The Mythical Man-Month. According to its author, Fred Brooks, the total available time for a “serious” software project should be divided roughly in:

  • 1/3 of the time for planning
  • 1/6 of the time for coding
  • 1/4 of the time for component testing
  • 1/4 of the time for system testing

Well, the dedication of only 1/6 of the time for the actual programming sounds very little, but every developer can verify that the work never ends after the coding phase. If you want to deliver high quality, bug-free software, a substantial amount of time needs to be reserved for the testing afterwards. This is especially true if your software project is about a component of a bigger software system.

On the other hand, a well executed planning phase reduces the needed time for the programming significantly. The planning phase is the most important one, because it impacts all the following steps.

Determining the Path of a Terminal Application

Are you a terminal user? In case you are, you launch your application mostly by one word.

But where do these executable binary files actually lie on your file system? There are many posibilities. Usually the application could be lying…

  • in the folder you are currently in
  • in one of the common binary folders like /bin/ or /usr/bin
  • in a random folder which an application or an user added to the $PATH environment variable

Regardless where the wanted applications lies, you do not have to check every folder of your $PATH. Just use which [application] or type -p [application]. The result is the desired path.

Setting Right Permissions on Website Files

So you set up your Apache or any other webserver on Linux or OS X? Ideally you want to grant access to your website files only for yourself as user and your webserver.

Here’s how it’s done:

  • chown -R [username] [directory] Grant permission to yourself
  • chgrp -R [apache-group] [directory] Grant permission to your webserver (e.g. Apache)
  • chmod -R 750 [website directory] Give just enough rights to avoid any vulnerability
  • chmod g+s [website directory] All new files get the webserver’s group
  • chmod g+w [website directory] Only necessary if the web server needs to write files in this folder

First Post!

Hello World

The basic layout and design is set. This blog is ready to publish some awesome nerdy stuff to the world out there.

Stay tuned.