CAS客户端链接报错

CAS客户端链接报错,如:

javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException:

PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException:

unable to find valid certification path to requested target


原因是证书不对,安装证书步骤:


1. Copy下面的代码,执行下面main函数

2. main函数有一个参数,cas IP地址和端口  如:127.0.0.1:443

3. 执行中间输入 :1

4:当你输入"1"后,InstallCert.java 会显示证书的有关信息,然后把证书导入到一个名为"jssecacerts"的keystore中(当前目录),只需要把这个文件拷贝到 JAVA_HOME/jre/lib/security目录中,重命名为"cacerts".


/*
* Copyright 2006 Sun Microsystems, Inc. All Rights Reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* - Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* - Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* - Neither the name of Sun Microsystems nor the names of its
* contributors may be used to endorse or promote products deriv
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
CAS(Central Authentication Service)是一种单点登录(SSO)协议,用于实现在多个应用系统中共享用户登录状态的功能。CAS客户文档Java是指CAS协议的Java客户的使用文档。 CAS客户文档Java主要包括以下内容: 1. 安装和配置:首先需要将CAS客户的Java库文件导入到项目中,并配置必要的参数,如CAS服务器地址、服务口等。 2. 登录和认证:CAS客户提供了一套API接口,用于用户登录认证。开发者可以通过调用这些接口实现用户登录功能。用户登录后,CAS客户会将用户信息保存在本地的会话中,以便在后续的请求中进行身份验证。 3. 单点登录(SSO):CAS客户能够与CAS服务器进行通信,实现跨应用系统的单点登录功能。用户只需要登录一次,即可在多个应用系统中共享登录状态,无需再次输入用户名和密码。 4. 会话管理:CAS客户还提供了一套会话管理机制,用于管理用户登录状态。开发者可以通过这些机制来管理用户的登录会话、注销会话等。 5. 安全机制:CAS客户实现了一套安全机制,用于保护用户的登录状态和用户信息的安全性。开发者可以根据需要进行配置,以确保用户数据的安全。 通过阅读CAS客户文档Java,开发者可以了解CAS客户的基本原理和使用方法,能够更好地使用CAS客户来实现单点登录功能,提升系统的用户登录体验和安全性。同时,该文档还提供了示例代码和常见问题解答,方便开发者快速上手和解决问题。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值