[go: up one dir, main page]

CN104580406A - Method and device for synchronizing login status - Google Patents

Method and device for synchronizing login status Download PDF

Info

Publication number
CN104580406A
CN104580406A CN201410815961.8A CN201410815961A CN104580406A CN 104580406 A CN104580406 A CN 104580406A CN 201410815961 A CN201410815961 A CN 201410815961A CN 104580406 A CN104580406 A CN 104580406A
Authority
CN
China
Prior art keywords
session information
login session
login
local
web page
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
CN201410815961.8A
Other languages
Chinese (zh)
Other versions
CN104580406B (en
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.)
Beijing Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and 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 Beijing Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN201410815961.8A priority Critical patent/CN104580406B/en
Publication of CN104580406A publication Critical patent/CN104580406A/en
Priority to PCT/CN2015/087219 priority patent/WO2016101635A1/en
Application granted granted Critical
Publication of CN104580406B publication Critical patent/CN104580406B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/40Support for services or applications
    • 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
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/10Network architectures or network communication protocols for network security for controlling access to devices or network resources

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)
  • Multimedia (AREA)
  • Information Transfer Between Computers (AREA)
  • Computer And Data Communications (AREA)

Abstract

本发明提供了一种同步登录状态的方法和装置,web页面被加载时,该web页面上的执行模块向本地http服务模块发送获取登录会话信息的请求;本地http服务模块接收到该请求后,确定登录会话信息所在的本地应用,从登录会话信息所在的本地应用获取当前登录用户的登录会话信息,将获取的登录会话信息返回给web页面上的执行模块;web页面上的执行模块利用登录会话信息进行自动登录。本发明能够将本地应用的登录状态同步至其他本地应用所加载的页面上,只要智能终端中存在本地应用处于登录状态,那么当用户在智能终端中打开与该本地应用属于同一账户系统域名的web页面都能够实现自动登录,减少用户操作,提升用户体验。

The present invention provides a method and device for synchronizing login status. When a web page is loaded, the execution module on the web page sends a request for obtaining login session information to the local http service module; after the local http service module receives the request, Determine the local application where the login session information is located, obtain the login session information of the currently logged-in user from the local application where the login session information is located, and return the obtained login session information to the execution module on the web page; the execution module on the web page uses the login session information to log in automatically. The present invention can synchronize the login state of the local application to the pages loaded by other local applications. As long as there is a local application in the login state in the smart terminal, when the user opens the web page in the smart terminal that belongs to the same account system domain name as the local application All pages can realize automatic login, reduce user operations, and improve user experience.

Description

一种同步登录状态的方法和装置A method and device for synchronizing login status

【技术领域】【Technical field】

本发明涉及计算机应用技术领域,特别涉及一种同步登录状态的方法和装置。The invention relates to the technical field of computer applications, in particular to a method and device for synchronizing login status.

【背景技术】【Background technique】

目前大多数大型互联网服务提供商向智能终端既提供web app(网络应用)的服务,也提供native app(本地应用)的服务。其中web app是运行于网络和标准浏览器上,基于网页技术开发实现特定功能的应用,native app是基于智能终端的操作系统运行的应用。例如百度公司提供的贴吧、知道是web app的产品,百度手机卫士是native app的产品,很多产品是既存在webapp也存在native app,例如百度地图、百度视频等既可以是web app的产品,也可以是native app的产品。At present, most large Internet service providers provide both web app (network application) services and native app (local application) services to smart terminals. Among them, web app is an application that runs on the network and a standard browser, and is developed based on web technology to realize specific functions, and native app is an application that runs on an operating system based on a smart terminal. For example, Tieba provided by Baidu Company is known to be a web app product. Baidu Mobile Guard is a native app product. Many products exist in both webapp and native app. For example, Baidu Maps, Baidu Video, etc. can be either web app products or It can be a product of native app.

基于上述特征,用户在使用同一服务提供商的不同产品时,通常使用同一账号,但需要分别在各产品上分别登录,这显然给用户操作带来了麻烦和不便,因此趋势是希望能够使得用户在使用同一服务提供商的不同产品时,能够自动同步登录状态到不同产品。Based on the above characteristics, when users use different products of the same service provider, they usually use the same account, but they need to log in separately on each product, which obviously brings trouble and inconvenience to user operations. Therefore, the trend is to enable users to When using different products of the same service provider, the login status can be automatically synchronized to different products.

目前已经实现的是在同一个native app中相同服务提供商的不同产品之间的登录状态同步,例如用户在百度手机浏览器中登录账户后,就可以将登录状态同步给所有在百度手机浏览器中打开的百度产品线的web页面。其实现方案是浏览器将用户的登录会话信息记录在针对该用户账户的系统域名所对应的用户cookie文件中,从而使得当该域名下的web页面在该浏览器中被加载时,能够直接从cookie中获取登录会话信息,利用该登录会话信息进行自动登录。由于多数操作系统出于安全性考虑,都会为每个应用进程单独维护一份独立的cookie数据,不同应用进程的cookie数据是不能互通的,因此无法实现native app的登录状态同步至其他native app所加载的页面上。What has been realized so far is the synchronization of login status between different products of the same service provider in the same native app. The web page of the Baidu product line opened in . The solution is that the browser records the user's login session information in the user cookie file corresponding to the system domain name of the user account, so that when the web page under the domain name is loaded in the browser, it can be directly accessed from the The login session information is obtained from the cookie, and the login session information is used for automatic login. Because most operating systems maintain an independent cookie data for each application process for security reasons, the cookie data of different application processes cannot communicate with each other, so it is impossible to synchronize the login status of the native app to that of other native apps. on the loaded page.

【发明内容】【Content of invention】

有鉴于此,本发明提供了一种同步登录状态的方法和装置,以便于实现将native app的登录状态同步至其他native app所加载的页面上。In view of this, the present invention provides a method and device for synchronizing the login status, so as to realize the synchronization of the login status of the native app to the pages loaded by other native apps.

具体技术方案如下:The specific technical scheme is as follows:

一种同步登录状态的方法,该方法包括:A method of synchronizing login status, the method comprising:

web页面被加载时,该web页面上的执行模块向本地http服务模块发送获取登录会话信息的请求;When the web page is loaded, the execution module on the web page sends a request to obtain login session information to the local http service module;

本地http服务模块接收到获取登录会话信息的请求后,确定登录会话信息所在的本地应用,从登录会话信息所在的本地应用获取当前登录用户的登录会话信息,将获取的登录会话信息返回给所述web页面上的执行模块;After the local http service module receives the request for obtaining the login session information, it determines the local application where the login session information is located, obtains the login session information of the currently logged-in user from the local application where the login session information is located, and returns the obtained login session information to the The execution module on the web page;

所述web页面上的执行模块利用所述登录会话信息进行自动登录。The execution module on the web page uses the login session information to perform automatic login.

根据本发明一优选实施方式,该方法还包括:所述本地http服务模块所在的本地应用启动后,初始化所述本地http服务模块以使所述本地http服务模块侦听预设的本地网络端口;According to a preferred embodiment of the present invention, the method further includes: after the local application where the local http service module is located is started, initializing the local http service module so that the local http service module listens to a preset local network port;

