Unicon / cas-mfa

CAS server overlay with support for multifactor authentication.
Apache License 2.0
24 stars 19 forks source link

Allow for easier customization of views #99

Closed alexkolson closed 9 years ago

alexkolson commented 9 years ago

It would be cool if one could more easily specify different views for MFA. Perhaps by adding a field or fields in cas.properties? Then this:

<bean id="casDuoLoginView" class="org.springframework.web.servlet.view.JstlView"
    p:url="/WEB-INF/view/jsp/default/ui/casDuoLoginView.jsp" />

Could become something like this:

<bean id="casDuoLoginView" class="org.springframework.web.servlet.view.JstlView"
    p:url="${screen.mfa.duo.login.view:/WEB-INF/view/jsp/default/ui/casDuoLoginView.jsp}" />

What are your thoughts? Should we just add this bean with our view url in our overlay or would putting this in the properties file make sense?

mmoayyed commented 9 years ago

What is it that you are trying to accomplish with the config? Do you mean to apply css and js to the jsp?

alexkolson commented 9 years ago

Yeah, exactly.

mmoayyed commented 9 years ago

OK. We can certainly add a CSS file. Looks like the view is missing that. However you should still be getting a cas.js file references on that page.

mmoayyed commented 9 years ago

Now that I review again, I also see the top.jsp which should include a ref to the css file: https://github.com/Unicon/cas-mfa/blob/master/cas-mfa-duo-web/src/main/webapp/WEB-INF/view/jsp/default/ui/casDuoLoginView.jsp#L1

Would that be sufficient?

mmoayyed commented 9 years ago

Also note that since duo loads in an iframe, I am not totally sure if you can change the look and feel of it purely via css/js.

alexkolson commented 9 years ago

After thinking about it again, I suppose there are many different ways one could customize the view. Perhaps I could just utilize the maven overlay method and substitute any number of customized *.jsp files for the ones packaged with cas-mfa.

alexkolson commented 9 years ago

Going to close this since I no longer really believe this is needed.