cas.propierties
cas.audit.slf4j.enabled=false
cas.audit.groovy.template.location=file:/etc/cas/GroovyAuditor.groovy
cat GroovyAuditor.groovy
${
logger.info("Hello, World")}
who: ${who}, what: ${what}, when: ${when}, ip: ${clientIpAddress}, trace: ${customHttpRequestHeader}
logs:
2024-05-14 12:55:14,429 ERROR [org.apereo.cas.web.support.filters.AbstractSecurityFilter] - <Request processing failed: org.springframework.webflow.execution.ActionExecutionException: Exception thrown executing org.apereo.cas.web.flow.login.InitialAuthenticationRequestValidationAction@1ce6a01e
in state 'initialAuthenticationRequestValidationCheck' of flow 'login' -- action execution attributes were 'map[[empty]]'
FrameworkServlet.java:processRequest:1022
FrameworkServlet.java:doGet:903
HttpServlet.java:service:527
... 109 more
Caused by: groovy.lang.MissingPropertyException: No such property: customHttpRequestHeader for class: groovy.lang.Binding
at groovy.lang.Binding.getVariable(Binding.java:61) ~[groovy-4.0.19.jar!/:4.0.19]
at groovy.lang.Binding.getProperty(Binding.java:117) ~[groovy-4.0.19.jar!/:4.0.19]
at org.codehaus.groovy.runtime.InvokerHelper.getProperty(InvokerHelper.java:167) ~[groovy-4.0.19.jar!/:4.0.19]
at groovy.lang.Closure.getPropertyTryThese(Closure.java:325) ~[groovy-4.0.19.jar!/:4.0.19]
at groovy.lang.Closure.getPropertyDelegateFirst(Closure.java:315) ~[groovy-4.0.19.jar!/:4.0.19]
at groovy.lang.Closure.getProperty(Closure.java:301) ~[groovy-4.0.19.jar!/:4.0.19]
What have i missed ? I just need to test some basic audit groovy script at the begining.