CN112565239B - Authentication method, device, computer equipment and storage medium for integrating multiple operators - Google Patents

Authentication method, device, computer equipment and storage medium for integrating multiple operators Download PDF

Info

Publication number
CN112565239B
CN112565239B CN202011386309.0A CN202011386309A CN112565239B CN 112565239 B CN112565239 B CN 112565239B CN 202011386309 A CN202011386309 A CN 202011386309A CN 112565239 B CN112565239 B CN 112565239B
Authority
CN
China
Prior art keywords
target
mobile phone
phone number
authentication
login
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.)
Active
Application number
CN202011386309.0A
Other languages
Chinese (zh)
Other versions
CN112565239A (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.)
Shenzhen Hexun Huagu Information Technology Co ltd
Original Assignee
Shenzhen Hexun Huagu Information 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 Shenzhen Hexun Huagu Information Technology Co ltd filed Critical Shenzhen Hexun Huagu Information Technology Co ltd
Priority to CN202011386309.0A priority Critical patent/CN112565239B/en
Publication of CN112565239A publication Critical patent/CN112565239A/en
Application granted granted Critical
Publication of CN112565239B publication Critical patent/CN112565239B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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/08Network architectures or network communication protocols for network security for authentication of entities
    • H04L63/0807Network architectures or network communication protocols for network security for authentication of entities using tickets, e.g. Kerberos
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/06Authentication

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Hardware Design (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Telephonic Communication Services (AREA)

Abstract

The invention discloses an authentication method, an authentication device, computer equipment and a storage medium for integrating multiple operators, wherein the method comprises the following steps of executing authentication SDK: acquiring an authentication request sent by a target application program, analyzing the authentication request, and acquiring a target mobile phone number, a target program identifier and a target server identifier of a user; calling a query interface based on the target mobile phone number to acquire a target operator gateway corresponding to the target mobile phone number; acquiring a corresponding target adaptation interface based on the target operator gateway; interacting with the target operator gateway based on the target adaptation interface, executing an authentication process corresponding to the target mobile phone number, and acquiring an SDK authentication result; and if the SDK authentication result is that the target mobile phone number passes the authentication, constructing a quick login channel between the target application program and the target server corresponding to the target server identification based on the target mobile phone number.

Description

Authentication method, device, computer equipment and storage medium for integrating multiple operators
Technical Field
The present invention relates to the field of communications technologies, and in particular, to an authentication method and apparatus for integrating multiple operators, a computer device, and a storage medium.
Background
In the age of mobile internet, more and more target applications are developed to provide more convenience and entertainment to users.
However, the target application program has more data, and accordingly, the user needs to obtain a mobile phone number sent to the operator to obtain a short message verification code and a voice verification code, and then perform user authentication.
Disclosure of Invention
The embodiment of the invention provides an authentication method, an authentication device, computer equipment and a storage medium for integrating multiple operators, and aims to solve the problems of long waiting time, complex operation and easy leakage of a user authentication method.
An authentication method for integrating multiple operators comprises the following steps executed by an authentication SDK:
acquiring an authentication request sent by a target application program, analyzing the authentication request, and acquiring a target mobile phone number, a target program identifier and a target server identifier of a user;
calling a query interface based on the target mobile phone number to acquire a target operator gateway corresponding to the target mobile phone number;
acquiring a corresponding target adaptation interface based on the target operator gateway;
Interacting with the target operator gateway based on the target adaptation interface, executing an authentication process corresponding to the target mobile phone number, and acquiring an SDK authentication result;
and if the SDK authentication result is that the target mobile phone number passes the authentication, constructing a quick login channel between the target application program and the target server corresponding to the target server identification based on the target mobile phone number.
An authentication apparatus that integrates multiple operators, comprising:
the authentication request acquisition module is used for acquiring an authentication request sent by a target application program, analyzing the authentication request and acquiring a target mobile phone number, a target program identifier and a target server identifier of a user;
the target operator gateway acquisition module is used for calling a query interface based on the target mobile phone number and acquiring a target operator gateway corresponding to the target mobile phone number;
a target adaptation interface obtaining module, configured to obtain a corresponding target adaptation interface based on the target operator gateway;
the first SDK authentication result acquisition module is used for interacting with the target operator gateway based on the target adaptation interface, executing an authentication process corresponding to the target mobile phone number and acquiring an SDK authentication result;
And the login channel creating module is used for creating a quick login channel between the target application program and the target server corresponding to the target server identifier based on the target mobile phone number if the SDK authentication result is that the target mobile phone number passes the authentication.
A computer device comprising a memory, a processor and a computer program stored in said memory and executable on said processor, said processor implementing the steps of the above-described method of integrating authentication of multiple operators when executing said computer program.
A computer-readable storage medium storing a computer program which, when executed by a processor, implements the steps of the above-described method of integrating authentication of multiple operators.
According to the authentication method for integrating multiple operators, the authentication request is analyzed, the target mobile phone number and the target server identification of the user are obtained, the query interface is called based on the target mobile phone number, the target operator gateway corresponding to the target mobile phone number is obtained, the target operator is quickly determined, the target adaptive interface corresponding to the target operator gateway is directly called in the subsequent authentication process, and the authentication efficiency is improved. And the corresponding target adaptation interface is obtained based on the target operator gateway, so that the development cost can be effectively reduced. And interacting with a target operator gateway based on the target adaptation interface, executing an authentication process corresponding to the target mobile phone number, acquiring an SDK authentication result, and providing technical support for subsequent login. And when the SDK authentication result is that the target mobile phone number passes authentication, a quick login channel between the target application program and the target server corresponding to the target server identification is constructed based on the target mobile phone number, login can be realized without a user account and a password, login steps are simplified, and the user experience is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments of the present invention will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without inventive labor.
FIG. 1 is a schematic diagram of an application environment for an authentication method for integrating multiple operators according to an embodiment of the present invention;
FIG. 2 is a flowchart of an authentication method for integrating multiple operators according to an embodiment of the present invention;
FIG. 3 is another flowchart of an authentication method for integrating multiple operators according to an embodiment of the present invention;
FIG. 4 is another flowchart of an authentication method for integrating multiple operators according to an embodiment of the present invention;
FIG. 5 is another flowchart of an authentication method for integrating multiple operators according to an embodiment of the present invention;
FIG. 6 is another flowchart of an authentication method for integrating multiple operators according to an embodiment of the present invention;
FIG. 7 is another flowchart of an authentication method for integrating multiple operators according to an embodiment of the present invention;
FIG. 8 is a schematic block diagram of an authentication device for integrating multiple operators according to an embodiment of the present invention;
FIG. 9 is a schematic diagram of a computing device in accordance with an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The authentication method for integrating multiple operators provided by the embodiment of the invention can be applied to the application environment shown in fig. 1. Specifically, the authentication method for integrating multiple operators is applied to an authentication system for integrating multiple operators, the authentication system for integrating multiple operators comprises a client and a server shown in fig. 1, and the client and the server communicate through a network to improve authentication efficiency. The client is also called a user side, and refers to a program corresponding to the server and providing local service for the client, and the client is integrated with an authentication SDK and a target application program. The client may be installed on, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices. The server may be implemented as a stand-alone server or as a server cluster consisting of a plurality of servers.
In an embodiment, as shown in fig. 2, an authentication method for integrating multiple operators is provided, which is described by taking the example that the method is applied to the authentication SDK of the client in fig. 1, and includes the following steps:
s201: and acquiring an authentication request sent by the target application program, analyzing the authentication request, and acquiring a target mobile phone number, a target program identifier and a target server identifier.
Among them, the target application is a program that the user wants to use. The target application program provided by the embodiment can be software downloaded at a client, and can also be a web target application program, so that diversified choices are provided for a user. The target program identification is an identification for uniquely identifying the target application program.
The target server identifier is an identifier for uniquely identifying a server providing a service for the target application.
The authentication request is a request sent to the authentication SDK by the user by clicking an authentication button on the target application program, and is used for authenticating the target mobile phone number of the user. The target cell phone number is a cell phone number used for authentication.
Specifically, the user's target handset uses the operator network, and the user sends an authentication request to the target application by clicking a button on the target application.
S202: and calling a query interface based on the target mobile phone number to acquire a target operator gateway corresponding to the target mobile phone number.
The inquiry interface is used for determining the interface of the target operator gateway according to the target mobile phone number.
An operator refers to a provider that provides network services, for example, an operator includes, but is not limited to, mobile, telecommunications, and connectivity, etc. The target operator refers to an operator corresponding to a target mobile phone number for the user to authenticate. The target operator gateway is a gateway corresponding to the target operator and is used for realizing data interaction between the authentication SDK and the target operator and providing technical support for realizing authentication of the target mobile phone number of the user.
Specifically, when the authentication SDK obtains the authentication request, the authentication request is analyzed, a target mobile phone number, a target program identifier and a target server identifier are obtained, the query interface is called based on the target mobile phone number to query the database, the target operator gateway corresponding to the target mobile phone number is determined, the target operator gateway is rapidly determined, a target adaptation interface corresponding to the target operator gateway is directly called in a subsequent authentication process, and the authentication efficiency is improved. The target adaptation interface is an interface corresponding to the target operator gateway, and interaction between the authentication SDK and the target operator gateway can be realized through the target adaptation interface.
S203: and acquiring a corresponding target adaptation interface based on the target operator gateway.
In this embodiment, one operator corresponds to one target adaptation interface, and the target adaptation interfaces of all operators are integrated in the authentication SDK integration, so that development cost can be effectively reduced.
S204: and interacting with a target operator gateway based on the target adaptation interface, executing an authentication process corresponding to the target mobile phone number, and acquiring an SDK authentication result.
The authentication process is a process for authenticating a target mobile phone number of a user.
The SDK authentication result is a result obtained by authenticating the target mobile phone number. The SDK authentication result may be authentication failure or authentication pass.
In this embodiment, the authentication SDK interacts with the target operator gateway through the target adaptation interface to execute an authentication procedure corresponding to the target mobile phone number, verify whether the target mobile phone number of the user is accurate, and provide technical support for subsequent login.
S205: and if the SDK authentication result is that the target mobile phone number passes the authentication, constructing a quick login channel between the target application program and the target server corresponding to the target server identification based on the target mobile phone number.
The quick login channel is used for quick login, login can be achieved without the need of the user to fill in the target mobile phone number, the short message, the verification code and the like, and login efficiency and use experience of the user are effectively improved. The login can be realized without a user account and a password, the login steps are simplified, and the user experience is improved.
The authentication method for integrating multiple operators provided by this embodiment analyzes an authentication request, obtains a target mobile phone number and a target server identifier of a user, calls a query interface based on the target mobile phone number, obtains a target operator gateway corresponding to the target mobile phone number, realizes quick determination of a target operator, and directly calls a target adaptation interface corresponding to the target operator gateway in a subsequent authentication process, thereby improving authentication efficiency. And the corresponding target adaptation interface is obtained based on the target operator gateway, so that the development cost can be effectively reduced. And interacting with a target operator gateway based on the target adaptation interface, executing an authentication process corresponding to the target mobile phone number, acquiring an SDK authentication result, and providing technical support for subsequent login. And when the SDK authentication result is that the target mobile phone number passes authentication, a quick login channel between the target application program and the target server corresponding to the target server identification is constructed based on the target mobile phone number, login can be realized without a user account and a password, login steps are simplified, and the user experience is improved.
In an embodiment, as shown in fig. 3, after step S201, that is, after parsing the authentication request and obtaining the target mobile phone number and the target server identifier of the user, the method for integrating the authentication of multiple operators further includes:
s301: judging whether an original token corresponding to the target mobile phone number is stored in the cache or not, wherein the original token corresponds to a target adaptation interface identifier and an effective period;
the cache is a storage space used by the client for storing information, the cache is stored in the CPU, and understandably, the speed of acquiring data from the cache is high, and the time for authentication can be shortened. The target adapter interface identifier is an identifier for uniquely identifying the target adapter interface. The validity period refers to the validity period of the original token.
S302: if the original token corresponding to the target mobile phone number is stored in the cache, judging whether the original token is valid;
in this embodiment, it is determined whether the original token corresponding to the target mobile phone number is stored in the cache, and when the original token corresponding to the target mobile phone number is stored in the cache, it is determined whether the original token is valid, so that a corresponding operation is performed according to the valid original token, thereby shortening the authentication time.
S303: if the original token is valid, determining the original token as an access token;
in this embodiment, when the original token is valid, the original token is determined as the access token, the valid original token is preferentially used, and the original token is determined as the access token, so that the authentication efficiency is effectively improved, and resources are reasonably utilized.
S304: determining a target adaptation interface based on the target adaptation interface identifier, and authenticating the target mobile phone number based on the target adaptation interface and the access token to obtain an SDK authentication result;
specifically, after the authentication SDK obtains the access token, the access token is sent to the client side, so that the client side can send the access token to the server; after receiving the access token, the server performs replacement processing on the target operator gateway through the target adaptation interface based on the access token to obtain a target mobile phone number corresponding to the access token, so as to realize authentication, and understandably, when performing replacement on the target operator based on the access token to obtain the target mobile phone number corresponding to the access token, the SDK authentication result is that the authentication is passed; and when the target operator is replaced based on the access token and the target mobile phone number corresponding to the access token cannot be obtained, the SDK authentication result is that the authentication is not passed.
S305: and if the SDK authentication result is that the target mobile phone number passes the authentication, constructing a quick login channel between the target application program and the target server corresponding to the target server identification based on the target mobile phone number.
In the embodiment, the login can be realized without a user account and a password subsequently, the login steps are simplified, and the user experience is improved.
S306: and if the original token corresponding to the target mobile phone number does not exist in the cache or the original token is invalid, executing calling a query interface based on the target mobile phone number, and acquiring the target operator gateway corresponding to the target mobile phone number.
The authentication method for integrating multiple operators provided by this embodiment determines whether an original token corresponding to a target mobile phone number is stored in a cache, where the original token corresponds to a target adaptation interface identifier and an expiration date; if the original token corresponding to the target mobile phone number is stored in the cache, judging whether the original token is valid; and if the original token is valid, determining the original token as the access token so as to execute corresponding operation according to the valid original token and shorten the authentication time. Determining a target adaptation interface based on the target adaptation interface identifier, authenticating a target mobile phone number based on the target adaptation interface and an access token, and acquiring an SDK authentication result corresponding to the target mobile phone number; if the SDK authentication result is that the target mobile phone number passes authentication, a quick login channel between the target application program and the target server corresponding to the target server identification is constructed based on the target mobile phone number, login can be achieved without a user account and a password subsequently, login steps are simplified, and user experience is improved. And if the original token corresponding to the target mobile phone number does not exist in the cache or the original token is invalid, executing calling a query interface based on the target mobile phone number, and acquiring the target operator gateway corresponding to the target mobile phone number.
In an embodiment, as shown in fig. 4, step S204 is to interact with the target operator gateway based on the target adaptation interface, execute an authentication procedure corresponding to the target mobile phone number, and obtain an SDK authentication result, where the authentication procedure includes:
s401: and based on the target adaptation interface, sending a token acquisition request to the target operator gateway to acquire an access token corresponding to the target mobile phone number and returned by the target operator gateway.
The token acquisition request refers to a request for requesting the token from the target operator gateway by the authentication SDK. Therefore, the authentication can be carried out according to the access token in the following process, and the safety of the authentication process is ensured.
The access token is a token returned to the authentication SDK by the target operator gateway, and the standard mobile phone number can be replaced based on the access token subsequently to judge whether the standard mobile phone number is the same as the target mobile phone number, so that the target mobile phone number is authenticated. The standard mobile phone number refers to an accurate and legal number provided by a target operator.
Further, after the access token corresponding to the target mobile phone number returned by the target operator gateway is obtained, the method further includes storing the access token in a cache. The access token comprises a validity period, the access token is stored in the cache, if errors occur in subsequent steps, whether the access token corresponding to the target mobile phone number is in the validity period can be inquired, if the access token corresponding to the target mobile phone number is in the validity period, the access token can be used for continuing verification, time is effectively saved, verification efficiency is improved, and the problems that in the prior art, when errors occur in authentication, all steps need to be executed again, authentication waiting time is long, and clients are lost are solved. The validity period refers to the validity period of the access token, and may be 600 seconds, for example.
S402: and authenticating the target mobile phone number based on the target adaptation interface and the access token to obtain an SDK authentication result.
In this embodiment, authentication processing is performed according to the access token to ensure security of the authentication process.
Specifically, the authenticating the target mobile phone number based on the target adaptation interface and the access token includes: after the authentication SDK obtains the access token, the access token is sent to the client side, so that the client side can send the access token to the server; after receiving the access token, the server performs replacement processing on the target operator gateway through the target adaptation interface based on the access token to obtain a target mobile phone number corresponding to the access token, so as to realize authentication, and understandably, when performing replacement on the target operator based on the access token to obtain the target mobile phone number corresponding to the access token, the SDK authentication result is that the authentication is passed; and when the target operator is replaced based on the access token and the target mobile phone number corresponding to the access token cannot be obtained, the SDK authentication result is that the authentication is not passed.
In this embodiment, based on the target adaptation interface, a token acquisition request is sent to the target operator gateway to acquire an access token corresponding to the target mobile phone number, which is returned by the target operator gateway, so that the standard mobile phone number can be replaced based on the access token in the following, to judge whether the standard mobile phone number is the same as the target mobile phone number, thereby implementing authentication on the target mobile phone number and ensuring the security of the authentication process. And authenticating the target mobile phone number based on the target adaptation interface and the access token to obtain an SDK authentication result.
In an embodiment, as shown in fig. 5, before step S401, that is, before sending the token obtaining request to the target operator gateway based on the target adaptation interface, the method for integrating authentication of multiple operators further includes:
s501: and sending a pre-fetching number request to the target operator gateway based on the target adaptation interface.
The pre-fetching number request is a request for requesting a user to log in a mask corresponding to a target mobile phone number of a target application program, and technical support is provided for a subsequent authentication process.
S502: receiving a mobile phone mask returned by a target operator gateway, sending the mobile phone mask to a target application program, and receiving authorization information fed back by the target application program;
the mobile phone mask refers to a mask corresponding to a target mobile phone number of a user logging in a target application program, and for example, the mobile phone mask may be 136xxxxx 832. The authorization information refers to information that the user authorizes to perform authentication.
Specifically, the authentication SDK sends a pre-number-fetching request to the target operator gateway, meanwhile, the client displays a skip authorization interface process, and when a mobile phone mask sent by the target operator gateway is obtained, the client displays the authorization interface, so that the skip speed of the authorization interface can be increased, the waiting time of a user is reduced, the number-fetching efficiency is improved, and the waiting time of the authorization interface is shortened. And the user clicks an authorization button on the authorization interface and sends authorization information to the authentication SDK so that the authentication SDK can determine whether the mobile phone mask is accurate or not and ensure the accuracy of subsequent authentication.
S503: and if the authorization information comprises the confirmation identification, sending a token acquisition request to the target operator gateway based on the target adaptation interface.
In this embodiment, when the authorization information includes the confirmation identifier, the token acquisition request is sent to the target operator gateway based on the target adaptation interface, so as to ensure accuracy of subsequent authentication.
The authentication method for integrating multiple operators provided by this embodiment sends a pre-fetch number request to a target operator gateway based on a target adaptation interface, so as to provide technical support for a subsequent authentication process. And receiving the mobile phone mask returned by the gateway of the target operator, and sending the mobile phone mask to the target application program, so that the jumping speed of the authorization interface can be accelerated, the waiting time of a user is reduced, the number fetching efficiency is improved, and the waiting time of the authorization interface is shortened. Receiving authorization information fed back by a target application program; if the authorization information comprises the confirmation identification, a token acquisition request is sent to the target operator gateway based on the target adaptation interface so as to ensure the accuracy of subsequent authentication.
In an embodiment, as shown in fig. 6, before step S401, that is, before sending the token obtaining request to the target operator gateway based on the target adaptation interface, the method for integrating authentication of multiple operators further includes:
S601: and sending a configuration information acquisition request to the server, and receiving the original configuration information returned by the server.
In this embodiment, the configuration information acquisition request is a request for acquiring information of the target application program.
The original configuration information refers to the information, such as appid, appKey, appsect and the like, which is filled when a developer applies for developing a target application program, wherein appid can be understood as a target application program number and is used for uniquely identifying the identifier of the target application program. secretpap refers to an API interface key, which can be understood as a private key.
In this embodiment, a developer applies for developing a target application program on a developer website to obtain the appid, appKey, appserct, and the like of the target application program, and stores the appid, appKey, and appserct of the target application program in a server in an associated manner to ensure data security, and then may obtain an access token according to the appid, appKey, and appserct of the target application program. When authentication is needed, a configuration information acquisition request is sent to the server so as to quickly receive the original configuration information returned by the server.
S602: acquiring a plurality of original adaptation interfaces corresponding to a target operator gateway based on original configuration information;
The original adaptation interface is an interface used for authentication on the target operator gateway.
S603: and acquiring the interface grades of all the original adaptation interfaces, and determining the original adaptation interface with the highest interface grade as the target adaptation interface.
The interface level refers to a level corresponding to the original adapter interface, for example, the interface level corresponding to the original adapter interface 1 is level26, the interface level corresponding to the original adapter interface 2 is level12, and the like.
In this embodiment, the interface grades of all the original adaptation interfaces are obtained, and the original adaptation interface with the highest interface grade is determined as the target adaptation interface, so as to ensure the safety of the user information and ensure the smooth proceeding of the authentication process.
The target adaptation interface is obtained based on the original adaptation interface and is used for realizing interaction between the authentication SDK and the target operator.
The authentication method for integrating multiple operators provided by this embodiment sends a configuration information acquisition request to a server, and receives original configuration information returned by the server; acquiring a plurality of original adaptation interfaces corresponding to a target operator gateway based on original configuration information; and acquiring the interface grades of all the original adaptation interfaces, and determining the original adaptation interface with the highest interface grade as a target adaptation interface so as to ensure the safety of user information and ensure the smooth operation of an authentication process.
In an embodiment, as shown in fig. 7, after step S205, that is, after building the fast login channel between the target application and the target server corresponding to the target server identifier, the authentication method for integrating multiple operators further includes:
s701: acquiring a login request, wherein the quick login request comprises a target program identifier, a target server identifier and a login mobile phone number;
s702: judging whether the target program identification is matched with the login program identification, the target server identification is matched with the login server identification, and the target mobile phone number is matched with the login mobile phone number;
s703: and if the target program identification is matched with the login program identification, the target server identification is matched with the login server identification, and the target mobile phone number is matched with the login mobile phone number, responding to the login request based on the quick login channel so as to enable the user to quickly login the program corresponding to the program identification.
In the authentication method for integrating multiple operators provided in this embodiment, when the target program identifier is matched with the login program identifier, the target server identifier is matched with the login server identifier, and the target mobile phone number is matched with the login mobile phone number, the user can quickly log in by using the quick login channel.
It should be understood that, the sequence numbers of the steps in the foregoing embodiments do not imply an execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
In one embodiment, an authentication device for integrating multiple operators is provided, and the authentication device for integrating multiple operators corresponds to the authentication method for integrating multiple operators in the above embodiment one to one. As shown in fig. 8, the authentication apparatus for integrating multiple operators includes an authentication request obtaining module 801, a target operator gateway obtaining module 802, a target adaptation interface obtaining module 803, a first SDK authentication result obtaining module 804, and a first login channel creating module 805. The detailed description of each functional module is as follows:
an authentication request obtaining module 801, configured to obtain an authentication request sent by a target application, analyze the authentication request, and obtain a target mobile phone number, a target program identifier, and a target server identifier of a user;
a target operator gateway obtaining module 802, configured to call a query interface based on the target mobile phone number, and obtain a target operator gateway corresponding to the target mobile phone number;
a target adaptation interface obtaining module 803, configured to obtain a corresponding target adaptation interface based on the target operator gateway;
a first SDK authentication result obtaining module 804, configured to interact with the target operator gateway based on the target adaptation interface, execute an authentication procedure corresponding to the target mobile phone number, and obtain an SDK authentication result;
And a login channel creating module 805, configured to, if the SDK authentication result is that the target mobile phone number passes authentication, construct a fast login channel between the target application and the target server corresponding to the target server identifier based on the target mobile phone number.
Preferably, after the authentication request obtaining module 801, the authentication device for integrating multiple operators further includes: the system comprises an original token judgment module, an effective module, a second SDK authentication result acquisition module, a login channel creation module and an ineffective module.
The original token judging module is used for judging whether an original token corresponding to the target mobile phone number is stored in a cache or not, and the original token is corresponding to a target adaptive interface identifier and an effective period;
the validity judging module is used for judging whether the original token is valid or not if the original token corresponding to the target mobile phone number is stored in the cache;
the valid module is used for determining the original token as an access token if the original token is valid;
the second SDK authentication result acquisition module is used for determining a target adaptation interface based on the target adaptation interface identifier and acquiring an SDK authentication result corresponding to a target mobile phone number based on the target adaptation interface and the access token;
The login channel creating module is used for the original token judging module and is used for creating a quick login channel between the target application program and the target server corresponding to the target server identification based on the target mobile phone number if the SDK authentication result is that the target mobile phone number passes the authentication;
and the invalidation module is used for the original token judgment module and is used for executing the target mobile phone number-based calling inquiry interface and acquiring the target operator gateway corresponding to the target mobile phone number if the original token corresponding to the target mobile phone number does not exist in the cache or the original token is invalid.
Preferably, the first SDK authentication result obtaining module 804 includes: an access token acquisition unit and an SDK authentication result acquisition unit.
An access token obtaining unit, configured to send a token obtaining request to the target operator gateway based on the target adaptation interface, and obtain an access token corresponding to the target mobile phone number and returned by the target operator gateway;
and the SDK authentication result acquisition unit is used for carrying out authentication processing on the target mobile phone number based on the target adaptation interface and the access token to acquire an SDK authentication result.
Preferably, before the access token acquiring unit, the authentication apparatus for integrated multi-operator further comprises: a prefetch number request unit, an authorization information receiving unit, and a token acquisition request transmitting unit.
A prefetch number request unit, configured to send a prefetch number request to the target operator gateway based on the target adaptation interface;
the authorization information receiving unit is used for receiving the mobile phone mask code returned by the target operator gateway, sending the mobile phone mask code to the target application program and receiving the authorization information fed back by the target application program;
a token obtaining request sending unit, configured to execute the sending of a token obtaining request to the target operator gateway based on the target adaptation interface if the authorization information includes a confirmation identifier.
Preferably, before the access token obtaining unit, the authentication apparatus for integrating multiple operators further includes: the device comprises an original configuration information receiving unit, an original adaptation interface determining unit and a target adaptation interface determining unit.
The system comprises an original configuration information receiving unit, a configuration information acquisition unit and a configuration information processing unit, wherein the original configuration information receiving unit is used for sending a configuration information acquisition request to a server and receiving original configuration information returned by the server;
An original adaptation interface determining unit, configured to obtain multiple original adaptation interfaces corresponding to a target operator gateway based on the original configuration information;
and the target adaptation interface determining unit is used for acquiring the interface grades of all the original adaptation interfaces and determining the original adaptation interface with the highest interface grade as the target adaptation interface.
Preferably, after the first login channel creating module 805, the authentication device for integrating multiple operators further comprises: the device comprises a login request acquisition module, an identification determination module and a login module.
The login request acquisition module is used for acquiring a login request, wherein the quick login request comprises a login program identifier, a login server identifier and a login mobile phone number;
the identification determining module is used for judging whether the target program identification is matched with the login program identification, the target server identification is matched with the login server identification, and the target mobile phone number is matched with the login mobile phone number;
and the login module is used for responding a login request based on a quick login channel so as to enable a user to quickly login a program corresponding to the program identifier if the target program identifier is matched with the login program identifier, the target server identifier is matched with the login server identifier, and the target mobile phone number is matched with the login mobile phone number.
For the specific limitation of the authentication device for integrating multiple operators, reference may be made to the above limitation on the authentication method for integrating multiple operators, which is not described herein again. The modules in the authentication device for integrating multiple operators can be wholly or partially realized by software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as shown in fig. 8. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The database of the computer device is used for storing access tokens. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement an authentication method that integrates multiple operators.
In an embodiment, a computer device is provided, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the processor executes the computer program, the steps of the authentication method for integrating multiple operators in the foregoing embodiments are implemented, for example, steps S201 to S205 shown in fig. 2 or steps shown in fig. 3 to fig. 7, which are not repeated herein to avoid repetition. Alternatively, the processor implements the functions of the modules/units in the embodiment of integrating the authentication devices of multiple operators when executing the computer program, for example, the functions of the authentication request obtaining module 801, the target operator gateway obtaining module 802, the target adaptation interface obtaining module 803, the first SDK authentication result obtaining module 804 and the first login channel creating module 805 shown in fig. 8, which are not described herein again to avoid repetition.
In an embodiment, a computer-readable storage medium is provided, where a computer program is stored on the computer-readable storage medium, and when executed by a processor, the computer program implements the steps of the authentication method for integrating multiple operators in the foregoing embodiments, such as steps S201 to S205 shown in fig. 2 or steps shown in fig. 3 to fig. 7, which are not repeated herein to avoid repetition. Alternatively, the processor implements the functions of the modules/units in the embodiment of integrating the authentication devices of multiple operators when executing the computer program, for example, the functions of the authentication request obtaining module 801, the target operator gateway obtaining module 802, the target adaptation interface obtaining module 803, the first SDK authentication result obtaining module 804 and the first login channel creating module 805 shown in fig. 8, which are not described herein again to avoid repetition.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory, among others. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-mentioned functions.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will 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; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present invention, and are intended to be included within the scope of the present invention.

Claims (9)

1. An authentication method for integrating multiple operators is characterized by comprising the following steps executed by an authentication SDK:
acquiring an authentication request sent by a target application program, analyzing the authentication request, and acquiring a target mobile phone number, a target program identifier and a target server identifier of a user;
Calling a query interface based on the target mobile phone number to acquire a target operator gateway corresponding to the target mobile phone number;
acquiring a corresponding target adaptation interface based on the target operator gateway;
sending a pre-fetch number request to the target operator gateway based on the target adaptation interface;
receiving a mobile phone mask returned by the target operator gateway, sending the mobile phone mask to the target application program, and receiving authorization information fed back by the target application program;
if the authorization information comprises a confirmation identifier, interacting with the target operator gateway based on the target adaptation interface, executing an authentication process corresponding to the target mobile phone number, and acquiring an SDK authentication result;
and if the SDK authentication result is that the target mobile phone number passes the authentication, constructing a quick login channel between the target application program and the target server corresponding to the target server identification based on the target mobile phone number.
2. The method as claimed in claim 1, wherein after parsing the authentication request to obtain the target phone number, the target program identifier and the target server identifier of the user, the method further comprises:
Judging whether an original token corresponding to the target mobile phone number is stored in a cache or not, wherein the original token is corresponding to a target adaptive interface identifier and a valid period;
if the original token corresponding to the target mobile phone number is stored in the cache, judging whether the original token is valid;
if the original token is valid, determining the original token as an access token;
determining a target adaptation interface based on the target adaptation interface identifier, and authenticating a target mobile phone number based on the target adaptation interface and an access token to obtain an SDK authentication result;
if the SDK authentication result is that the target mobile phone number passes the authentication, a quick login channel between the target application program and a target server corresponding to the target server identification is constructed based on the target mobile phone number;
and if the original token corresponding to the target mobile phone number does not exist in the cache or the original token is invalid, executing the calling query interface based on the target mobile phone number to acquire the target operator gateway corresponding to the target mobile phone number.
3. The method as claimed in claim 1, wherein the interacting with the target operator gateway based on the target adaptation interface, executing the authentication procedure corresponding to the target mobile phone number, and obtaining the SDK authentication result comprises:
Based on the target adaptation interface, sending a token acquisition request to the target operator gateway to acquire an access token corresponding to the target mobile phone number and returned by the target operator gateway;
and authenticating the target mobile phone number based on the target adaptation interface and the access token to obtain an SDK authentication result.
4. The method of claim 3, wherein before sending a token acquisition request to the target operator gateway based on the target adaptation interface, the method further comprises:
sending a configuration information acquisition request to a server, and receiving original configuration information returned by the server;
acquiring a plurality of original adaptation interfaces corresponding to a target operator gateway based on the original configuration information;
and acquiring the interface grades of all the original adaptation interfaces, and determining the original adaptation interface with the highest interface grade as the target adaptation interface.
5. The method as claimed in claim 1, wherein after the building of the fast login channel between the target application and the target server corresponding to the target server identifier based on the target phone number, the method further comprises:
Acquiring a quick login request, wherein the quick login request comprises a login program identifier, a login server identifier and a login mobile phone number;
judging whether the target program identification is matched with the login program identification, the target server identification is matched with the login server identification, and the target mobile phone number is matched with the login mobile phone number;
and if the target program identification is matched with the login program identification, the target server identification is matched with the login server identification, and the target mobile phone number is matched with the login mobile phone number, responding to a quick login request based on a quick login channel so as to enable a user to quickly login the program corresponding to the program identification.
6. An authentication apparatus for integrating multiple operators, comprising:
the authentication request acquisition module is used for acquiring an authentication request sent by a target application program, analyzing the authentication request and acquiring a target mobile phone number, a target program identifier and a target server identifier of a user;
the target operator gateway acquisition module is used for calling a query interface based on the target mobile phone number and acquiring a target operator gateway corresponding to the target mobile phone number;
a target adaptation interface obtaining module, configured to obtain a corresponding target adaptation interface based on the target operator gateway;
A prefetch number request module, configured to send a prefetch number request to the target operator gateway based on the target adaptation interface;
the authorization information receiving module is used for receiving the mobile phone mask code returned by the target operator gateway, sending the mobile phone mask code to the target application program and receiving the authorization information fed back by the target application program;
a first SDK authentication result obtaining module, configured to interact with the target operator gateway based on the target adaptation interface if the authorization information includes a confirmation identifier, execute an authentication procedure corresponding to the target mobile phone number, and obtain an SDK authentication result;
and the login channel creating module is used for creating a quick login channel between the target application program and the target server corresponding to the target server identifier based on the target mobile phone number if the SDK authentication result is that the target mobile phone number passes the authentication.
7. The integrated multi-operator certification device according to claim 6, wherein after the certification request acquiring module, the integrated multi-operator certification device further comprises:
the original token judging module is used for judging whether an original token corresponding to the target mobile phone number is stored in a cache or not, and the original token is corresponding to a target adaptive interface identifier and an effective period;
The validity judging module is used for judging whether the original token is valid or not if the original token corresponding to the target mobile phone number is stored in the cache;
the valid module is used for determining the original token as an access token if the original token is valid;
the second SDK authentication result acquisition module is used for determining a target adaptation interface based on the target adaptation interface identifier and acquiring an SDK authentication result corresponding to a target mobile phone number based on the target adaptation interface and the access token;
the login channel creating module is used for the original token judging module and is used for creating a quick login channel between the target application program and the target server corresponding to the target server identification based on the target mobile phone number if the SDK authentication result is that the target mobile phone number passes the authentication;
and the invalidation module is used for the original token judgment module and is used for executing the target mobile phone number-based calling inquiry interface and acquiring the target operator gateway corresponding to the target mobile phone number if the original token corresponding to the target mobile phone number does not exist in the cache or the original token is invalid.
8. A computer arrangement comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor, when executing the computer program, carries out the steps of the method of integrating authentication of multiple operators according to any one of claims 1 to 5.
9. A computer-readable storage medium, in which a computer program is stored, which, when being executed by a processor, carries out the steps of the method of integrating authentication of multiple operators according to any one of claims 1 to 5.
CN202011386309.0A 2020-12-01 2020-12-01 Authentication method, device, computer equipment and storage medium for integrating multiple operators Active CN112565239B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011386309.0A CN112565239B (en) 2020-12-01 2020-12-01 Authentication method, device, computer equipment and storage medium for integrating multiple operators

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011386309.0A CN112565239B (en) 2020-12-01 2020-12-01 Authentication method, device, computer equipment and storage medium for integrating multiple operators

Publications (2)

Publication Number Publication Date
CN112565239A CN112565239A (en) 2021-03-26
CN112565239B true CN112565239B (en) 2022-07-29

Family

ID=75047036

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011386309.0A Active CN112565239B (en) 2020-12-01 2020-12-01 Authentication method, device, computer equipment and storage medium for integrating multiple operators

Country Status (1)

Country Link
CN (1) CN112565239B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114051243B (en) * 2021-10-16 2023-09-26 北京达佳互联信息技术有限公司 Verification method, verification device, electronic equipment and storage medium
CN114338132B (en) * 2021-12-24 2023-08-01 中国联合网络通信集团有限公司 Secret-free login method, client application, operator server and electronic equipment

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102325210A (en) * 2011-05-19 2012-01-18 武汉天喻信息产业股份有限公司 Universal mobile payment terminal compatible with multiple operators and implementation method thereof
CN103944737B (en) * 2014-05-06 2018-11-02 中国联合网络通信集团有限公司 Method for authenticating user identity, Third Party Authentication platform, carrier authorization platform
CN110336778A (en) * 2019-05-06 2019-10-15 中国联合网络通信集团有限公司 A kind of identity identifying method, apparatus and system
CN111010363B (en) * 2019-09-20 2022-04-05 中国银联股份有限公司 Information authentication method and system, authentication module and user terminal
CN111740942B (en) * 2020-01-17 2022-11-08 北京沃东天骏信息技术有限公司 Login/registration method, device, system, electronic equipment and storage medium
CN111885043B (en) * 2020-07-20 2022-03-29 中国联合网络通信集团有限公司 Internet account login method, system, equipment and storage medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
基于Portal技术的高校多运营商网络认证系统研究与实现;陶浩;《江苏科技信息》;20191110(第31期);全文 *
运营商统一移动认证方案与应用;张荣等;《广东通信技术》;20161115(第11期);全文 *

Also Published As

Publication number Publication date
CN112565239A (en) 2021-03-26

Similar Documents

Publication Publication Date Title
US10223520B2 (en) System and method for integrating two-factor authentication in a device
US10674009B1 (en) Validating automatic number identification data
CN107196950B (en) Verification method, verification device and server
CN108322416B (en) Security authentication implementation method, device and system
CN112559993B (en) Identity authentication method, device and system and electronic equipment
WO2020233308A1 (en) Self-checking method, apparatus and device based on local certificate, and storage medium
CN110365684B (en) Access control method and device for application cluster and electronic equipment
TW201724878A (en) Method and system for website registration on the basis of mobile phone message
CN113765906B (en) Method, equipment and system for one-key login of terminal application program
CN110266642A (en) Identity identifying method and server, electronic equipment
CN112565239B (en) Authentication method, device, computer equipment and storage medium for integrating multiple operators
US10805083B1 (en) Systems and methods for authenticated communication sessions
CN109286933B (en) Authentication method, device, system, computer equipment and storage medium
CN106713315B (en) Login method and device of plug-in application program
CN112165448B (en) Service processing method, device, system, computer equipment and storage medium
CN113938886A (en) Identity authentication platform test method, device, equipment and storage medium
CN107645474B (en) Method and device for logging in open platform
CN110225511B (en) Method, device and system for acquiring IMEI number of terminal and computer equipment
CN112966242A (en) User name and password authentication method, device and equipment and readable storage medium
CN111355800A (en) Service processing method, device, equipment and storage medium
CN112597118B (en) Shared file adding method and device
US20190199704A1 (en) System and method for non-numeric authentication using a legacy telephone
CN112543194B (en) Mobile terminal login method and device, computer equipment and storage medium
CN113901428A (en) Login method and device of multi-tenant system
CN111064675A (en) Access flow control method, device, network equipment and storage medium

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