A bit of refactoring in ShibbolethController

Most pulled from mconf-rnp/mconf-web.