Code cleanup: except as (refs #327)

Replace 'except X, e:' -> 'except X as e:' for python3 compatibility.
Use new octal literal syntax (refs #327)
Pythonify! Use 'in' properly (refs #327)

Do not use 'object.has_key(key)' but instead use "key in object". Also,
prefer 'key not in object' to 'not key in object'.
Use relative imports (refs #327). Explicit > implicit
Change color of verify password notitication

The color of the password notification was green, this is counterintuitive
for users as it marks something that went well. However, after typing in the
password, some action has to be taken.

Now the color shows the color of the other hints (yellow). Also, the message
does not disappear anymore, you have to click it, or finish the password
change (after it is finished, a new message shows up, which will disappear
automatically). This refs #377.
Change the no-MD5 error message (fixes #377)

From the error message it was not clear that a password might not have been
set at all. Explain this and give a hint on how to fix this.