Fix bug and add authentifcation access.

Fix bug.
Add possibility to have a / at the end of one URL.
Add EventDispatcher to manage access (with authentification or not)