[ FSyncMS ] Version 0.13 – Database upgrade

It has been a while since the last FSyncMS update so here is a new Version.
The main new feature is that its now possible to store the user password as a bcrypt hash and one does no longer depend on MD5 for this.
Thanks to Trellmor for this new feature.

Also it’s recommended to use bcrypt as hashalgorythm from now on, and this is default for new installtions, existing installations wont change algorythm automaticaly.

But changing the algorythm in existing installations is quiet easy.
As always you should remember doing a backup at first.
After that do this simple steps:

  1. First the DB scheme has to be updated, so that the filed named ‘md5’ can take 124 Characters. If you use mysql this change will be done by the following sql statement
    ALTER TABLE `users` CHANGE `md5` `md5` VARCHAR( 124 ) CHARACTER SET latin1 COLLATE latin1_swedish_ci NULL DEFAULT NULL;

    .

  2. After adapting the DB, you may enable bcrypt by adding
    define("BCRYPT", true); 
    define("BCRYPT_ROUNDS", 12);

    to your config.php

  3. As last step you simply have to sync. While the correspoding login, the FSyncMS-Software will replace the Passwordhash in your database with the new version.

Further more, if you’re using sqlite, you may now change the destination or name of the database file in config.php,
by the a statement like this:

define("SQLITE_FILE", "weave_db");

In this context I want to remind that the weave_db should never be accessible directly via web, also its data should be encrypted.
So eighter use .htacces or similar technology to deny access to this file via browser, or move it anywhere that is not served via your webserver.

Download newest Version

Posted in FSyncMS, Synchronsiation, Technik | Tagged , , | 6 Comments

Und dann waren wir wieder Fremde…

Wir waren Fremde.
Wurden Freunde und mehr als das.
Gesucht und gefunden…

Herzen berührt,
als Eins gefühlt.
Es war schön, sehr schön.

Aber irgendwann änderte es sich,
es wurde kompliziert…

Irgendwann zu kompliziert,
und es brach in zwei.

Und dann konnten wir nicht mal mehr Freunde sein.
Und heute sind wir wie Fremde.
Wieder Fremde…

Posted in Nachdenklich, out of my life | Leave a comment

Debian Wheezy, Atom N2800 and graphic

I recently upgraded some debian installations to the currently newest Version (wheezy).
While most of the upgrades went very smooth, I ran into some trubles updating a system running on a Intel Atom Board.
As I reboted the mentiond system to boot the new kernel the VGA signal droped.

In the end it seems to be a bug in the 'gma500_gfx' module witch caused the Graphic-Blackout.
After blacklisting the mentiond modul, it worked again as it should.

Posted in Technik | Tagged , , , , , | 1 Comment

`cat` as a shell builtin

Recently i blogged about how to get a process list if you aren’t able to fork any processes . Also a process list is allways handy, i allways find cat a very usefull tool too. But as you might have noticed cat is not a shell builtin. So everytime cat is called a new process needs to be forked. In case you can’t fork processes it’s a problem, and even if you can fork them you may save resources by “creating” a shell builtin cat.
So lets do this,
open your .profile for usage with your user only or /etc/profile for global usage (You may also use your .bashrc or .zshrc instead).
Append the following lines to the file:

#pseudo bash builtin cat function
function cat { echo “$(< $1)" }

Siehe Kommentar :)

function cat {
  if [ $# -eq 1 -a "${1:0:1}" != "-" ]
  then
    exec 3< "${1:-/dev/stdin}"
    while read -r -u3 line
    do
      echo -E ''"${line}";
    done
    echo -nE ''"${line}";
    exec 3<&-
    else
     /bin/cat "$@"
fi
}

Voila, if you start a new loginshell the cat should refer to a shell function and not to a binary.
(to test this simply type type cat result should be something like cat is a shell function )

Posted in Allgemein, Technik | Tagged , , | 2 Comments

Shortcut to lock the screen on a mac

Sometimes i don’t want to put my macbook air asleep because of some job that is running. But i have to leave the room so i need to lock it.
So there is a shortcut for locking the screen:

Shift+Crtl+Eject

This works on the most macs, but the macbook air has no Eject button on the Keyboard. So on systems without an Eject button you have to use:

Shift+Crtl+Power

Posted in Allgemein, Technik | Tagged , , , | 1 Comment