CN111177612A - Method and related device for authenticating page login - Google Patents

Method and related device for authenticating page login Download PDF

Info

Publication number
CN111177612A
CN111177612A CN201910643352.1A CN201910643352A CN111177612A CN 111177612 A CN111177612 A CN 111177612A CN 201910643352 A CN201910643352 A CN 201910643352A CN 111177612 A CN111177612 A CN 111177612A
Authority
CN
China
Prior art keywords
page
routing module
login
target
client
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
CN201910643352.1A
Other languages
Chinese (zh)
Other versions
CN111177612B (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201910643352.1A priority Critical patent/CN111177612B/en
Publication of CN111177612A publication Critical patent/CN111177612A/en
Application granted granted Critical
Publication of CN111177612B publication Critical patent/CN111177612B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/958Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/30Authentication, i.e. establishing the identity or authorisation of security principals
    • G06F21/31User authentication

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The application provides a page login authentication method and a related device, which can reduce the workload of developers and improve the development efficiency. The method is applied to a front end frame Vue, Vue comprising a routing module, the method comprising: receiving a page access request through a routing module, wherein the page access request is used for requesting to log in a target page; acquiring the running environment corresponding to the target page through the routing module according to the page access request; if the running environment corresponding to the target page is the first running environment, sending a target application login link to the client through the routing module so that the client accesses the target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation; receiving a callback link sent by a client through a routing module; and the routing module authenticates the client according to the callback link.

Description

Method and related device for authenticating page login
Technical Field
The present application relates to the field of network technologies, and in particular, to a method and a related apparatus for authenticating a page login
Background
When a user accesses a page through a browser, some pages typically require the user to log in to continue browsing the page.
In the prior art, a browser usually performs page construction based on a front-end framework (Vue), each Vue instance for constructing a page is subjected to an initialization process when being created, in the process, a hook function of some life cycles is usually run, a developer can add codes to the function to set required functions, such as login authentication codes, service rendering codes and the like, so that the browser can render the page for a user after performing login authentication on the user.
In the prior art, the login authentication is performed in a hook function of a life cycle, the login authentication code and the service code are mutually coupled, and when developers develop different pages, each page needs to independently set one login authentication code, so that the workload of the developers is large, and the development efficiency is low.
Disclosure of Invention
The embodiment of the application provides a page login authentication method and a related device, which can reduce the workload of developers and improve the development efficiency.
A first aspect of the present embodiment provides a method for authenticating a page login, where the method is applied to a front end framework Vue, the Vue includes a routing module, and the method includes:
receiving a page access request through a routing module, wherein the page access request is used for requesting to log in a target page;
acquiring the running environment corresponding to the target page through the routing module according to the page access request;
if the running environment corresponding to the target page is a first running environment, sending a target application login link to a client through the routing module so that the client accesses a target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation;
receiving a callback link sent by the client through the routing module;
and the routing module authenticates the client according to the callback link.
A second aspect of the embodiments of the present application provides a page login authentication apparatus, where the page login authentication apparatus includes a front end frame Vue, the Vue includes a routing module, and the page login authentication apparatus includes:
the first receiving module is used for receiving a page access request through the routing module, wherein the page access request is used for requesting to log in a target page;
the first obtaining module is used for obtaining the running environment corresponding to the target page through the routing module according to the page access request;
the sending module is used for sending a target application login link to a client through the routing module if the running environment corresponding to the target page is a first running environment, so that the client accesses a target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation;
the second receiving module is used for receiving the callback link sent by the client through the routing module;
and the processing module is used for carrying out authentication processing on the client through the routing module according to the callback link.
Based on the second aspect, the embodiments of the present application further provide a first implementation manner of the second aspect:
the page login authentication device further comprises:
the second obtaining module is used for obtaining the visitor login identification from the server through the routing module if the running environment corresponding to the target page is a second running environment;
and the storage module is used for storing the visitor login identification through the routing module.
Based on the second aspect, the embodiments of the present application further provide a second implementation manner of the second aspect:
the first obtaining module is further configured to obtain, by the routing module, the operating environment corresponding to the target page if the user login identifier corresponding to the page access request is not obtained by the routing module.
Based on the second aspect, the present application provides a third implementation manner of the second aspect:
the first obtaining module is further used for detecting the state of the user login identification if the user login identification corresponding to the page access request is obtained through the routing module;
and if the user login identification is in an invalid state, acquiring the operating environment corresponding to the target page through the routing module.
Based on the second aspect or any one of the first implementation manner of the second aspect to the third implementation manner of the second aspect, the present application also provides a fourth implementation manner of the second aspect:
and the processing module is also used for storing the user login identification carried by the callback link through the routing module.
A third aspect of the embodiments of the present application provides a client, including: a memory, a transceiver, a processor, and a bus system;
wherein the memory is used for storing programs;
the processor is used for executing the program in the memory and comprises the following steps:
receiving a page access request through a routing module, wherein the page access request is used for requesting to log in a target page;
acquiring the running environment corresponding to the target page through the routing module according to the page access request;
if the running environment corresponding to the target page is a first running environment, sending a target application login link to a client through the routing module so that the client accesses a target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation;
receiving a callback link sent by the client through the routing module;
the routing module authenticates the client according to the callback link;
the bus system is used for connecting the memory and the processor so as to enable the memory and the processor to communicate.
A fourth aspect of embodiments of the present application provides a computer-readable storage medium, comprising instructions, which, when executed on a computer, cause the computer to perform the method according to the first aspect.
A fifth aspect of embodiments of the present application provides a computer program product containing instructions which, when run on a computer, cause the computer to perform the method according to the first aspect.
According to the technical scheme, the embodiment of the application has the following advantages:
the embodiment of the application provides a page login authentication method and a related device, wherein the method is executed by a routing module additionally added to an Vue frame, when the routing module judges that a target page needing to be browsed by a user is not logged in by the user, and judges that the target page runs in a first running environment, a target application is accessed in a login link mode, so that the user jumps to the target application for login and then jumps to the target page for successful access, because the page login authentication steps are all executed in the routing module, then service codes in a life cycle hook function are executed, the page login authentication step can be preposed, and developers only need to uniformly set login authentication codes in the routing module when developing different pages, so that the login authentication codes are decoupled from the service codes, and the workload of the developers is reduced, the development efficiency is improved.
Drawings
FIG. 1 is a schematic flowchart of a method for authenticating page login in an embodiment of the present application;
FIG. 2 is a schematic diagram illustrating an application of the authentication method for page login in the embodiment of the present application;
FIG. 3 is a schematic structural diagram of a page login authentication device in an embodiment of the present application;
fig. 4 is a block diagram of a partial structure of a mobile phone related to a client according to an embodiment of the present disclosure.
Detailed Description
The embodiment of the application provides a page login authentication method and a related device, which can reduce the workload of developers and improve the development efficiency.
The terms "first," "second," "third," "fourth," and the like in the description and in the claims of the present application and in the drawings described above, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the application described herein are, for example, capable of operation in sequences other than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "corresponding" and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
It should be understood that the present application applies to a network login scenario, and in particular, network login generally refers to a login authentication scenario performed when a user browses a page through a browser on a client.
In the prior art, a browser usually performs page construction based on a front-end framework (Vue), each Vue instance for constructing a page is subjected to an initialization process when being created, in the process, a hook function of some life cycles is usually run, a developer can add codes to the function to set required functions, such as login authentication codes, service rendering codes and the like, so that the browser can render the page for a user after performing login authentication on the user.
In the prior art, the login authentication is performed in a hook function of a life cycle, the login authentication code and the service code are mutually coupled, and when developers develop different pages, each page needs to independently set one login authentication code, so that the workload of the developers is large, and the development efficiency is low.
In order to facilitate understanding, the present application provides a method for authenticating page login, which is applied to a client for execution, where the client may include, but is not limited to, a terminal device such as a smart phone, a personal computer, a palm computer, a television set-top box, and the like, and is used to output an application graphical interface and send an operation instruction input by a user through an input device such as a mouse, a keyboard, and the like, to a server through a network. It should be understood that, in the embodiment of the present application, a browser is installed on a client, and the browser may be started in different operating environments, such as a wechat environment and a non-wechat environment, which are hereinafter collectively referred to as a first operating environment and a second operating environment for convenience of description.
The browser generally constructs a page based on Vue, Vue in the embodiment of the present application includes a routing module, and the routing module executes the method for authenticating page login in the embodiment of the present application.
The method for authenticating page login in the embodiment of the present application is described below from the perspective of the client, and it should be noted that the method for authenticating page login in the embodiment of the present application is applied to the front end frames Vue, Vue including the routing module. Fig. 1 is a schematic flowchart of a method for authenticating page login in an embodiment of the present application, referring to fig. 1, an embodiment of the method for authenticating page login in the embodiment of the present application includes:
101. receiving a page access request through a routing module, wherein the page access request is used for requesting to log in a target page;
in this embodiment, when a user needs to access a target page through a browser on a client, a page access request may be input to the client, and at this time, after a routing module (for convenience, the routing module is described below) of the client receives the page access request input by the user, a configuration file corresponding to the page access request may be obtained. After determining that the target page needs to be checked for login according to the information of the configuration file, the routing module may execute step 102.
102. Acquiring the running environment corresponding to the target page through the routing module according to the page access request;
after the routing module receives the page access request, the operating environment corresponding to the target page needs to be determined. It should be noted that, because the operating environments of the browsers are different, the manner of login authentication performed by the routing module on the page is also different, and specifically, after the routing module obtains the operating environment corresponding to the target page and determines that the operating environment is the first operating environment, step 103 is executed.
103. If the running environment corresponding to the target page is the first running environment, sending a target application login link to the client through the routing module so that the client accesses the target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation;
when the routing module determines that the operating environment is the first operating environment, the corresponding target application login link is obtained and sent to the client, it should be noted that the routing module and the target application in this embodiment may be disposed in the same client, and the target application program and the first operating environment have a corresponding relationship.
And when the client receives the target application login link, jumping to the target application program according to the target application login link. At this time, the login authorization page displayed on the client is the target application program, and after receiving an authorization instruction input by the user, the target application program can return a callback link to the routing module.
104. Receiving a callback link sent by a client through a routing module;
105. and the routing module authenticates the client according to the callback link.
And the routing module receives the callback link returned by the target application program in the client, analyzes the callback link and authenticates the client according to the callback link. It can be understood that, completing the authentication process, i.e., completing the page login authentication of the user, may be regarded as determining that the user login page is successful, and thus, the login authentication step performed by the routing module of Vue is completed, the hook function module corresponding to the service code in Vue is entered, and the client performs the page rendering step to render a complete target page and display the target page on the display interface of the client for the user to use.
In the embodiment, the routing module is additionally added to the Vue framework for execution, when the routing module judges that a target page which needs to be browsed by a user is not logged in by the user, and judges that the target page runs in the first running environment, the target application is accessed in a login link mode, so that the user jumps to the target application for login and then jumps to the target page for successful access, since the steps of page login authentication are all executed in the routing module, and then the service codes in the lifecycle hook function are executed, the steps of page login authentication can be preposed, and when developers develop different pages, only the login authentication codes need to be uniformly set in the routing module, so that the login authentication codes are decoupled from the service codes, the workload of the developers is reduced, and the development efficiency is improved.
Optionally, based on the embodiment corresponding to fig. 1, in an optional embodiment of the method for authenticating a face login in the embodiment of the present application, after the obtaining, by the routing module, the operating environment corresponding to the target page according to the page access request, the method further includes:
if the running environment corresponding to the target page is a second running environment, obtaining a visitor login identifier from the server through the routing module;
and storing the visitor login identification through the routing module.
In this embodiment, after the routing module determines that the operating environment corresponding to the target page is the second operating environment, the routing module may request the server for a guest login interface, and after the request is successful, a guest login identifier may be obtained, and the user successfully logs in the page with the identity of the guest, and the routing module stores the guest login identifier, so far, the login authentication step performed by the routing module of Vue is completed, and the hook function module corresponding to the service code in Vue is entered, and the client performs a page rendering step to render a complete target page and display the target page on a display interface of the client for the user to use.
Optionally, based on each embodiment corresponding to fig. 1, in an optional embodiment of the method for authenticating a face login in the embodiment of the present application, the obtaining, by the routing module according to the page access request, the operating environment corresponding to the target page includes:
and if the user login identification corresponding to the page access request is not acquired through the routing module, acquiring the operating environment corresponding to the target page through the routing module.
In this embodiment, before obtaining the operating environment corresponding to the target page, the routing module generally obtains a user login identifier corresponding to a page access request sent by a user from a local storage, and if the corresponding user login identifier cannot be obtained, it is determined that the user does not log in the target page and needs to perform login authentication, and then the routing module obtains the operating environment corresponding to the target page to perform subsequent login authentication operations.
Optionally, based on each embodiment corresponding to fig. 1, in an optional embodiment of the method for authenticating a face login in the embodiment of the present application, the obtaining, by the routing module according to the page access request, the operating environment corresponding to the target page includes:
if a user login identifier corresponding to the page access request is obtained through the routing module, detecting the state of the user login identifier;
and if the user login identification is in an invalid state, acquiring the running environment corresponding to the target page through the routing module.
In this embodiment, before obtaining the operating environment corresponding to the target page, the routing module generally obtains, from a local storage, a user login identifier corresponding to a page access request sent by a user, and if a corresponding user login identifier is obtained, detects a state of the user login identifier.
If the user login identification is judged to be in an invalid state, if the identification is expired or damaged, the page login authentication needs to be carried out again even if the user logs in the target page, and then the routing module acquires the operating environment corresponding to the target page to execute subsequent login authentication operation.
If the user login identification is judged to be in the valid state, the login authentication operation is finished, and the page rendering operation is executed.
Optionally, based on each embodiment corresponding to fig. 1, in an optional embodiment of the method for authenticating a face login in the embodiment of the present application, the authenticating the client according to the callback link by the routing module specifically includes:
and storing the user login identification carried by the callback link through the routing module.
In this embodiment, after receiving the callback link, the routing module parses the callback link, and since the callback link includes the user login identifier, the routing module may obtain the user login identifier after the parsing operation is completed, and store the user login identifier, thereby completing the login authentication processing.
For convenience of understanding, the following will further describe the page login authentication method in the embodiment of the present application by using an application example, fig. 2 is an application example diagram of the page login authentication method in the embodiment of the present application, please refer to fig. 2, where the application example includes:
201. the routing module receives a page login request input by a user;
202. the routing module judges whether the page needs login verification or not;
if so, go to step 203, and if not, go to step 208.
203. The routing module acquires a user login identifier and judges whether a user logs in a page or not;
if the user login identification (token) cannot be acquired, executing step 204, if the user login identification is acquired, judging whether the identification is valid, if so, executing step 208, and if not, executing step 204;
204. the routing module detects the running environment of the page;
if the operating environment is the first operating environment, step 205 is executed, and if the operating environment is the second operating environment, step 207 is executed;
205. the routing module acquires an application login link and skips to a target application;
206. receiving a callback link returned by a target application, and storing a user login identifier;
after the user authorizes login on the target application, the target application sends a call back to the routing module.
207. The routing module requests a visitor login interface and stores a visitor login identifier;
208. and rendering the page.
The application case is based on vue route front-end authentication login, executes login authentication logic in a navigation guard of a routing module, uniformly manages login authority of a page, is completely decoupled from service codes, reduces workload of developers, and facilitates login access and maintenance. Developers only need to concentrate on the development of the business, and do not need to care about the internal reality of the login logic at all.
The above is a detailed description of the method for authenticating page login in the embodiment of the present application, and the following is a description of the structure and connection relationship of the page login authentication device in the embodiment of the present application, it should be noted that the page login authentication device includes front end frames Vue, Vue including a routing module. Fig. 3 is a schematic structural diagram of a page login authentication apparatus in an embodiment of the present application, please refer to fig. 3, an embodiment of the page login authentication apparatus in the embodiment of the present application includes:
a first receiving module 301, configured to receive a page access request through a routing module, where the page access request is used to request to log in a target page;
a first obtaining module 302, configured to obtain, by a routing module, an operating environment corresponding to a target page according to a page access request;
a sending module 303, configured to send a target application login link to the client through the routing module if the operating environment corresponding to the target page is the first operating environment, so that the client accesses the target application program according to the target application login link, where the target application program and the first operating environment have a corresponding relationship;
a second receiving module 304, configured to receive, through the routing module, the callback link sent by the client;
and the processing module 305 is configured to perform authentication processing on the client according to the callback link through the routing module.
Based on the embodiment corresponding to fig. 3, in an optional embodiment of the page login authentication apparatus in the embodiment of the present application, the page login authentication apparatus further includes:
the second acquisition module is used for acquiring the visitor login identification from the server through the routing module if the operating environment corresponding to the target page is the second operating environment;
and the storage module is used for storing the visitor login identification through the routing module.
Based on each embodiment corresponding to fig. 3, in an optional embodiment of the page login authentication apparatus in the embodiment of the present application, the first obtaining module is further configured to obtain, by the routing module, the operating environment corresponding to the target page if the user login identifier corresponding to the page access request is not obtained by the routing module.
Based on each embodiment corresponding to fig. 3, in an optional embodiment of the page login authentication apparatus in the embodiment of the present application, the first obtaining module is further configured to detect a state of the user login identifier if the user login identifier corresponding to the page access request is obtained by the routing module;
and if the user login identification is in an invalid state, acquiring the running environment corresponding to the target page through the routing module.
Based on each embodiment corresponding to fig. 3, in an optional embodiment of the page login authentication apparatus in the embodiment of the present application, the processing module is further configured to store, by the routing module, the user login identifier carried by the callback link.
The embodiment of the present application further provides a client, which includes front-end frames Vue, Vue including a routing module. As shown in fig. 4, for convenience of explanation, only the parts related to the embodiments of the present application are shown, and details of the technology are not disclosed, please refer to the method part of the embodiments of the present application. The client may be any client device including a mobile phone, a tablet computer, a Personal Digital Assistant (PDA), a point of sales (POS), a vehicle-mounted computer, etc., taking the client as the mobile phone as an example:
fig. 4 is a block diagram illustrating a partial structure of a mobile phone related to a client provided in an embodiment of the present application. Referring to fig. 4, the handset includes: radio Frequency (RF) circuitry 410, memory 420, input unit 430, display unit 440, sensor 450, audio circuitry 460, wireless fidelity (WiFi) module 470, processor 480, and power supply 490. Those skilled in the art will appreciate that the handset configuration shown in fig. 4 is not intended to be limiting and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
The following describes each component of the mobile phone in detail with reference to fig. 4:
the RF circuit 410 may be used for receiving and transmitting signals during information transmission and reception or during a call, and in particular, receives downlink information of a base station and then processes the received downlink information to the processor 480; in addition, the data for designing uplink is transmitted to the base station. Typically, the RF circuitry 410 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a Low Noise Amplifier (LNA), a duplexer, and the like. In addition, the RF circuitry 410 may also communicate with networks and other devices via wireless communications. The wireless communication may use any communication standard or protocol, including but not limited to global system for mobile communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Long Term Evolution (LTE), email, Short Message Service (SMS), etc.
The memory 420 may be used to store software programs and modules, and the processor 480 executes various functional applications and data processing of the mobile phone by operating the software programs and modules stored in the memory 420. The memory 420 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may store data (such as audio data, a phonebook, etc.) created according to the use of the cellular phone, and the like. Further, the memory 420 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device.
The input unit 430 may be used to receive input numeric or character information and generate key signal inputs related to user settings and function control of the cellular phone. Specifically, the input unit 430 may include a touch panel 431 and other input devices 432. The touch panel 431, also called a touch screen, may collect touch operations of a user on or near the touch panel 431 (e.g., operations of the user on or near the touch panel 431 using any suitable object or accessory such as a finger or a stylus) and drive the corresponding connection device according to a preset program. Alternatively, the touch panel 431 may include two parts of a touch detection device and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 480, and receives and executes commands sent from the processor 480. In addition, the touch panel 431 may be implemented in various types, such as a resistive type, a capacitive type, an infrared ray, and a surface acoustic wave. The input unit 430 may include other input devices 432 in addition to the touch panel 431. In particular, other input devices 432 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like.
The display unit 440 may be used to display information input by the user or information provided to the user and various menus of the cellular phone. The display unit 440 may include a display panel 441, and optionally, the display panel 441 may be configured in the form of a Liquid Crystal Display (LCD), an organic light-emitting diode (OLED), or the like. Further, the touch panel 431 may cover the display panel 441, and when the touch panel 431 detects a touch operation on or near the touch panel 431, the touch panel is transmitted to the processor 480 to determine the type of the touch event, and then the processor 480 provides a corresponding visual output on the display panel 441 according to the type of the touch event. Although the touch panel 431 and the display panel 441 are shown in fig. 4 as two separate components to implement the input and output functions of the mobile phone, in some embodiments, the touch panel 431 and the display panel 441 may be integrated to implement the input and output functions of the mobile phone.
The handset may also include at least one sensor 450, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor that adjusts the brightness of the display panel 441 according to the brightness of ambient light, and a proximity sensor that turns off the display panel 441 and/or the backlight when the mobile phone is moved to the ear. As one of the motion sensors, the accelerometer sensor can detect the magnitude of acceleration in each direction (generally, three axes), can detect the magnitude and direction of gravity when stationary, and can be used for applications of recognizing the posture of a mobile phone (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer and tapping), and the like; as for other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which can be configured on the mobile phone, further description is omitted here.
Audio circuit 460, speaker 461, microphone 462 may provide an audio interface between the user and the cell phone. The audio circuit 460 may transmit the electrical signal converted from the received audio data to the speaker 461, and convert the electrical signal into a sound signal for output by the speaker 461; on the other hand, the microphone 462 converts the collected sound signal into an electrical signal, which is received by the audio circuit 460 and converted into audio data, which is then processed by the audio data output processor 480 and then transmitted to, for example, another cellular phone via the RF circuit 410, or output to the memory 420 for further processing.
WiFi belongs to short-distance wireless transmission technology, and the mobile phone can help a user to receive and send e-mails, browse webpages, access streaming media and the like through the WiFi module 470, and provides wireless broadband Internet access for the user. Although fig. 4 shows the WiFi module 470, it is understood that it does not belong to the essential constitution of the handset, and can be omitted entirely as needed within the scope not changing the essence of the invention.
The processor 480 is a control center of the mobile phone, connects various parts of the entire mobile phone by using various interfaces and lines, and performs various functions of the mobile phone and processes data by operating or executing software programs and/or modules stored in the memory 420 and calling data stored in the memory 420, thereby integrally monitoring the mobile phone. Optionally, processor 480 may include one or more processing units; optionally, the processor 480 may integrate an application processor and a modem processor, wherein the application processor mainly handles operating systems, user interfaces, application programs, and the like, and the modem processor mainly handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into processor 480.
The phone also includes a power supply 490 (e.g., a battery) for powering the various components, optionally, the power supply may be logically connected to the processor 480 through a power management system, so as to implement functions such as managing charging, discharging, and power consumption through the power management system.
Although not shown, the mobile phone may further include a camera, a bluetooth module, etc., which are not described herein.
In the embodiment of the present application, the processor 480 included in the client further has the following functions:
receiving a page access request through a routing module, wherein the page access request is used for requesting to log in a target page;
acquiring the running environment corresponding to the target page through the routing module according to the page access request;
if the running environment corresponding to the target page is the first running environment, sending a target application login link to the client through the routing module so that the client accesses the target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation;
receiving a callback link sent by a client through a routing module;
the routing module authenticates the client according to the callback link;
the bus system is used for connecting the memory and the processor so as to enable the memory and the processor to communicate.
Embodiments of the present application further provide a computer-readable storage medium, which includes instructions that, when executed on a computer, cause the computer to perform the above-mentioned method for authenticating a page login.
A fifth aspect of the embodiments of the present application provides a computer program product containing instructions, which when run on a computer, causes the computer to perform the above-mentioned method for authenticating a page login.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application may be substantially implemented or contributed to by the prior art, or all or part of the technical solution may be embodied in a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a read-only memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.

Claims (10)

1. A method for authentication of page login, the method being applied to a front end framework Vue, the Vue comprising a routing module, the method comprising:
receiving a page access request through a routing module, wherein the page access request is used for requesting to log in a target page;
acquiring the running environment corresponding to the target page through the routing module according to the page access request;
if the running environment corresponding to the target page is a first running environment, sending a target application login link to a client through the routing module so that the client accesses a target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation;
receiving a callback link sent by the client through the routing module;
and the routing module authenticates the client according to the callback link.
2. The method for authenticating page login according to claim 1, wherein after the obtaining the operating environment corresponding to the target page through the routing module according to the page access request, the method further comprises:
if the running environment corresponding to the target page is a second running environment, obtaining a visitor login identifier from a server through the routing module;
and storing the visitor login identification through the routing module.
3. The method for authenticating page login according to claim 1, wherein the obtaining, by the routing module, the operating environment corresponding to the target page according to the page access request comprises:
and if the user login identification corresponding to the page access request is not acquired through the routing module, acquiring the operating environment corresponding to the target page through the routing module.
4. The method for authenticating page login according to claim 1, wherein the obtaining, by the routing module, the operating environment corresponding to the target page according to the page access request comprises:
if the user login identification corresponding to the page access request is obtained through the routing module, detecting the state of the user login identification;
and if the user login identification is in an invalid state, acquiring the operating environment corresponding to the target page through the routing module.
5. The method for authenticating page login according to any one of claims 1 to 3, wherein the authenticating the client according to the callback link by the routing module specifically comprises:
and storing the user login identification carried by the callback link through the routing module.
6. A page login authentication device, wherein the page login authentication device comprises a front end frame Vue, the Vue comprises a routing module, and the page login authentication device comprises:
the first receiving module is used for receiving a page access request through the routing module, wherein the page access request is used for requesting to log in a target page;
the first obtaining module is used for obtaining the running environment corresponding to the target page through the routing module according to the page access request;
the sending module is used for sending a target application login link to a client through the routing module if the running environment corresponding to the target page is a first running environment, so that the client accesses a target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation;
the second receiving module is used for receiving the callback link sent by the client through the routing module;
and the processing module is used for carrying out authentication processing on the client through the routing module according to the callback link.
7. The page login authentication device of claim 6, wherein the page login authentication device further comprises:
the second obtaining module is used for obtaining the visitor login identification from the server through the routing module if the running environment corresponding to the target page is a second running environment;
and the storage module is used for storing the visitor login identification through the routing module.
8. A client, comprising: a memory, a transceiver, a processor, and a bus system;
wherein the memory is used for storing programs;
the processor is used for executing the program in the memory and comprises the following steps:
receiving a page access request through a routing module, wherein the page access request is used for requesting to log in a target page;
acquiring the running environment corresponding to the target page through the routing module according to the page access request;
if the running environment corresponding to the target page is a first running environment, sending a target application login link to a client through the routing module so that the client accesses a target application program according to the target application login link, wherein the target application program and the first running environment have a corresponding relation;
receiving a callback link sent by the client through the routing module;
the routing module authenticates the client according to the callback link;
the bus system is used for connecting the memory and the processor so as to enable the memory and the processor to communicate.
9. A computer-readable storage medium comprising instructions that, when executed on a computer, cause the computer to perform the method of any of claims 1 to 5.
10. A computer program product comprising instructions which, when run on a computer, cause the computer to perform the method of any one of claims 1 to 5.
CN201910643352.1A 2019-07-16 2019-07-16 Page login authentication method and related device Active CN111177612B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910643352.1A CN111177612B (en) 2019-07-16 2019-07-16 Page login authentication method and related device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910643352.1A CN111177612B (en) 2019-07-16 2019-07-16 Page login authentication method and related device

Publications (2)

Publication Number Publication Date
CN111177612A true CN111177612A (en) 2020-05-19
CN111177612B CN111177612B (en) 2023-09-19

Family

ID=70655312

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910643352.1A Active CN111177612B (en) 2019-07-16 2019-07-16 Page login authentication method and related device

Country Status (1)

Country Link
CN (1) CN111177612B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112187748A (en) * 2020-09-15 2021-01-05 中信银行股份有限公司 Cross-network access control management method and device and electronic equipment
CN113472752A (en) * 2021-06-11 2021-10-01 北京达佳互联信息技术有限公司 Authority processing method and device, electronic equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104580074A (en) * 2013-10-14 2015-04-29 阿里巴巴集团控股有限公司 Logging method of client end application and corresponding server of logging method
CN105610810A (en) * 2015-12-23 2016-05-25 北京奇虎科技有限公司 Data processing method, client and servers
CN105791324A (en) * 2016-05-12 2016-07-20 腾讯科技(深圳)有限公司 Account login method and device
CN109669597A (en) * 2018-10-31 2019-04-23 武汉艺果互动科技股份有限公司 Front end authority control method, equipment and storage equipment when user browses web sites
CN109784033A (en) * 2018-12-13 2019-05-21 平安科技(深圳)有限公司 Operating right Dynamic Configuration and relevant device based on page menus
CN109962908A (en) * 2019-01-22 2019-07-02 深圳壹账通智能科技有限公司 Right management method, device, equipment and storage medium based on token

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104580074A (en) * 2013-10-14 2015-04-29 阿里巴巴集团控股有限公司 Logging method of client end application and corresponding server of logging method
CN105610810A (en) * 2015-12-23 2016-05-25 北京奇虎科技有限公司 Data processing method, client and servers
CN105791324A (en) * 2016-05-12 2016-07-20 腾讯科技(深圳)有限公司 Account login method and device
CN109669597A (en) * 2018-10-31 2019-04-23 武汉艺果互动科技股份有限公司 Front end authority control method, equipment and storage equipment when user browses web sites
CN109784033A (en) * 2018-12-13 2019-05-21 平安科技(深圳)有限公司 Operating right Dynamic Configuration and relevant device based on page menus
CN109962908A (en) * 2019-01-22 2019-07-02 深圳壹账通智能科技有限公司 Right management method, device, equipment and storage medium based on token

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
JERRMY: "一步一步学Vue", pages 1 - 3, Retrieved from the Internet <URL:https://cloud.tencent.com/developer/article/1147255?areaSource=102001.10&traceId=dBs8qBlOaJon8OFrjEVZw> *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112187748A (en) * 2020-09-15 2021-01-05 中信银行股份有限公司 Cross-network access control management method and device and electronic equipment
CN112187748B (en) * 2020-09-15 2022-11-25 中信银行股份有限公司 Cross-network access control management method and device and electronic equipment
CN113472752A (en) * 2021-06-11 2021-10-01 北京达佳互联信息技术有限公司 Authority processing method and device, electronic equipment and storage medium
CN113472752B (en) * 2021-06-11 2023-12-01 北京达佳互联信息技术有限公司 Authority processing method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN111177612B (en) 2023-09-19

Similar Documents

Publication Publication Date Title
CN106970790B (en) Application program creating method, related equipment and system
CN105824958B (en) A kind of methods, devices and systems of inquiry log
CN104618217B (en) Share method, terminal, server and the system of resource
CN105471931B (en) Method, device and system for inquiring service data
CN111597542B (en) Verification information sharing method and device, electronic equipment and storage medium
CN108156508B (en) Barrage information processing method and device, mobile terminal, server and system
CN108834132B (en) Data transmission method and equipment and related medium product
WO2018006841A1 (en) Qr code information transmission method, device and apparatus
CN104298666A (en) Web page sharing method and web page sharing device
CN107832375A (en) Control method, terminal and the server that picture is shown
CN105530239A (en) Multimedia data obtaining method and device
CN103177217A (en) File scan method, file scan system, client-side and server
CN112749074B (en) Test case recommending method and device
CN104901992B (en) A kind of method and apparatus of resource transfers
CN105530222A (en) Method for establishing connection among terminals, and device and system
CN104391629B (en) The method of directive sending message, the method for display message, server and terminal
CN108270764B (en) Application login method, server and mobile terminal
CN111177612B (en) Page login authentication method and related device
CN111273955A (en) Thermal restoration plug-in optimization method and device, storage medium and electronic equipment
CN106339402B (en) Method, device and system for pushing recommended content
CN115794654A (en) Test case distribution processing method, system, equipment and storage medium
CN112214699B (en) Page processing method and related device
CN105578467A (en) System, method and device for accessing to wireless access point
CN114510417A (en) Image rendering effect testing method and device, electronic equipment and storage medium
CN112418835B (en) Method and related device for testing online banking payment process

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant