added build script
partly implemented cookie&session support #1, #2