所述web页面上的执行模块向本地http服务模块发送获取登录会话信息的请求包括:所述web页面上的执行模块向所述预设的本地网络端口发送所述获取登录会话信息的请求。The execution module on the web page sending the request for obtaining login session information to the local http service module includes: the execution module on the web page sending the request for obtaining login session information to the preset local network port.

根据本发明一优选实施方式,所述确定登录会话信息所在的本地应用包括:According to a preferred embodiment of the present invention, the local application for determining where the login session information is located includes:

所述本地http服务模块依据所述获取登录会话信息的请求包含的应用标识信息,确定所述应用标识信息对应的本地应用。The local http service module determines the local application corresponding to the application identification information according to the application identification information included in the request for obtaining login session information.

根据本发明一优选实施方式,所述确定登录会话信息所在的本地应用还包括:According to a preferred embodiment of the present invention, the local application for determining where the login session information is located further includes:

如果所述获取登录会话信息的请求不包含所述应用标识信息,则所述本地http服务模块依据预设的配置信息,确定登录会话信息所在的本地应用。If the request for obtaining login session information does not include the application identification information, the local http service module determines the local application where the login session information resides according to preset configuration information.

根据本发明一优选实施方式,所述获取登录会话信息的请求包括JS回调函数信息;According to a preferred embodiment of the present invention, the request for obtaining login session information includes JS callback function information;

所述将获取的登录会话信息返回给所述web页面上的执行模块包括:利用获取的登录会话信息和所述JS回调函数信息生成执行代码,将所述执行代码返回给所述web页面上的执行模块;The returning the obtained login session information to the execution module on the web page includes: generating execution code by using the obtained login session information and the JS callback function information, and returning the execution code to the execution module on the web page execution module;

所述web页面上的执行模块利用所述登录会话信息进行自动登录包括:所述web页面上的执行模块执行所述执行代码以完成自动登录。The automatic login by the execution module on the web page using the login session information includes: the execution module on the web page executes the execution code to complete the automatic login.

根据本发明一优选实施方式,在所述确定登录会话信息所在的本地应用之前,还包括:According to a preferred embodiment of the present invention, before the local application where the login session information is determined, it further includes:

本地http服务模块判断所述获取登录会话信息的请求的refer来源地址是否在预设的域名范围内,如果是,则继续执行所述确定登录会话信息所在的本地应用;否则,拒绝响应所述web页面上的执行模块或者向所述web页面上的执行模块返回指示错误的信息。The local http service module judges whether the refer source address of the request for obtaining the login session information is within the preset domain name range, and if so, continues to execute the local application where the login session information is determined; otherwise, refuses to respond to the web The execution module on the page returns or returns information indicating an error to the execution module on the web page.

根据本发明一优选实施方式,在所述从登录会话信息所在的本地应用获取当前登录用户的登录会话信息之前还包括:According to a preferred embodiment of the present invention, before obtaining the login session information of the currently logged-in user from the local application where the login session information is located, further includes:

所述本地http服务模块通过调用系统接口判断登录会话信息所在的本地应用是否已经安装在本地,如果是,继续执行所述从登录会话信息所在的本地应用获取当前登录用户的登录会话信息;否则,向所述web页面上的执行模块返回指示错误的信息。The local http service module judges whether the local application where the login session information is located has been installed locally by calling the system interface, and if so, continues to execute the acquisition of the login session information of the currently logged-in user from the local application where the login session information is located; otherwise, Returning information indicating an error to an execution module on the web page.

根据本发明一优选实施方式,所述从登录会话信息所在的本地应用获取当前登录用户的登录会话信息包括:According to a preferred embodiment of the present invention, the obtaining the login session information of the currently logged-in user from the local application where the login session information is located includes:

如果所述本地http服务模块所在的本地应用与所述登录会话信息所在的本地应用是同一个应用,则所述本地http服务模块通过进程内通信的方式向位于同一本地应用的会话信息维护模块发送请求,并获取该会话信息维护模块返回的当前登录用户的登录会话信息;或者,If the local application where the local http service module is located is the same application as the local application where the login session information is located, then the local http service module sends request, and obtain the login session information of the currently logged-in user returned by the session information maintenance module; or,

如果所述本地http服务模块所在的本地应用与所述登录会话信息所在的本地应用是不同的应用,则所述本地http服务模块通过进程间通信的方式向所述登录会话信息所在的本地应用中的会话信息维护模块发送请求,并获取该会话信息维护模块返回的当前登录用户的登录会话信息。If the local application where the local http service module is located is a different application from the local application where the login session information is located, then the local http service module sends a message to the local application where the login session information is located through inter-process communication. The session information maintenance module sends a request, and obtains the login session information of the currently logged-in user returned by the session information maintenance module.

根据本发明一优选实施方式,该方法还包括:According to a preferred embodiment of the present invention, the method also includes:

所述web页面上的执行模块自动登录后,将登录状态信息和登录会话信息存储于web页面所在的本地应用的cookie中。After the execution module on the web page logs in automatically, it stores the login status information and the login session information in the cookie of the local application where the web page is located.

根据本发明一优选实施方式,所述web页面上的执行模块向本地http服务模块发送获取登录会话信息的请求之前,还包括:According to a preferred embodiment of the present invention, before the execution module on the web page sends a request to obtain login session information to the local http service module, it also includes:

判断所述web页面所在本地应用的cookie中是否存在对应的登录会话信息,如果是,使用所述web页面所在的本地应用的cookie中对应的登录会话信息进行登录;否则执行所述向本地http服务模块发送获取登录会话信息的请求。Determine whether there is corresponding login session information in the cookie of the local application where the web page is located, and if so, use the corresponding login session information in the cookie of the local application where the web page is located to log in; The module sends a request to get login session information.

本发明还提供了一种同步登录状态的装置,该装置包括:The present invention also provides a device for synchronizing login status, which device includes:

web页面上的执行模块,用于当web页面被加载时,向本地http服务模块发送获取登录会话信息的请求;利用本地http服务模块返回的登录会话信息进行自动登录;The execution module on the web page is used to send a request for obtaining login session information to the local http service module when the web page is loaded; use the login session information returned by the local http service module to perform automatic login;

本地http服务模块,用于接收到获取登录会话信息的请求后,确定登录会话信息所在的本地应用,从登录会话信息所在的本地应用获取当前登录用户的登录会话信息,将获取的登录会话信息返回给所述web页面上的执行模块。The local http service module is used to determine the local application where the login session information is located after receiving the request for obtaining the login session information, obtain the login session information of the currently logged-in user from the local application where the login session information is located, and return the obtained login session information to the execution module on said web page.

根据本发明一优选实施方式,所述本地http服务模块,用于被所在的本地应用初始化后,侦听预设的本地网络端口;According to a preferred embodiment of the present invention, the local http service module is configured to listen to a preset local network port after being initialized by the local application;

所述web页面上的执行模块,具体用于向所述预设的本地网络端口发送所述获取登录会话信息的请求。The execution module on the web page is specifically configured to send the request for obtaining login session information to the preset local network port.

