User agent generation function added to common.py for convenience.
Primitive Web application support added. Only works on Unix.