add option to trust reverse proxy for basic auth
Merge pull request #55 from p1tz/master

merge
Merge pull request #30 from arago/master

sync with master