根据本发明一优选实施方式,所述本地http服务模块在确定登录会话信息所在的本地应用时,具体用于依据所述获取登录会话信息的请求包含的应用标识信息,确定所述应用标识信息对应的本地应用。According to a preferred embodiment of the present invention, when the local http service module determines the local application where the login session information is located, it is specifically configured to determine the application identification information corresponding to the application identification information according to the application identification information contained in the request for obtaining the login session information. native applications.

根据本发明一优选实施方式,所述本地http服务模块,还用于如果所述获取登录会话信息的请求不包含所述应用标识信息,则依据预设的配置信息,确定登录会话信息所在的本地应用。According to a preferred embodiment of the present invention, the local http service module is further configured to, if the request for obtaining login session information does not include the application identification information, determine the local URL where the login session information is located according to preset configuration information. application.

根据本发明一优选实施方式,所述本地http服务模块在将获取的登录会话信息返回给所述web页面上的执行模块时,具体执行:利用获取的登录会话信息和所述获取登录会话信息的请求中包含的JS回调函数信息生成执行代码,将所述执行代码返回给所述web页面上的执行模块;According to a preferred embodiment of the present invention, when the local http service module returns the obtained login session information to the execution module on the web page, it specifically executes: using the obtained login session information and the method of obtaining the login session information The JS callback function information contained in the request generates execution code, and returns the execution code to the execution module on the web page;

所述web页面上的执行模块,具体用于执行所述执行代码以完成自动登录。The execution module on the web page is specifically configured to execute the execution code to complete automatic login.

根据本发明一优选实施方式,本地http服务模块,还用于在确定登录会话信息所在的本地应用之前,判断所述获取登录会话信息的请求的refer来源地址是否在预设的域名范围内,如果是,则继续执行所述确定登录会话信息所在的本地应用;否则,拒绝响应所述web页面上的执行模块或者向所述web页面上的执行模块返回指示错误的信息。According to a preferred embodiment of the present invention, the local http service module is further configured to determine whether the refer source address of the request for obtaining the login session information is within the preset domain name range before determining the local application where the login session information is located. If yes, continue to execute the local application where the login session information is determined; otherwise, refuse to respond to the execution module on the web page or return information indicating an error to the execution module on the web page.

根据本发明一优选实施方式,所述本地http服务模块在从登录会话信息所在的本地应用获取当前登录用户的登录会话信息之前还用于,通过调用系统接口判断登录会话信息所在的本地应用是否已经安装在本地,如果是,继续执行所述从登录会话信息所在的本地应用获取当前登录用户的登录会话信息;否则,向所述web页面上的执行模块返回指示错误的信息。According to a preferred embodiment of the present invention, before the local http service module obtains the login session information of the currently logged-in user from the local application where the login session information is located, it is also used to determine whether the local application where the login session information is If it is installed locally, if so, continue to execute the acquisition of the login session information of the currently logged-in user from the local application where the login session information is located; otherwise, return information indicating an error to the execution module on the web page.

根据本发明一优选实施方式,该装置还包括会话信息维护模块;According to a preferred embodiment of the present invention, the device further includes a session information maintenance module;

所述本地http服务模块在从登录会话信息所在的本地应用获取当前登录用户的登录会话信息时,具体执行:如果所述本地http服务模块所在的本地应用与所述登录会话信息所在的本地应用是同一个应用,则通过进程内通信的方式向位于同一本地应用的会话信息维护模块发送请求,并获取该会话信息维护模块返回的当前登录用户的登录会话信息;或者,如果所述本地http服务模块所在的本地应用与所述登录会话信息所在的本地应用是不同的应用,则通过进程间通信的方式向所述登录会话信息所在的本地应用中的会话信息维护模块发送请求,并获取该会话信息维护模块返回的当前登录用户的登录会话信息;When the local http service module obtains the login session information of the currently logged-in user from the local application where the login session information is located, it specifically executes: if the local application where the local http service module is located and the local application where the login session information is located are For the same application, send a request to the session information maintenance module located in the same local application through in-process communication, and obtain the login session information of the currently logged-in user returned by the session information maintenance module; or, if the local http service module The local application where the login session information is located and the local application where the login session information is located are different applications, then send a request to the session information maintenance module in the local application where the login session information is located through inter-process communication, and obtain the session information The login session information of the currently logged-in user returned by the maintenance module;

所述会话信息维护模块,用于接收到所述本地http服务模块发送的请求后,向所述本地http服务模块返回该会话信息维护模块所在本地应用中当前登录用户的登录会话信息。The session information maintenance module is configured to return to the local http service module the login session information of the currently logged-in user in the local application where the session information maintenance module is located after receiving the request sent by the local http service module.

根据本发明一优选实施方式,所述web页面上的执行模块,还用于在自动登录后,将登录状态信息和登录会话信息存储于web页面所在的本地应用的cookie中。According to a preferred embodiment of the present invention, the execution module on the web page is further configured to store the login status information and login session information in the cookie of the local application where the web page is located after the automatic login.

根据本发明一优选实施方式,所述web页面上的执行模块,还用于在向本地http服务模块发送获取登录会话信息的请求之前,判断所述web页面所在本地应用的cookie中是否存在对应的登录会话信息,如果是,使用所述web页面所在的本地应用的cookie中对应的登录会话信息进行登录;否则执行所述向本地http服务模块发送获取登录会话信息的请求。According to a preferred embodiment of the present invention, the execution module on the web page is further configured to determine whether there is a corresponding For login session information, if yes, use the corresponding login session information in the cookie of the local application where the web page is located to log in; otherwise, execute the request to send the login session information to the local http service module.

由以上技术方案可以看出,本发明能够将native app的登录状态同步至其他native应用所加载的页面上,只要智能终端中存在native app处于登录状态,那么当用户在智能终端中打开与该native app属于同一账户系统域名的web页面都能够实现自动登录,减少用户操作,提升用户体验。It can be seen from the above technical solutions that the present invention can synchronize the login status of the native app to the pages loaded by other native applications. The web pages of the app belonging to the same account system domain name can be automatically logged in, reducing user operations and improving user experience.

【附图说明】【Description of drawings】

图1为本发明实施例提供的装置结构图;Fig. 1 is the device structural diagram that the embodiment of the present invention provides;

图2为本发明实施例提供的方法流程图。Fig. 2 is a flowchart of a method provided by an embodiment of the present invention.

【具体实施方式】【Detailed ways】

为了使本发明的目的、技术方案和优点更加清楚,下面结合附图和具体实施例对本发明进行详细描述。In order to make the object, technical solution and advantages of the present invention clearer, the present invention will be described in detail below in conjunction with the accompanying drawings and specific embodiments.

为了方便理解首先对本发明提供的装置结构进行介绍,如图1中所示,该装置可以包括:web页面上的执行模块、本地http服务模块以及登录信息维护模块。In order to facilitate understanding, the structure of the device provided by the present invention is first introduced. As shown in FIG. 1 , the device may include: an execution module on a web page, a local http service module, and a login information maintenance module.

