添加链接
link之家
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
Collectives™ on Stack Overflow

Find centralized, trusted content and collaborate around the technologies you use most.

Learn more about Collectives

Teams

Q&A for work

Connect and share knowledge within a single location that is structured and easy to search.

Learn more about Teams

I try to configure the Apereo CAS 5.0.6 REST API and I have and when I send a POST request to get a TGT, I got this error :

WARN [org.apereo.cas.authentication.PolicyBasedAuthenticationManager] - 
<Authentication has failed. Credentials may be incorrect or CAS cannot find authentication
handler that supports [username] of type [UsernamePasswordCredential], which suggests a configuration problem.>

I have tried this with RESTED on Firefox :

  • URL : https://cas.services/cas/v1/tickets
  • Method : POST
  • Headers : Content-Type application/x-www-form-urlencoded
  • Request body : URLEncoded form data (with username and password form fields)
  • And I have 401 too.

    I use the Docker image apereo/cas:v5.0.6.

    My pom.xml :

    <dependency>
        <groupId>org.apereo.cas</groupId>
        <artifactId>cas-server-webapp</artifactId>
        <version>${cas.version}</version>
        <type>war</type>
        <scope>runtime</scope>
    </dependency>
    <dependency>
        <groupId>org.apereo.cas</groupId>
        <artifactId>cas-server-support-spnego-webflow</artifactId>
        <version>${cas.version}</version>
    </dependency>
    <dependency>
        <groupId>org.apereo.cas</groupId>
        <artifactId>cas-server-support-rest</artifactId>
        <version>${cas.version}</version>
        <scope>runtime</scope>
    </dependency>
    <dependency>
        <groupId>org.samba.jcifs</groupId>
        <artifactId>jcifs-ext</artifactId>
        <version>0.9.4</version>
        <scope>runtime</scope>
    </dependency>
    

    The authentication works when I go to https://cas.services/cas/ with Firefox

    Thanks for contributing an answer to Stack Overflow!

    • Please be sure to answer the question. Provide details and share your research!

    But avoid

    • Asking for help, clarification, or responding to other answers.
    • Making statements based on opinion; back them up with references or personal experience.

    To learn more, see our tips on writing great answers.