Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

A method and terminal for automatic renewal of a login status

A login state, automatic technology, applied in the field of data processing, can solve the problems of token failure, increase in the number of network requests, increase in server pressure, etc., to achieve the effect of less difficulty in execution, improved processing efficiency, and simple steps

Active Publication Date: 2021-06-25
FUJIAN TIANQUAN EDUCATION TECH LTD
View PDF9 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

The disadvantage of this solution is that it cannot completely solve the problem of token invalidation, and the number of network requests will increase, and the pressure on the server will increase

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • A method and terminal for automatic renewal of a login status
  • A method and terminal for automatic renewal of a login status
  • A method and terminal for automatic renewal of a login status

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0069] Please refer to figure 1 , Embodiment 1 of the present invention is:

[0070] The invention provides a method for automatic renewal of a login status, which includes the following steps:

[0071] S1: When the webpage starts, obtain the token corresponding to the current account of the webpage;

[0072] Wherein, the S1 is specifically:

[0073] When the webpage starts, the token corresponding to the current account of the webpage is obtained from the cache.

[0074] S2: Determine whether the token is valid, if invalid, jump to the login page of the webpage; if valid, obtain the last renewal time of the token, and execute S3;

[0075] Wherein, the S2 is specifically:

[0076] Judging whether the token is valid, if invalid, jump to the login page of the webpage; obtain the input account number and password, and perform a login operation. If the login is successful, cache the token corresponding to the currently logged in account, and cache the current time point as Th...

Embodiment 2

[0089] The difference between the second embodiment of the present invention and the first embodiment is that all webpages in the first embodiment are replaced with apps.

Embodiment 3

[0090] Please refer to figure 2 , Embodiment three of the present invention is:

[0091] The present invention provides a terminal for automatically renewing a login status, including a memory 1, a processor 2, and a computer program stored in the memory 1 and operable on the processor 2, and the computer program is implemented when the processor executes the computer program. The following steps:

[0092] S1: When the webpage starts, obtain the token corresponding to the current account of the webpage;

[0093] Wherein, the S1 is specifically:

[0094] When the webpage starts, the token corresponding to the current account of the webpage is obtained from the cache.

[0095] S2: Determine whether the token is valid, if invalid, jump to the login page of the webpage; if valid, obtain the last renewal time of the token, and execute S3;

[0096] Wherein, the S2 is specifically:

[0097] Judging whether the token is valid, if invalid, jump to the login page of the webpage; o...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The present invention provides a method and a terminal for automatic renewal of a login state, the method comprising the following steps: S1: when the webpage is started, obtain a token corresponding to the current account of the webpage; S2: determine whether the token is valid, if invalid, then Jump to the login page of the webpage; if valid, obtain the last renewal time point of the token, and execute S3; S3: obtain the renewal time period according to the last renewal time point and the current time point, and judge the renewal time Whether the segment exceeds the preset time segment threshold, and if so, renew the token to realize the automatic renewal of the login status of the current account. The present invention provides a method and a terminal capable of automatically renewing a login state, and has efficient processing performance.

Description

technical field [0001] The invention relates to the technical field of data processing, in particular to a method and a terminal for automatically renewing a login status. Background technique [0002] Since the token corresponding to the webpage login account has an expiration time, in order to maintain the login status for a long time, the common solutions in the industry are: [0003] 1. When the server receives the user's network request, it will automatically extend the token expiration time. The disadvantage of this solution is that it is inflexible, unable to meet the complex business needs of large-scale website applications, and its performance is not high. [0004] 2. The client creates a network request interceptor. After the network initiates the request and before accessing the network, it obtains the expiration time of the token. If it is "about to expire", it initiates a renewal request and notifies the server to extend the token expiration time. The disadva...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Patents(China)
IPC IPC(8): H04L29/06
CPCH04L63/0807H04L63/083
Inventor 刘德建陈铭高举全郭玉湖
Owner FUJIAN TIANQUAN EDUCATION TECH LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products