其中web页面上的执行模块可以采用Javascript实现,负责在web页面被加载时,向本地http服务模块发送获取登录会话信息的请求。利用本地http服务模块返回的登录会话信息实现在web页面上的登录,并可以进一步将登录会话信息存储于该web页面所在native app的cookie中。The execution module on the web page can be implemented by Javascript, and is responsible for sending a request for obtaining login session information to the local http service module when the web page is loaded. The login session information returned by the local http service module is used to log in on the web page, and the login session information can be further stored in the cookie of the native app where the web page is located.

本地http服务模块内置于某一个native app中,负责接收web页面上的执行模块发送的获取登录会话信息的请求,确定该登录会话信息所在的native app,并向登录会话信息所在的native app发送获取登录会话信息的请求;获取登录会话信息所在的native app返回的登录会话信息,并将获取的登录会话信息返回给web页面上的执行模块。The local http service module is built in a native app, and is responsible for receiving the request for obtaining login session information sent by the execution module on the web page, determining the native app where the login session information is located, and sending the request to the native app where the login session information is located. A request for login session information; obtain the login session information returned by the native app where the login session information is located, and return the obtained login session information to the execution module on the web page.

登录信息维护模块内置于native app中用于维护登录会话信息,并应本地http服务模块的请求向本地http服务模块返回当前登录用户的登录会话信息。The login information maintenance module is built into the native app to maintain the login session information, and returns the login session information of the currently logged-in user to the local http service module in response to the request of the local http service module.

上述登录信息维护模块与本地http服务模块可以位于同一个native app,也可以位于不同native app,上述含执行模块的web页面可以在任何能够加载web页面的native应用内被加载,可以在上述登录信息维护模块所在的native app被加载,也可以在上述本地http服务模块所在的native app被加载,也可以在其他任意native app中被加载。The above-mentioned login information maintenance module and the local http service module can be located in the same native app, or in different native apps. The above-mentioned web page containing the execution module can be loaded in any native application that can load web pages. The native app where the maintenance module is located is loaded, or it can be loaded in the native app where the local http service module is located, or it can be loaded in any other native app.

下面结合图2对本发明提供的方法进行详细描述。图2为本发明实施例提供的方法流程图,如图2中所示,该方法可以包括以下步骤:The method provided by the present invention will be described in detail below with reference to FIG. 2 . Fig. 2 is the flow chart of the method provided by the embodiment of the present invention, as shown in Fig. 2, the method may include the following steps:

在201中,内置有本地http服务模块的native app在启动后,初始化本地http服务模块以侦听预设的本地网络端口。In 201, after the native app with the built-in local http service module is started, the local http service module is initialized to listen to the preset local network port.

本步骤是预先执行的步骤,初始化本地http服务模块后,本地http服务模块就能够对预设的一个本地网络端口进行侦听,接收发送至该本地网络端口的http请求。This step is a pre-executed step. After the local http service module is initialized, the local http service module can listen to a preset local network port and receive http requests sent to the local network port.

在202中,当有某个native app(例如手机浏览器)加载web页面时,web页面上的执行模块向预设的本地网络端口发送获取登录会话信息的http请求。该http请求可以包含登录会话信息所在的应用标识信息(即目标应用的标识信息),还可以包含JS回调函数信息。In 202, when a certain native app (such as a mobile phone browser) loads a web page, the execution module on the web page sends an http request to obtain login session information to a preset local network port. The http request may include application identification information where the login session information resides (that is, identification information of the target application), and may also include JS callback function information.

其中登录会话信息所在的应用标识信息是预先在执行模块中设置好的,一个服务提供商的web页面对应登录会话信息所在的native app也是同一服务提供商的其他产品,即账户采用相同的系统域名,在此可以预先在执行模块中设置登录会话信息所在的应用标识信息。例如,可以在百度地图的web页面上的执行模块中预先设置登录会话信息所在的应用标识信息为百度地图的native app的标识信息,或者百度知道的native app的标识信息等。该应用标识信息可以包括但不限于应用的包名或包签名信息,另外,这里的应用标识信息可以是一个,也可以是多于一个的应用标识信息。The application identification information where the login session information is located is pre-set in the execution module, and the native app where the login session information is located on the web page of a service provider is also another product of the same service provider, that is, the account uses the same system domain name , where the application identification information where the login session information is located can be set in advance in the execution module. For example, the application identification information where the login session information is located can be preset in the execution module on the web page of Baidu Maps as the identification information of the native app of Baidu Maps, or the identification information of the native app known by Baidu. The application identification information may include, but not limited to, the package name or package signature information of the application. In addition, the application identification information here may be one or more than one application identification information.

另外,在本步骤中,加载web页面后,web页面上的执行模块可以首先判断该web页面所在native app的cookie中是否已经存在对应的登录会话信息,如果已经存在,则可以直接利用cookie中的登录会话信息进行登录。如果不存在,再向预设的本地网络端口发送获取登录会话信息的http请求。In addition, in this step, after the web page is loaded, the execution module on the web page can first judge whether the corresponding login session information already exists in the cookie of the native app where the web page is located. Login session information to log in. If it does not exist, send an http request to obtain login session information to the preset local network port.

在203中,本地http服务模块从预设的本地网络端口侦听到上述http请求。In 203, the local http service module listens to the above http request from a preset local network port.

在204中,本地http服务模块判断http请求的合法性,如果是合法请求,继续执行205;如果是非法请求,则直接拒绝响应或者返回指示错误的信息。In 204, the local http service module judges the legitimacy of the http request, if it is a legal request, continue to execute 205; if it is an illegal request, it directly refuses to respond or returns an error message.

本步骤中可以校验http请求的refer(来源地址)是否在预设的域名范围内来判断http请求的合法性,如果http请求的refer不再预设的域名范围内,则确定该http请求非法,如果在预设的域名范围内,则确定该http请求合法。上述域名范围可以预先设置于本地http服务模块中,也可以通过云端下发配置信息的方式对本地http服务模块中的域名范围进行配置。In this step, you can check whether the refer (source address) of the http request is within the preset domain name range to determine the legitimacy of the http request. If the refer of the http request is no longer within the preset domain name range, then determine that the http request is illegal , if it is within the preset domain name range, it is determined that the http request is legal. The above domain name range can be pre-set in the local http service module, or the domain name range in the local http service module can be configured by sending configuration information from the cloud.

本步骤中域名范围的设置通常是为了限制登录状态同步这一方法的应用范围,也可以不进行限制,因此本步骤是一个可选步骤。The setting of the domain name range in this step is usually to limit the scope of application of the login status synchronization method, and it may not be limited, so this step is an optional step.

在205中,确定该http请求获取的登录会话信息所在的native app(即确定目标应用)。In 205, determine the native app where the login session information acquired by the http request resides (that is, determine the target application).

如果http请求中包含登录会话信息所在的应用标识信息,则直接确定该应用标识信息对应的native app。如果http请求中不包含登录会话信息所在的应用标识信息,则本地http服务模块可以根据预设的配置信息确定登录会话信息所在的native app。If the http request includes the application identification information where the login session information is located, directly determine the native app corresponding to the application identification information. If the http request does not include the application identification information where the login session information is located, the local http service module can determine the native app where the login session information is located according to preset configuration information.

