Apple Webserver fix to master

Cherry-picked laurentj's webservr fixes to work with master