CN104410674A - 一种单点登录系统的web会话同步方法 - Google Patents

一种单点登录系统的web会话同步方法 Download PDF

Info

Publication number
CN104410674A
CN104410674A CN201410640808.6A CN201410640808A CN104410674A CN 104410674 A CN104410674 A CN 104410674A CN 201410640808 A CN201410640808 A CN 201410640808A CN 104410674 A CN104410674 A CN 104410674A
Authority
CN
China
Prior art keywords
session
application system
time
user
subsystem
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201410640808.6A
Other languages
English (en)
Other versions
CN104410674B (zh
Inventor
袁炯钟
杨松
季统凯
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
G Cloud Technology Co Ltd
Original Assignee
G Cloud Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by G Cloud Technology Co Ltd filed Critical G Cloud Technology Co Ltd
Priority to CN201410640808.6A priority Critical patent/CN104410674B/zh
Publication of CN104410674A publication Critical patent/CN104410674A/zh
Application granted granted Critical
Publication of CN104410674B publication Critical patent/CN104410674B/zh
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/143Termination or inactivation of sessions, e.g. event-controlled end of session
    • H04L67/145Termination or inactivation of sessions, e.g. event-controlled end of session avoiding end of session, e.g. keep-alive, heartbeats, resumption message or wake-up for inactive or interrupted session
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/08Network architectures or network communication protocols for network security for authentication of entities
    • H04L63/0815Network architectures or network communication protocols for network security for authentication of entities providing single-sign-on or federations

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Hardware Design (AREA)
  • Computer Security & Cryptography (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Cardiology (AREA)
  • General Health & Medical Sciences (AREA)
  • Information Transfer Between Computers (AREA)
  • Computer And Data Communications (AREA)

Abstract

本发明涉及用户管理技术领域,特别是指一种单点登录系统的WEB会话同步方法。本发明首先用户子系统把会话的sessionId传给应用系统;然后应用系统定时发送到用户子系统检测此会话是否正常并刷新会话;接着用户子系统监听会话状态,会话超时及时通知应用系统;最后用户访问应用系统根据会话状态确定是直接访问还是跳到登录页面。本发明保证单点登录后的应用系统在活跃状态下,用户保持登录的状态,同时在用户子系统或应用系统中操作引起的状态改变能更新到其他系统中;可以用于用户子系统与应用系统间的会话。

Description

一种单点登录系统的WEB会话同步方法
技术领域
本发明涉及用户管理技术领域,特别是指一种单点登录系统的WEB会话同步方法。
背景技术
单点登录(Single Sign On),简称为SSO,是目前比较流行的企业业务整合的解决方案之一。SSO的定义是在多个应用系统中,用户只需要登录一次就可以访问所有相互信任的应用系统。它包括可以将这次主要的登录映射到其他应用中用于同一个用户的登录的机制。
当用户第一次访问应用系统1的时候,因为还没有登录,会被引导到用户子系统中进行登录;根据用户提供的登录信息,用户子系统进行身份效验,如果通过效验,应该返回给用户一个认证的凭据--sessionId;用户再访问别的应用的时候就会将这个sessionId带上,作为自己认证的凭据,应用系统接受到请求之后会把sessionId送到用户子系统进行效验,检查sessionId的合法性。如果通过效验,用户就可以在不用再次登录的情况下访问应用系统2和应用系统3了。
然而,在WEB服务器上,会话都会存在一个过期的时间。用户子系统或应用系统操作这个过期时间没有进行操作的话,sessionId会失效,也就是认证会不通过。目前,在用户子系统和应用系统的会话同步上,面临以下几个问题:
1、登录到应用系统后,一般不再访问用户子系统,长时间不访问用户子系统会导致在其中的会话超时,sessionId失效,这时候再访问应用系统,会被重定向到登录页面,没有单点登录的效果;
2、在用户子系统中用户会话超时以后,用户的在线状态没有被更新到应用系统中。
发明内容
本发明解决的技术问题在于提供一种单点登录系统的WEB会话同步方法,解决了用户管理领域里单点登录会话超时、用户状态不同步等相关问题。
本发明解决上述技术问题的技术方案是:
所述的方法包括如下步骤:
步骤1:在用户子系统登录成功以后,重定向到应用系统的登录成功页面时将用户子系统的sessionId反馈到应用系统,应用系统将此sessionId和登录时间作为上次会话接口访问时间加入到应用系统的会话列表中;
步骤2:在用户子系统中设置一个会话检测与刷新接口,在应用系统中设置一个定时器定期访问会话检测与刷新接口,如果当前的时间到上次会话接口访问的时间间隔达到设定的同步时间,那么检测用户子系统中sessionId是否正常,如果正常,更新上次会话接口访问的时间为当前时间;如果不正常,则从应用系统会话列表中删除此sessionId;
步骤3:在用户子系统中设置一个监听器,在用户子系统的会话超时,更新用户状态信息并通知应用系统,应用系统将会话列表中此sessionId删除;
步骤4:用户再访问应用系统时,若应用系统会话列表没有sessionId,重定向到登录界面,重新进行登录操作。
所述的单点登录系统模型是由一个用户子系统和N个应用系统组成;用户子系统负责统一维护各应用系统的用户基本信息、用户权限信息,应用系统负责具体的业务处理。
所述的用户子系统和应用系统有各自的session和session超时时间,通常应用系统在第一次使用时登录用户子系统进行用户身份鉴别和权限验证,之后只要应用系统不退出并正常使用则不会再去访问用户子系统;
所述的系统session超时时间,通常设置用户子系统的session超时时间大于等于应用系统的session超时时间。
所述的用户子系统会话刷新,当应用系统带着用户子系统的sessionId访问用户子系统即完成该用户的会话刷新,会话超时时间重新计算。
本发明方案的有益效果如下:
1、本发明的方法可以维持活跃的应用系统的登录状态,不会因为不对用户子系统进行操作而导致会话超时;
2、本发明的方法能保证用户子系统的会话状态与应用系统保持一致,能实现整个单点登录系统的会话同步。
附图说明
下面结合附图对本发明进一步说明:
图1为本发明的流程图;
图2为本发明的模型架构图;
具体实施方式
见附图1、2所示,本发明用户子系统负责保存用户基本信息、权限信息、系统登入登出,应用系统负责具体的业务处理。
(1)用户子系统用户登录时的loginJudge方法把用户子系统的sessionId传到应用系统;
Struts.xml配置文件配置登录后调用应用系统的loginNotify把sessionId传到应用系统
(2)应用系统的loginNotify方法把用户子系统的sessionId保存在MapSsoSession类中,MapSsoSession类主要保存应用系统的sessionId和用户子系统的sessionId的对应关系;
(3)用户子系统提供session检测和刷新接口refreshSession.do;
(4)应用系统的定时任务SsoSessionTimer;
(5)用户子系统会话超时,定义监听器OnlineUserListener,更新用户在线状态信息以便应用系统及时改变用户状态;

Claims (5)

1.一种单点登录系统的WEB会话同步方法,其特征在于:所述的方法包括如下步骤:
步骤1:在用户子系统登录成功以后,重定向到应用系统的登录成功页面时将用户子系统的sessionId反馈到应用系统,应用系统将此sessionId和登录时间作为上次会话接口访问时间加入到应用系统的会话列表中;
步骤2:在用户子系统中设置一个会话检测与刷新接口,在应用系统中设置一个定时器定期访问会话检测与刷新接口,如果当前的时间到上次会话接口访问的时间间隔达到设定的同步时间,那么检测用户子系统中sessionId是否正常,如果正常,更新上次会话接口访问的时间为当前时间;如果不正常,则从应用系统会话列表中删除此sessionId;
步骤3:在用户子系统中设置一个监听器,在用户子系统的会话超时,更新用户状态信息并通知应用系统,应用系统将会话列表中此sessionId删除;
步骤4:用户再访问应用系统时,若应用系统会话列表没有sessionId,重定向到登录界面,重新进行登录操作。
2.根据权利要求1所述的一种单点登录系统的WEB会话同步方法,其特征在于:所述的单点登录系统模型是由一个用户子系统和N个应用系统组成;用户子系统负责统一维护各应用系统的用户基本信息、用户权限信息,应用系统负责具体的业务处理。
3.根据权利要求1所述的一种单点登录系统的WEB会话同步方法,其特征在于:所述的用户子系统和应用系统有各自的session和session超时时间,通常应用系统在第一次使用时登录用户子系统进行用户身份鉴别和权限验证,之后只要应用系统不退出并正常使用则不会再去访问用户子系统;
所述的系统session超时时间,通常设置用户子系统的session超时时间大于等于应用系统的session超时时间。
4.根据权利要求2所述的一种单点登录系统的WEB会话同步方法,其特征在于:所述的用户子系统和应用系统有各自的session和session超时时间,通常应用系统在第一次使用时登录用户子系统进行用户身份鉴别和权限验证,之后只要应用系统不退出并正常使用则不会再去访问用户子系统;
所述的系统session超时时间,通常设置用户子系统的session超时时间大于等于应用系统的session超时时间。
5.根据权利要求1至4任一项所述的一种单点登录系统的WEB会话同步方法,其特征在于:所述的用户子系统会话刷新,当应用系统带着用户子系统的sessionId访问用户子系统即完成该用户的会话刷新,会话超时时间重新计算。
CN201410640808.6A 2014-11-12 2014-11-12 一种单点登录系统的web会话同步方法 Active CN104410674B (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410640808.6A CN104410674B (zh) 2014-11-12 2014-11-12 一种单点登录系统的web会话同步方法

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410640808.6A CN104410674B (zh) 2014-11-12 2014-11-12 一种单点登录系统的web会话同步方法

Publications (2)

Publication Number Publication Date
CN104410674A true CN104410674A (zh) 2015-03-11
CN104410674B CN104410674B (zh) 2018-04-10

Family

ID=52648272

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410640808.6A Active CN104410674B (zh) 2014-11-12 2014-11-12 一种单点登录系统的web会话同步方法

Country Status (1)

Country Link
CN (1) CN104410674B (zh)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106506227A (zh) * 2016-11-29 2017-03-15 深圳天珑无线科技有限公司 配置更新方法和配置更新装置
CN107995214A (zh) * 2017-12-19 2018-05-04 深圳市创梦天地科技股份有限公司 一种网站登录方法及相关设备
CN108683675A (zh) * 2018-05-23 2018-10-19 南京联创信息科技有限公司 基于sso延长会话时长的报活方法
CN108965332A (zh) * 2018-08-29 2018-12-07 北京航天云路有限公司 多站点用户登录状态同步方法及系统
CN109274662A (zh) * 2018-09-06 2019-01-25 北京天元创新科技有限公司 防止cas服务器被动销毁会话的方法、装置、服务器及终端
CN110557396A (zh) * 2019-09-09 2019-12-10 苏宁消费金融有限公司 一种h5客户端之间登录会话统一方法和系统
CN110933029A (zh) * 2019-10-24 2020-03-27 杭州数梦工场科技有限公司 基于统一认证的信息同步方法、装置及设备
CN111083127A (zh) * 2019-12-05 2020-04-28 达闼科技成都有限公司 会话管理方法、电子设备及计算机可读存储介质
CN114363395A (zh) * 2021-12-31 2022-04-15 深圳金蝶账无忧网络科技有限公司 会话处理方法、装置及计算机可读存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050131966A1 (en) * 2003-12-15 2005-06-16 Sbc Knowledge Ventures, L.P. Architecture of database application with robust online recoverability
CN101075875A (zh) * 2007-06-14 2007-11-21 中国电信股份有限公司 在门户/系统之间实现单点登录的方法及其系统
CN101222335A (zh) * 2008-02-02 2008-07-16 国电信息中心 一种应用系统间的级联认证方法及装置
CN101605030A (zh) * 2008-06-13 2009-12-16 新奥特(北京)视频技术有限公司 一种面向电视台应用的基于Active Directory的统一认证实现方法

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050131966A1 (en) * 2003-12-15 2005-06-16 Sbc Knowledge Ventures, L.P. Architecture of database application with robust online recoverability
CN101075875A (zh) * 2007-06-14 2007-11-21 中国电信股份有限公司 在门户/系统之间实现单点登录的方法及其系统
CN101222335A (zh) * 2008-02-02 2008-07-16 国电信息中心 一种应用系统间的级联认证方法及装置
CN101605030A (zh) * 2008-06-13 2009-12-16 新奥特(北京)视频技术有限公司 一种面向电视台应用的基于Active Directory的统一认证实现方法

Cited By (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106506227A (zh) * 2016-11-29 2017-03-15 深圳天珑无线科技有限公司 配置更新方法和配置更新装置
CN107995214A (zh) * 2017-12-19 2018-05-04 深圳市创梦天地科技股份有限公司 一种网站登录方法及相关设备
CN108683675B (zh) * 2018-05-23 2019-06-18 南京联创信息科技有限公司 基于sso延长会话时长的报活方法
CN108683675A (zh) * 2018-05-23 2018-10-19 南京联创信息科技有限公司 基于sso延长会话时长的报活方法
CN108965332B (zh) * 2018-08-29 2021-05-04 北京航天云路有限公司 多站点用户登录状态同步方法及系统
CN108965332A (zh) * 2018-08-29 2018-12-07 北京航天云路有限公司 多站点用户登录状态同步方法及系统
CN109274662A (zh) * 2018-09-06 2019-01-25 北京天元创新科技有限公司 防止cas服务器被动销毁会话的方法、装置、服务器及终端
CN109274662B (zh) * 2018-09-06 2021-06-04 北京天元创新科技有限公司 防止cas服务器被动销毁会话的方法、装置、服务器及终端
CN110557396A (zh) * 2019-09-09 2019-12-10 苏宁消费金融有限公司 一种h5客户端之间登录会话统一方法和系统
CN110557396B (zh) * 2019-09-09 2022-03-15 苏宁消费金融有限公司 一种h5客户端之间登录会话统一方法和系统
CN110933029A (zh) * 2019-10-24 2020-03-27 杭州数梦工场科技有限公司 基于统一认证的信息同步方法、装置及设备
CN111083127A (zh) * 2019-12-05 2020-04-28 达闼科技成都有限公司 会话管理方法、电子设备及计算机可读存储介质
CN111083127B (zh) * 2019-12-05 2021-11-09 达闼机器人有限公司 会话管理方法、电子设备及计算机可读存储介质
CN114363395A (zh) * 2021-12-31 2022-04-15 深圳金蝶账无忧网络科技有限公司 会话处理方法、装置及计算机可读存储介质

Also Published As

Publication number Publication date
CN104410674B (zh) 2018-04-10

Similar Documents

Publication Publication Date Title
CN104410674A (zh) 一种单点登录系统的web会话同步方法
US10740353B2 (en) Systems and methods for managing distributed database deployments
US10205760B2 (en) Task coordination in distributed systems
US10713280B2 (en) Systems and methods for managing distributed database deployments
US10965772B2 (en) Interface invocation method and apparatus for hybrid cloud
EP3766203B1 (en) Autonomous secrets renewal and distribution
US10819701B2 (en) Autonomous secrets management for a managed service identity
US20170286516A1 (en) Systems and methods for managing distributed database deployments
US8903917B2 (en) System and method for implementing a cluster token registry for business continuity
CN106664302B (zh) 使用信令撤销会话的方法和系统
EP3765982B1 (en) Autonomous cross-scope secrets management
US9680821B2 (en) Resource access control for virtual machines
US20190286813A1 (en) Autonomous secrets management for a temporary shared access signature service
US9985970B2 (en) Individualized audit log access control for virtual machines
CN105049427A (zh) 应用系统登录账号的管理方法及装置
US9635024B2 (en) Methods for facilitating improved user authentication using persistent data and devices thereof
US11146443B2 (en) Techniques for accessing logical networks via a virtualized gateway
CN103152351A (zh) 网络设备、ad 域单点登录的方法及系统
WO2012162952A1 (zh) 凭据认证方法及单点登录服务器
AU2012319193B2 (en) Techniques for accessing logical networks via a programmatic service call
US20220269769A1 (en) Delegating multi-factor authentication in legacy databases
CN118200396A (zh) 一种基于Kubernetes集群的请求响应方法
Kim et al. Intrusion-Tolerant Jini Service Architecture for Ensuring Survivability of U-Services Based on WSN

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CP02 Change in the address of a patent holder
CP02 Change in the address of a patent holder

Address after: 523808 19th Floor, Cloud Computing Center, Chinese Academy of Sciences, No. 1 Kehui Road, Songshan Lake Hi-tech Industrial Development Zone, Dongguan City, Guangdong Province

Patentee after: G-Cloud Technology Co., Ltd.

Address before: 523808 No. 14 Building, Songke Garden, Songshan Lake Science and Technology Industrial Park, Dongguan City, Guangdong Province

Patentee before: G-Cloud Technology Co., Ltd.