这里预设的配置信息可以是默认的native app信息,即如果http请求中不包含应用标识信息,本地http服务模块就采用默认的native app作为登录会话信息所在的native app。例如,百度公司可以设置百度手机助手作为默认native app,一旦接收到的http请求中没有指定目标应用,则将百度手机助手作为目标应用。可以将经常处于登录状态,或者使用率较高的native app作为默认的native app配置于本地http服务模块中。The preset configuration information here can be the default native app information, that is, if the http request does not contain application identification information, the local http service module uses the default native app as the native app where the login session information is located. For example, Baidu can set Baidu Mobile Assistant as the default native app, and if no target application is specified in the received http request, Baidu Mobile Assistant will be used as the target application. A native app that is often logged in or has a high usage rate can be configured in the local http service module as the default native app.

在206中,本地http服务模块通过调用系统接口判断在205中确定的native app是否已经安装在本地,如果是,执行207;否则,返回指示错误的信息。In 206, the local http service module judges whether the native app determined in 205 has been installed locally by calling the system interface, and if so, executes 207; otherwise, returns an error message.

在207中,本地http服务模块向登录会话信息所在的native app发送获取登录会话信息的请求。In 207, the local http service module sends a request for obtaining login session information to the native app where the login session information is located.

如果本地http服务模块所在的native app与登录会话信息所在的nativeapp是同一个app,则本地http服务模块采用进程内通信的方式发送获取登录会话信息的请求给登录会话信息所在的native app。如果本地http服务模块所在的native app与登录会话信息所在的native app是不同的app,则本地http服务模块采用进程间通信的方式发送获取登录会话信息的请求给登录会话信息所在的native app。进程间通信的方式可以采用但不限于管道的方式、共享内存的方式、套接字的方式等。If the native app where the local http service module is located is the same app as the native app where the login session information is located, then the local http service module uses in-process communication to send a request for obtaining login session information to the native app where the login session information is located. If the native app where the local http service module is located is different from the native app where the login session information is located, the local http service module uses inter-process communication to send a request for obtaining login session information to the native app where the login session information is located. The way of inter-process communication can adopt but not limited to the way of pipeline, the way of shared memory, the way of socket and so on.

在208中,登录会话信息所在的native app中登录信息维护模块接收到获取登录会话信息的请求后,将当前登录用户的登录会话信息返回给本地http服务模块。In 208, after receiving the request for obtaining login session information, the login information maintenance module in the native app where the login session information is located returns the login session information of the currently logged in user to the local http service module.

本地http服务模块可以将请求发送至登录会话信息所在的native app的预设端口,登录信息维护模块通过该预设端口就能够接收到该请求。The local http service module can send the request to the preset port of the native app where the login session information is located, and the login information maintenance module can receive the request through the preset port.

如果登录信息维护模块确定当前处于未登录状态,则可以返回指示错误的信息。另外,为了保证安全,返回的登录会话信息可以进行加密并以加密串的形态返回。If the login information maintenance module determines that the current status is not logged in, it may return information indicating an error. In addition, in order to ensure security, the returned login session information can be encrypted and returned in the form of an encrypted string.

在209中,本地http服务模块利用登录会话信息和JS回调函数信息生成登录执行代码,将登录执行代码返回给web页面上的执行模块。In 209, the local http service module uses the login session information and the JS callback function information to generate a login execution code, and returns the login execution code to the execution module on the web page.

本地http服务模块与web页面上的执行模块采用JSONP、web socket(套接字)等形式进行http交互。The local http service module and the execution module on the web page use JSONP, web socket (socket) and other forms to perform http interaction.

在210中,web页面上的执行模块执行接收到的登录执行代码,完成利用登录会话信息自动登录,并将登录会话信息存储于该web页面所在nativeapp的cookie中。In 210, the execution module on the web page executes the received login execution code, completes automatic login using the login session information, and stores the login session information in the cookie of the native app where the web page is located.

web页面上的执行模块接收到登录执行代码后,自动执行该代码。执行代码的过程就是利用登录会话信息完成在web页面上登录的相关处理逻辑,包括从登录会话信息中获取账户信息,例如用户名、密码等,在web页面上输入账户信息以请求登录。After the execution module on the web page receives the login execution code, it automatically executes the code. The process of executing the code is to use the login session information to complete the relevant processing logic of logging in on the web page, including obtaining account information from the login session information, such as user name, password, etc., and inputting the account information on the web page to request login.

在自动登录后,登录状态信息和登录会话信息可以存储于web页面所在native app的cookie中,供该native app作为目标应用时提供登录会话信息使用,也供下次在该native app中加载同一服务提供商的web页面时,即账户的系统域名相同时,能够直接使用该native app的cookie中的登录会话信息进行登录。After automatic login, the login status information and login session information can be stored in the cookie of the native app where the web page is located, which can be used to provide login session information when the native app is used as the target application, and also for loading the same service in the native app next time Provider's web page, that is, when the system domain name of the account is the same, you can directly use the login session information in the cookie of the native app to log in.

另外,在205中确定出的登录会话信息所在的native app可能是多个,那么本地http服务模块就可能收到多个native app返回的登录会话信息。如果返回的多个登录会话信息中账户信息是相同的,则利用其中一个登录会话信息生成执行代码返回给web页面上的执行模块即可。但也存在另外的可能性,即返回的多个登录会话信息中账户信息是不同的,例如在手机中可能有两个百度账户分别登录了两个百度产品的app,那么本地http服务模块可以利用多个登录会话信息和JS回调函数信息生成登录执行代码。该登录执行代码在被web页面上的执行模块执行的过程中,会将多个登录会话信息中的账户信息提供给用户供用户选择,并依据用户选择的账户信息进行自动登录。当然,本地http服务模块也可以采用其他方式,例如从多个登录会话信息中选择一个用以生成登录执行代码。In addition, there may be multiple native apps where the login session information determined in step 205 resides, so the local http service module may receive login session information returned by multiple native apps. If the account information in the returned multiple login session information is the same, use one of the login session information to generate an execution code and return it to the execution module on the web page. But there is also another possibility, that is, the account information in the multiple login session information returned is different. For example, there may be two Baidu accounts in the mobile phone that have logged in to two Baidu product apps respectively, so the local http service module can use Multiple login session information and JS callback function information generate login execution code. When the login execution code is executed by the execution module on the web page, the account information in multiple login session information will be provided to the user for selection, and automatic login will be performed according to the account information selected by the user. Of course, the local http service module can also adopt other methods, such as selecting one of multiple login session information to generate login execution code.

下面举一个实例,用户在浏览器上打开百度地图的web页面时,如果浏览器本地的cookie没有百度地图的账户域名对应的登录会话信息,则该web页面上的执行模块向预设的本地网络端口发送获取登录会话信息的http请求,该http请求中包含JS回调函数信息和目标应用标识信息,其中目标应用标识信息可以包括百度地图的native app的包名信息、百度贴吧的nativeapp的包名信息以及百度音乐的native app的包名信息。Here's an example. When a user opens a web page of Baidu Maps on a browser, if the browser's local cookie does not have the login session information corresponding to the account domain name of Baidu Maps, the execution module on the web page will send a message to the preset local network. The port sends an http request to obtain login session information. The http request includes JS callback function information and target application identification information. The target application identification information can include the package name information of the native app of Baidu Maps and the package name information of the native app of Baidu Tieba. And the package name information of the native app of Baidu Music.

