howto print out Database AUTHENTICATION_FAILED details

23 views
Skip to first unread message

Cross Zheng

unread,
Jun 13, 2016, 10:48:36 AM6/13/16
to CAS Community
Hi guys

I am new to CAS and start from v4.2.2.

I have tried cas-overlay-template and dockerized-webapp for Database Authentication, but no matter how I modified the deployerConfigContext.xml and cas.properties, and passwordEncoder etc. I always got failed:

[STDOUT] 2016-06-13 22:35:15,057 INFO [org.jasig.cas.authentication.PolicyBasedAuthenticationManager] - <QueryDatabaseAuthenticationHandler failed authenticating cross1>
[STDOUT] 2016-06-13 22:35:15,060 INFO [org.jasig.inspektr.audit.support.Slf4jLoggingAuditTrailManager] - <Audit trail record BEGIN
[STDOUT] =============================================================
[STDOUT] WHO: cross1
[STDOUT] WHAT: Supplied credentials: [cross1]
[STDOUT] ACTION: AUTHENTICATION_FAILED
[STDOUT] APPLICATION: CAS
[STDOUT] WHEN: Mon Jun 13 22:35:15 CST 2016
[STDOUT] CLIENT IP ADDRESS: 192.168.1.150
[STDOUT] SERVER IP ADDRESS: 192.168.1.149
[STDOUT] =============================================================


So I want to find out more details about what happened during the encryption and transformations Could you please tell me how to tweak the log printing to print out more details or how to debug it?

Thanks,
Cross

John Rellis

unread,
Jun 16, 2016, 4:55:11 AM6/16/16
to CAS Community
Can you set the log level to debug?

You need log4j2.xml on your classpath

Something like (not tested)

<?xml version="1.0" encoding="UTF-8"?>
<Configuration status="WARN">
  <Appenders>
    <Console name="Console" target="SYSTEM_OUT">
      <PatternLayout pattern="%d{DEFAULT} [%t] %-5level %logger{36} - %msg%n"/>
    </Console>
  </Appenders>
  <Loggers>
    <Logger name="org.jasig" level="debug">
      <AppenderRef ref="Console"/>
    </Logger>
    <Logger name="org.apereo" level="debug">
      <AppenderRef ref="Console"/>
    </Logger>
    <Root level="info">
      <AppenderRef ref="Console"/>
    </Root>
  </Loggers>
</Configuration>

Cross Zheng

unread,
Jun 16, 2016, 5:15:28 AM6/16/16
to CAS Community
Thanks, John.

When I switch to DEBUG level, I got the error details. That is because my Mysql data problem.

Cheers,
Cross
Reply all
Reply to author
Forward
0 new messages