flow
flow

Reputation: 5038

CAS server 4.0.x restlet api supplied credentials are null

I successfully configured a cas server with ldap. Login works fine.
Now, I try to configure the rest protocol following this instructions : http://jasig.github.io/cas/4.0.x/protocol/REST-Protocol.html

I use a restclient tu send this POST request :

https://localhost:8443/cas/v1/tickets
username=myUser
password=myPassword

I receive an err 400. There are the logs on cas server :

2015-01-21 13:41:50,513 DEBUG [org.jasig.cas.integration.restlet.TicketResource] - <Obtaining credentials...>
2015-01-21 13:41:50,513 DEBUG [org.jasig.cas.integration.restlet.TicketResource] - <>
2015-01-21 13:41:50,513 INFO [org.jasig.cas.authentication.PolicyBasedAuthenticationManager] - <LdapAuthenticationHandler failed authenticating null+password>
2015-01-21 13:41:50,514 INFO [com.github.inspektr.audit.support.Slf4jLoggingAuditTrailManager] - <Audit trail record BEGIN
=============================================================
WHO: audit:unknown
WHAT: supplied credentials: [null+password]
ACTION: AUTHENTICATION_FAILED
APPLICATION: CAS
WHEN: Wed Jan 21 13:41:50 CET 2015
CLIENT IP ADDRESS: 0:0:0:0:0:0:0:1
SERVER IP ADDRESS: 0.0.0.0
=============================================================

>
2015-01-21 13:41:50,514 INFO [org.perf4j.TimingLogger] - <start[1421844110513] time[0] tag[AUTHENTICATE]>
2015-01-21 13:41:50,514 INFO [com.github.inspektr.audit.support.Slf4jLoggingAuditTrailManager] - <Audit trail record BEGIN
=============================================================
WHO: audit:unknown
WHAT: 1 errors, 0 successes
ACTION: TICKET_GRANTING_TICKET_NOT_CREATED
APPLICATION: CAS
WHEN: Wed Jan 21 13:41:50 CET 2015
CLIENT IP ADDRESS: 0:0:0:0:0:0:0:1
SERVER IP ADDRESS: 0.0.0.0
=============================================================

>
2015-01-21 13:41:50,514 INFO [org.perf4j.TimingLogger] - <start[1421844110513] time[0] tag[CREATE_TICKET_GRANTING_TICKET]>
2015-01-21 13:41:50,514 ERROR [org.jasig.cas.integration.restlet.TicketResource] - <1 errors, 0 successes>
org.jasig.cas.authentication.AuthenticationException: 1 errors, 0 successes
[...]

It seems that supplied credentials are null. What can be the cause of this error ?
Thanks for help

Upvotes: 0

Views: 1137

Answers (1)

user3849960
user3849960

Reputation: 120

Hi I currently have the same problem. I get 400 if the api is called by a java client instead 201 with rest chrome extension. BTW the only clue I've found is http://restlet-discuss.1400322.n2.nabble.com/Servlet-Filter-using-request-getParameter-loses-Form-data-td2141035.html

Upvotes: 1

Related Questions