假设本地http服务模块内置于百度贴吧的native app中,那么本地http服务模块通过侦听预设的本地网络端口能够获取到上述http请求。假设该http请求的offer合法,依据其中的目标应用标识信息,向本地安装的百度地图的native app、百度音乐的native app以及百度贴吧的native app中的会话维护模块发送获取登录会话信息的请求。其中向百度地图的native app和百度音乐的native app发送请求采用进程间通信的方式。Assuming that the local http service module is built into the native app of Baidu Tieba, then the local http service module can obtain the above http request by listening to the preset local network port. Assuming that the offer of the HTTP request is legal, according to the target application identification information, send a request to obtain login session information to the session maintenance module in the locally installed native app of Baidu Maps, native app of Baidu Music, and native app of Baidu Tieba. Among them, sending requests to the native app of Baidu Maps and the native app of Baidu Music adopts the method of inter-process communication.

各会话维护模块分别判断本native app是否处于登录状态,如果处于登录状态,则利用对应的登录会话信息和JS回调函数生成执行代码返回给本地http服务模块。由本地http服务模块返回给百度地图的web页面上的执行模块,该执行模块执行上述执行代码,完成自动登录。只要有一个目标应用处于登录状态,就能够返回执行代码让web页面上的执行模块自动登录。Each session maintenance module judges whether the native app is in the login state, and if it is in the login state, it uses the corresponding login session information and the JS callback function to generate execution code and return it to the local http service module. The execution module on the web page of Baidu Map is returned by the local http service module, and the execution module executes the above execution code to complete the automatic login. As long as there is a target application in the login state, the execution code can be returned to allow the execution module on the web page to automatically log in.

在此,如果本地http服务模块接收到多个登录会话信息,且登录会话信息中的账户信息不同,则可以利用多个登录会话信息生成执行代码。web页面上的执行模块在执行该执行代码的过程中,会让用户选择采用哪个账户信息进行自动登录,并根据用户选择的账户信息进行自动登录。Here, if the local http service module receives multiple login session information, and the account information in the login session information is different, the multiple login session information can be used to generate the execution code. In the process of executing the execution code, the execution module on the web page will allow the user to choose which account information to use for automatic login, and perform automatic login according to the account information selected by the user.

可见,只要用户在智能终端中使用了服务提供商的一个native app进行登录,那么在其他native app中打开同一服务提供上的web页面都能够进行自动登录。It can be seen that as long as the user uses a native app of the service provider to log in in the smart terminal, then opening the web page on the same service provider in other native apps can automatically log in.

在本发明所提供的几个实施例中,应该理解到,所揭露的装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。In the several embodiments provided by the present invention, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the units is only a logical function division, and there may be other division methods in actual implementation.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用硬件加软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware, or in the form of hardware plus software functional units.

上述以软件功能单元的形式实现的集成的单元,可以存储在一个计算机可读取存储介质中。上述软件功能单元存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)或处理器(processor)执行本发明各个实施例所述方法的部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。The above-mentioned integrated units implemented in the form of software functional units may be stored in a computer-readable storage medium. The above-mentioned software functional units are stored in a storage medium, and include several instructions to make a computer device (which may be a personal computer, server, or network device, etc.) or a processor (processor) execute the methods described in various embodiments of the present invention. partial steps. The aforementioned storage media include: U disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disk or optical disc and other media that can store program codes. .

以上所述仅为本发明的较佳实施例而已,并不用以限制本发明,凡在本发明的精神和原则之内,所做的任何修改、等同替换、改进等,均应包含在本发明保护的范围之内。The above descriptions are only preferred embodiments of the present invention, and are not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention shall be included in the present invention. within the scope of protection.

Claims (20)

