Add authentication

(protection is still not implemented)