1. A method for synchronizing login status, the method comprising:
when the web page is loaded, an execution module on the web page sends a request for acquiring login session information to a local http service module;
after receiving the request for obtaining the login session information, the local http service module determines the local application where the login session information is located, obtains the login session information of the current login user from the local application where the login session information is located, and returns the obtained login session information to the execution module on the web page;
and the execution module on the web page utilizes the login session information to automatically log in.
2. The method of claim 1, further comprising: after a local application where the local http service module is located is started, initializing the local http service module to enable the local http service module to monitor a preset local network port;
the step of sending a request for acquiring login session information to a local http service module by an execution module on the web page comprises the following steps: and the execution module on the web page sends the request for acquiring the login session information to the preset local network port.
3. The method of claim 1, wherein determining the local application in which the login session information is located comprises:
and the local http service module determines a local application corresponding to the application identification information according to the application identification information included in the request for acquiring the login session information.
4. The method of claim 3, wherein determining the local application in which the login session information is located further comprises:
and if the request for acquiring the login session information does not contain the application identification information, the local http service module determines the local application where the login session information is located according to preset configuration information.
5. The method of claim 1, wherein the request to obtain login session information includes JS callback function information;
the step of returning the acquired login session information to the execution module on the web page comprises the following steps: generating an execution code by using the acquired login session information and the JS callback function information, and returning the execution code to an execution module on the web page;
the automatic login of the execution module on the web page by using the login session information comprises the following steps: an execution module on the web page executes the execution code to complete the automatic login.
6. The method of claim 1, further comprising, prior to the determining the local application where the login session information is located:
the local http service module judges whether a refer source address of the request for obtaining the login session information is in a preset domain name range, and if so, the local application where the login session information is determined is continuously executed; otherwise, refusing to respond to the execution module on the web page or returning information indicating the error to the execution module on the web page.
7. The method according to claim 1, further comprising, before the obtaining login session information of the current login user from the local application where the login session information is located:
the local http service module judges whether the local application where the login session information is located is installed locally or not by calling a system interface, and if so, the local application where the login session information is located is continuously executed to acquire the login session information of the current login user; otherwise, returning information indicating the error to an execution module on the web page.
8. The method according to any one of claims 1 to 7, wherein the obtaining login session information of the current login user from the local application where the login session information is located comprises:
if the local application of the local http service module and the local application of the login session information are the same application, the local http service module sends a request to a session information maintenance module of the same local application in an in-process communication mode, and acquires the login session information of the current login user returned by the session information maintenance module; or,
and if the local application of the local http service module is different from the local application of the login session information, the local http service module sends a request to a session information maintenance module in the local application of the login session information in an interprocess communication mode, and acquires the login session information of the current login user returned by the session information maintenance module.
9. The method of any one of claims 1 to 7, further comprising:
and after the execution module on the web page automatically logs in, storing the login state information and the login session information in a cookie of a local application where the web page is located.
10. The method of claim 9, wherein before the executing module on the web page sends the request for obtaining login session information to the local http service module, the method further comprises:
judging whether corresponding login session information exists in the cookie of the local application where the web page is located, and if so, logging in by using the corresponding login session information in the cookie of the local application where the web page is located; otherwise, the request for obtaining the login session information is sent to the local http service module.
11. An apparatus for synchronizing login status, the apparatus comprising:
the execution module on the web page is used for sending a request for acquiring login session information to the local http service module when the web page is loaded; automatically logging in by using login session information returned by the local http service module;
and the local http service module is used for determining the local application where the login session information is located after receiving the request for obtaining the login session information, obtaining the login session information of the current login user from the local application where the login session information is located, and returning the obtained login session information to the execution module on the web page.
12. The device according to claim 11, wherein the local http service module is configured to intercept a preset local network port after being initialized by the local application;
the execution module on the web page is specifically configured to send the request for obtaining login session information to the preset local network port.
13. The apparatus according to claim 11, wherein the local http service module, when determining the local application where the login session information is located, is specifically configured to determine the local application corresponding to the application identification information according to the application identification information included in the request for obtaining the login session information.
14. The apparatus according to claim 13, wherein the local http service module is further configured to determine, according to preset configuration information, a local application where the login session information is located, if the request for obtaining the login session information does not include the application identification information.
15. The apparatus according to claim 11, wherein the local http service module, when returning the obtained login session information to the execution module on the web page, specifically executes: generating an execution code by using the acquired login session information and JS callback function information contained in the request for acquiring the login session information, and returning the execution code to an execution module on the web page;
and the execution module on the web page is specifically used for executing the execution code to complete automatic login.
16. The apparatus according to claim 11, wherein the local http service module is further configured to, before determining the local application where the login session information is located, determine whether a refer source address of the request for obtaining the login session information is within a preset domain name range, and if so, continue to execute the local application where the login session information is determined; otherwise, refusing to respond to the execution module on the web page or returning information indicating the error to the execution module on the web page.
17. The apparatus according to claim 11, wherein the local http service module, before acquiring the login session information of the current login user from the local application where the login session information is located, is further configured to determine, by invoking a system interface, whether the local application where the login session information is located is already installed locally, and if so, continue to execute the acquiring of the login session information of the current login user from the local application where the login session information is located; otherwise, returning information indicating the error to an execution module on the web page.
18. The apparatus according to any one of claims 11 to 17, further comprising a session information maintenance module;
the local http service module specifically executes the following steps when obtaining the login session information of the current login user from the local application where the login session information is located: if the local application of the local http service module and the local application of the login session information are the same application, sending a request to a session information maintenance module of the same local application in an in-process communication mode, and acquiring login session information of a current login user returned by the session information maintenance module; or if the local application of the local http service module is different from the local application of the login session information, sending a request to a session information maintenance module in the local application of the login session information in an interprocess communication manner, and acquiring the login session information of the current login user returned by the session information maintenance module;
and the session information maintenance module is used for returning login session information of a current login user in a local application where the session information maintenance module is located to the local http service module after receiving the request sent by the local http service module.
19. The apparatus according to any of claims 11 to 17, wherein the execution module on the web page is further configured to store the login state information and the login session information in a cookie of a local application where the web page is located after the automatic login.
20. The apparatus according to claim 19, wherein the execution module on the web page is further configured to determine, before sending the request for obtaining login session information to the local http service module, whether corresponding login session information exists in a cookie of the local application where the web page is located, and if so, perform login using the corresponding login session information in the cookie of the local application where the web page is located; otherwise, the request for obtaining the login session information is sent to the local http service module.
CN201410815961.8A 2014-12-23 2014-12-23 A kind of method and apparatus of synchronous logging state Active CN104580406B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201410815961.8A CN104580406B (en) 2014-12-23 2014-12-23 A kind of method and apparatus of synchronous logging state
PCT/CN2015/087219 WO2016101635A1 (en) 2014-12-23 2015-08-17 Method, apparatus and device for synchronizing login status, and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410815961.8A CN104580406B (en) 2014-12-23 2014-12-23 A kind of method and apparatus of synchronous logging state

Publications (2)

Publication Number Publication Date
CN104580406A true CN104580406A (en) 2015-04-29
CN104580406B CN104580406B (en) 2019-11-26

Family

ID=53095564

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410815961.8A Active CN104580406B (en) 2014-12-23 2014-12-23 A kind of method and apparatus of synchronous logging state

Country Status (2)

Country Link
CN (1) CN104580406B (en)
WO (1) WO2016101635A1 (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016101635A1 (en) * 2014-12-23 2016-06-30 北京百度网讯科技有限公司 Method, apparatus and device for synchronizing login status, and computer storage medium
CN105791324A (en) * 2016-05-12 2016-07-20 腾讯科技(深圳)有限公司 Account login method and device
CN106572068A (en) * 2015-10-13 2017-04-19 阿里巴巴集团控股有限公司 Account synchronous login method and device
CN106790269A (en) * 2017-02-15 2017-05-31 东软集团股份有限公司 Restoration methods and device that application program time-out is logged in
WO2017107732A1 (en) * 2015-12-24 2017-06-29 广州爱九游信息技术有限公司 Login status synchronization method and system
CN107370772A (en) * 2017-09-20 2017-11-21 青岛海信移动通信技术股份有限公司 Account login method, device and computer-readable storage medium
CN107995245A (en) * 2016-10-27 2018-05-04 腾讯科技(深圳)有限公司 The method and terminal of a kind of resource-sharing
CN109040072A (en) * 2018-08-06 2018-12-18 武汉斗鱼网络科技有限公司 A kind of method, system, server and the storage medium of client authorization log-on webpage
CN109375960A (en) * 2018-09-29 2019-02-22 郑州云海信息技术有限公司 A method and device for loading copyright information
CN109981781A (en) * 2019-03-27 2019-07-05 深圳市网心科技有限公司 Data processing method and system, electronic equipment and storage medium
CN110224924A (en) * 2019-05-21 2019-09-10 腾讯科技(深圳)有限公司 State updating method and device, storage medium and electronic device
CN111353142A (en) * 2019-02-15 2020-06-30 鸿合科技股份有限公司 User information sharing method and device and electronic equipment
US10812465B2 (en) 2017-09-20 2020-10-20 Hisense Mobile Communications Technology Co., Ltd. Method for logging into account on mobile device, mobile device, and non-transitory computer readable storage medium

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109547237A (en) * 2018-11-02 2019-03-29 航天信息股份有限公司 A kind of monitoring system and method for web application
CN112069476B (en) * 2020-09-16 2022-07-12 杭州安恒信息技术股份有限公司 Login state detection method, device, equipment and readable storage medium
CN114721836A (en) * 2021-01-05 2022-07-08 武汉斗鱼网络科技有限公司 Login state synchronization method, device, device and storage medium
CN114827158B (en) * 2021-01-18 2025-02-11 网宿科技股份有限公司 Configuration information loading method, system and server

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101369272A (en) * 2007-08-17 2009-02-18 徐萍 Auto-filling system and method for auto-filling registration or login information
CN101504616A (en) * 2009-03-23 2009-08-12 金蝶软件(中国)有限公司 Method and apparatus for login of Windows application program through Web application
CN102495855A (en) * 2011-11-21 2012-06-13 奇智软件(北京)有限公司 Automatic login method and device
CN102638454A (en) * 2012-03-14 2012-08-15 武汉理工大学 Plug-in type SSO (single signon) integration method oriented to HTTP (hypertext transfer protocol) identity authentication protocol
US20120324556A1 (en) * 2011-06-17 2012-12-20 Ebay Inc. Passporting credentials between a mobile app and a web browser
CN102882903A (en) * 2011-07-12 2013-01-16 腾讯科技(深圳)有限公司 Method and system for acquiring multi-site application information
CN102984218A (en) * 2012-11-12 2013-03-20 北京奇虎科技有限公司 Browser and login method thereof and login system thereof

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102065141B (en) * 2010-12-27 2014-05-07 广州欢网科技有限责任公司 Method and system for realizing single sign-on of cross-application and browser
CN104519050B (en) * 2014-11-14 2019-03-12 百度在线网络技术(北京)有限公司 Login method and login system
CN104580406B (en) * 2014-12-23 2019-11-26 北京百度网讯科技有限公司 A kind of method and apparatus of synchronous logging state
CN104735066B (en) * 2015-03-18 2018-10-16 百度在线网络技术(北京)有限公司 A kind of single-point logging method of object web page application, device and system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101369272A (en) * 2007-08-17 2009-02-18 徐萍 Auto-filling system and method for auto-filling registration or login information
CN101504616A (en) * 2009-03-23 2009-08-12 金蝶软件(中国)有限公司 Method and apparatus for login of Windows application program through Web application
US20120324556A1 (en) * 2011-06-17 2012-12-20 Ebay Inc. Passporting credentials between a mobile app and a web browser
CN102882903A (en) * 2011-07-12 2013-01-16 腾讯科技(深圳)有限公司 Method and system for acquiring multi-site application information
CN102495855A (en) * 2011-11-21 2012-06-13 奇智软件(北京)有限公司 Automatic login method and device
CN102638454A (en) * 2012-03-14 2012-08-15 武汉理工大学 Plug-in type SSO (single signon) integration method oriented to HTTP (hypertext transfer protocol) identity authentication protocol
CN102984218A (en) * 2012-11-12 2013-03-20 北京奇虎科技有限公司 Browser and login method thereof and login system thereof

Cited By (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016101635A1 (en) * 2014-12-23 2016-06-30 北京百度网讯科技有限公司 Method, apparatus and device for synchronizing login status, and computer storage medium
CN106572068A (en) * 2015-10-13 2017-04-19 阿里巴巴集团控股有限公司 Account synchronous login method and device
WO2017107732A1 (en) * 2015-12-24 2017-06-29 广州爱九游信息技术有限公司 Login status synchronization method and system
CN105791324A (en) * 2016-05-12 2016-07-20 腾讯科技(深圳)有限公司 Account login method and device
US10686778B2 (en) 2016-05-12 2020-06-16 Tencent Technology (Shenzhen) Company Limited Account login method and apparatus
WO2017193990A1 (en) * 2016-05-12 2017-11-16 腾讯科技(深圳)有限公司 Account login method and device
CN105791324B (en) * 2016-05-12 2019-12-06 腾讯科技(深圳)有限公司 Account login method and device
CN107995245B (en) * 2016-10-27 2019-03-15 腾讯科技(深圳)有限公司 A kind of method and terminal of resource-sharing
CN107995245A (en) * 2016-10-27 2018-05-04 腾讯科技(深圳)有限公司 The method and terminal of a kind of resource-sharing
CN106790269A (en) * 2017-02-15 2017-05-31 东软集团股份有限公司 Restoration methods and device that application program time-out is logged in
US10812465B2 (en) 2017-09-20 2020-10-20 Hisense Mobile Communications Technology Co., Ltd. Method for logging into account on mobile device, mobile device, and non-transitory computer readable storage medium
CN107370772A (en) * 2017-09-20 2017-11-21 青岛海信移动通信技术股份有限公司 Account login method, device and computer-readable storage medium
CN107370772B (en) * 2017-09-20 2019-12-10 青岛海信移动通信技术股份有限公司 Account login method, device and computer-readable storage medium
CN110650129A (en) * 2017-09-20 2020-01-03 青岛海信移动通信技术股份有限公司 Account login method and device and computer readable storage medium
CN109040072A (en) * 2018-08-06 2018-12-18 武汉斗鱼网络科技有限公司 A kind of method, system, server and the storage medium of client authorization log-on webpage
CN109040072B (en) * 2018-08-06 2021-03-12 武汉斗鱼网络科技有限公司 A method, system, server and storage medium for client authorization to log in to webpage
CN109375960A (en) * 2018-09-29 2019-02-22 郑州云海信息技术有限公司 A method and device for loading copyright information
CN111353142A (en) * 2019-02-15 2020-06-30 鸿合科技股份有限公司 User information sharing method and device and electronic equipment
CN109981781A (en) * 2019-03-27 2019-07-05 深圳市网心科技有限公司 Data processing method and system, electronic equipment and storage medium
CN109981781B (en) * 2019-03-27 2021-08-06 深圳市网心科技有限公司 Data processing method and system, electronic device and storage medium
CN110224924A (en) * 2019-05-21 2019-09-10 腾讯科技(深圳)有限公司 State updating method and device, storage medium and electronic device

Also Published As

Publication number Publication date
WO2016101635A1 (en) 2016-06-30
CN104580406B (en) 2019-11-26

Similar Documents

Publication Publication Date Title
CN104580406B (en) A kind of method and apparatus of synchronous logging state
US11206451B2 (en) Information interception processing method, terminal, and computer storage medium
US10554655B2 (en) Method and system for verifying an account operation
US9954855B2 (en) Login method and apparatus, and open platform system
US11128621B2 (en) Method and apparatus for accessing website
US11770385B2 (en) Systems and methods for malicious client detection through property analysis
US9554276B2 (en) System and method for on the fly protocol conversion in obtaining policy enforcement information
EP4109861B1 (en) Data processing method, apparatus, computer device, and storage medium
CN104767775A (en) Web application message push method and system
CN104335523A (en) Access control method, client and server
CN104735066A (en) Single sign-on method, device and system oriented to web page applications
US11882154B2 (en) Template representation of security resources
US20140019957A1 (en) Method, apparatus, and system for sharing software among terminals
US11163499B2 (en) Method, apparatus and system for controlling mounting of file system
CN104468592A (en) Login method and system
CN106686151B (en) IP address obtaining method and device
US10623450B2 (en) Access to data on a remote device
CN106254319B (en) Light application login control method and device
US20150180851A1 (en) Method, device, and system for registering terminal application
CN104346460B (en) Carry out the method, apparatus and browser client of file download
CN105554136A (en) Backup data restoration method, device and system
CN110633432A (en) Method, device, terminal equipment and medium for acquiring data
CN103067398A (en) Method and equipment for achieving third-party application accessing user data
US10375141B2 (en) Method for processing URL and associated server and non-transitory computer readable storage medium
US9830436B1 (en) Managing authenticated user access to public content

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