A protocol authentication method and device, electronic equipment and storage medium

By generating authentication interfaces through a plugin engine, the problem of requiring extensive code modifications to add new authentication protocols in existing technologies is solved. This enables dynamic loading and unloading of multiple protocols, improving the scalability and efficiency of the authentication system.

CN117540365BActive Publication Date: 2026-11-24WEAVER NETWORK TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202311694835.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-11
Publication Date
2026-11-24
Estimated Expiration
2043-12-11

AI Technical Summary

Technical Problem

Existing technologies require extensive code modifications when adding new authentication protocols, resulting in low work efficiency and increased system complexity, making it difficult to effectively support multiple protocols.

Method used

By using a plugin engine, corresponding authentication interfaces are generated based on the authentication protocol type, enabling dynamic loading and unloading of different protocols. The authentication protocol engine loads the authentication protocol logic and generates the authentication interface.

Benefits of technology

It improves the scalability and efficiency of the authentication protocol, reduces the workload for users, and enhances the accuracy and security of authentication.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117540365B_ABST
    Figure CN117540365B_ABST
Patent Text Reader

Abstract

This application provides a protocol authentication method, apparatus, electronic device, and storage medium. The method includes: receiving an authentication request; the authentication request includes an authentication protocol type; sending the authentication request to a pre-generated authentication interface according to the authentication protocol type to execute a protocol authentication method within the authentication interface and obtain an authentication result; the authentication interface generates a configuration authentication source based on the authentication protocol type and authentication source information, inputs the configuration authentication source into an authentication protocol engine, and loads the authentication protocol logic corresponding to the authentication protocol type; wherein the authentication protocol logic corresponding to the authentication protocol type is pre-set and stored. By adopting a plug-in engine approach, dynamic loading and unloading of different protocols is achieved, improving the scalability of the authentication protocol and mitigating the inefficiency caused by re-developing code when adding new protocols, thus improving work efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and more specifically, to a protocol authentication method, apparatus, electronic device, and storage medium. Background Technology

[0002] With the rapid development of network applications, various authentication protocols are widely used. Existing technologies mainly support specific protocols through hard coding. When a new authentication protocol needs to be added to the system, the code needs to be redeveloped or a large amount of code needs to be modified, resulting in low work efficiency and poor scalability of authentication protocols. Summary of the Invention

[0003] The purpose of this application is to provide a protocol authentication method, apparatus, electronic device, and storage medium. The method involves inputting the acquired configuration authentication source into an authentication protocol engine, loading the authentication protocol logic corresponding to the authentication protocol type, and then generating authentication interfaces corresponding to different authentication protocol types. Upon receiving an authentication request, the method sends the authentication protocol to the corresponding authentication interface according to the authentication protocol type in the request, thereby enabling identity verification using that authentication interface.

[0004] In a first aspect, embodiments of this application provide a protocol authentication method, comprising: receiving an authentication request; the authentication request including an authentication protocol type; sending the authentication request to a pre-generated authentication interface according to the authentication protocol type to execute a protocol authentication method within the authentication interface and obtain an authentication result; the authentication interface generates a configuration authentication source based on the authentication protocol type and authentication source information, inputs the configuration authentication source into an authentication protocol engine, and loads the authentication protocol logic corresponding to the authentication protocol type; wherein the authentication protocol logic corresponding to the authentication protocol type is pre-set and stored.

[0005] In the above implementation process, the acquired authentication source is input into the authentication protocol engine. After loading the authentication protocol logic, authentication interfaces corresponding to different authentication protocol types are generated. Upon receiving an authentication request, the authentication protocol is sent to the corresponding authentication interface according to the authentication protocol type in the request, thus enabling authentication using that protocol. By adopting a plugin engine approach, dynamic loading and unloading of different protocols is achieved, improving the scalability of authentication protocols and mitigating the inefficiency caused by redeveloping code when adding protocols, thereby improving work efficiency.

[0006] Optionally, in this embodiment of the application, before sending the authentication request to the pre-generated authentication interface according to the authentication protocol type, the method further includes: obtaining a pre-determined authentication protocol type; configuring authentication source information according to the authentication protocol type; encapsulating the authentication source information to generate a configured authentication source; inputting the configured authentication source into the authentication protocol engine, loading the authentication protocol logic through the authentication protocol engine, and generating the authentication interface.

[0007] In the above implementation process, the authentication source is generated using the authentication protocol type and authentication source information. Then, the authentication protocol logic corresponding to the authentication protocol type is loaded through the authentication protocol engine to generate the authentication interface. This encapsulates different authentication functions or authentication services into independent interfaces or plugins, and integrates different types of authentication protocols into the same system for unified management, so that the interfaces can be flexibly called to perform authentication when needed.

[0008] Optionally, in this embodiment, configuring authentication source information according to the authentication protocol type includes: determining the protocol configuration parameters corresponding to the authentication protocol type from the template library according to the authentication protocol type; rendering the corresponding protocol configuration page based on the protocol configuration parameters; receiving the authentication source information configured by the user based on the protocol configuration page; the authentication source information includes the interface information corresponding to the authentication protocol type.

[0009] In the above implementation process, the corresponding protocol configuration page is rendered based on the protocol configuration parameters. Users can use the authentication source information configured on the protocol configuration page to reduce the workload of users and improve work efficiency.

[0010] Optionally, in this embodiment of the application, loading the authentication protocol logic through the authentication protocol engine to generate the authentication interface includes: using the authentication protocol engine to parse the protocol structure in the authentication protocol logic according to the protocol definition and / or protocol rules corresponding to the authentication protocol logic, and obtaining the structure parsing result; encapsulating the structure parsing result to generate the authentication interface.

[0011] In the above implementation process, the authentication protocol logic is loaded through the authentication protocol engine to generate the authentication interface, which improves the efficiency caused by the need to redevelop the code when adding new protocols and improves work efficiency.

[0012] Optionally, in this embodiment of the application, the structure parsing result is encapsulated to generate an authentication interface, including: performing parameter verification on the structure parsing result to obtain parameter verification results; the parameter verification results include parameter validity verification results and parameter integrity verification results; if the parameter validity verification results and parameter integrity verification results indicate that the verification is passed, the structure parsing result is encapsulated to generate an authentication interface.

[0013] In the above implementation process, the authentication protocol engine verifies the legality and completeness of the authentication protocol logic parameters to avoid authentication failure due to incorrect or incomplete authentication protocol logic parameters, thereby improving the accuracy of authentication.

[0014] Optionally, in this embodiment of the application, after obtaining the structure parsing result, the method further includes: obtaining identity information and permission information from the authentication protocol logic; verifying the identity information through the authentication protocol engine to obtain the authentication result; verifying the permission information through the authentication protocol engine to obtain the permission verification result; and encapsulating the structure parsing result to generate an authentication interface, including: encapsulating the structure parsing result, the authentication result, and the permission verification result to generate an authentication interface.

[0015] In the above implementation process, authentication and permission verification are performed separately through the authentication protocol engine. The structure parsing results, authentication results, and permission verification results are encapsulated to generate an authentication interface, thereby improving the security of the authentication interface and thus improving the security of protocol authentication.

[0016] Optionally, in this embodiment, executing the protocol authentication method within the authentication interface to obtain the authentication result includes: sending an authentication request to the protocol interface engine through the authentication interface; the protocol interface engine is used to maintain and manage the authentication interface; maintenance and management include adding authentication interfaces, deleting authentication interfaces, and modifying the protocol authentication method within the authentication interface; forwarding the authentication request to the unified authentication manager using the protocol interface engine; the unified authentication manager is used to receive and process the authentication request; and the unified authentication manager calls the protocol processing engine according to the authentication protocol type to execute the authentication protocol logic and obtain the authentication result.

[0017] In the above implementation process, different authentication functions or services are encapsulated into independent interfaces or plugins. When authentication is required, the authentication request is sent to the pre-generated authentication interface to execute the protocol authentication method within the authentication interface and obtain the authentication result. By integrating different types of authentication protocols into the same system for unified management, a single system can implement the protocol authentication methods of multiple authentication interfaces, improving the convenience of authentication.

[0018] Secondly, embodiments of this application also provide a protocol authentication device, including: a request receiving module for receiving authentication requests; the authentication request includes an authentication protocol type; a protocol authentication module for sending the authentication request to a pre-generated authentication interface according to the authentication protocol type, to execute the protocol authentication method within the authentication interface, and obtain an authentication result; the authentication interface generates a configuration authentication source based on the authentication protocol type and authentication source information, inputs the configuration authentication source into the authentication protocol engine, and loads the authentication protocol logic corresponding to the authentication protocol type; wherein, the authentication protocol logic corresponding to the authentication protocol type is pre-set and stored.

[0019] Thirdly, embodiments of this application also provide an electronic device, including: a processor and a memory, the memory storing machine-readable instructions executable by the processor, which, when executed by the processor, perform the method described above.

[0020] Fourthly, embodiments of this application also provide a computer-readable storage medium storing a computer program that, when executed by a processor, performs the methods described above.

[0021] The authentication method, apparatus, electronic device, and storage medium provided in this application input the acquired configuration authentication source into the authentication protocol engine. After loading the authentication protocol logic, authentication interfaces corresponding to different authentication protocol types are generated. Upon receiving an authentication request, the authentication protocol is sent to the corresponding authentication interface according to the authentication protocol type in the request, thus enabling identity verification using that authentication protocol. By employing a plug-in engine approach, dynamic loading and unloading of different protocols is achieved, improving the scalability of the authentication protocol and mitigating the inefficiency caused by re-developing code when adding new protocols, thereby improving work efficiency. Attached Figure Description

[0022] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0023] Figure 1 A schematic flowchart illustrating a protocol authentication method provided in an embodiment of this application;

[0024] Figure 2 This is a schematic diagram of components supporting different protocol authentication sources for unified authentication in an embodiment of this application;

[0025] Figure 3A schematic diagram of the protocol authentication device provided in the embodiments of this application;

[0026] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0027] The embodiments of the technical solution of this application will now be described in detail with reference to the accompanying drawings. These embodiments are only used to more clearly illustrate the technical solution of this application and are therefore merely examples, and should not be used to limit the scope of protection of this application.

[0028] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit this application.

[0029] In the description of the embodiments of this application, technical terms such as "first" and "second" are used only to distinguish different objects and should not be construed as indicating or implying relative importance or implicitly specifying the number, specific order, or primary and secondary relationship of the indicated technical features. In the description of the embodiments of this application, "multiple" means two or more, unless otherwise explicitly defined.

[0030] An authentication protocol is an agreement used to verify and confirm the true identity, authority, or ownership of a party. Its primary function is to ensure that the identity and authorization of participating parties are accurately verified and confirmed when conducting various transactions, accessing, or using specific services. Authentication protocols can be used in various situations, including network security, electronic payments, login systems, and data access. By using authentication protocols, unauthorized access or activities can be effectively prevented, and the interests and security of participating parties can be protected.

[0031] With the rapid development of network applications, various types of authentication protocols are widely used, such as LDAP (Lightweight Directory Access Protocol), RADIUS (Remote Authentication Dial-In User Service), OAuth 2.0 (Open Authorization Protocol), and CAS (Central Authentication Service). However, different protocols have their own unique authentication mechanisms and data formats, making it difficult to support multiple protocols within a single authentication system.

[0032] To address the aforementioned issues, existing technologies primarily rely on hard-coding to support different protocols. When support for a new protocol needs to be added, extensive code modifications are required. This not only increases the development workload and reduces efficiency but also increases system complexity and the likelihood of errors.

[0033] This application provides a protocol authentication method, apparatus, electronic device, and storage medium. By using a plug-in engine, authentication interfaces corresponding to different authentication protocol types are generated based on configuration information. This enables dynamic loading and unloading of different protocols, improving the scalability of authentication protocols and mitigating the inefficiency caused by re-developing code when adding new protocols, thereby increasing work efficiency.

[0034] Please see Figure 1 The illustrated diagram shows a flowchart of a protocol authentication method provided in an embodiment of this application. The protocol authentication method provided in this application can be applied to electronic devices equipped with authentication services or authentication systems. The electronic device may include a terminal and a server; specifically, the terminal may be a smartphone, tablet computer, computer, personal digital assistant (PDA), etc.; the server may be an application server or a web server. The protocol authentication method may include:

[0035] Step S110: Receive authentication request; the authentication request includes the authentication protocol type.

[0036] Step S120: Based on the authentication protocol type, send the authentication request to the pre-generated authentication interface to execute the protocol authentication method within the authentication interface and obtain the authentication result; the authentication interface generates a configuration authentication source based on the authentication protocol type and authentication source information, and inputs the configuration authentication source into the authentication protocol engine, which loads the authentication protocol logic corresponding to the authentication protocol type before generating the interface; wherein, the authentication protocol logic corresponding to the authentication protocol type is pre-set and stored.

[0037] In step S110 above, the authentication request is a request to initiate the protocol authentication process. The initiator of the authentication request can be a terminal device that needs to authenticate itself using an authentication protocol. The authentication request protocol is received through the authentication service or authentication system configured on the electronic device, and the authentication request is parsed to obtain the authentication protocol type in the authentication request. Specifically, for example, the authentication request is identified and matched according to the specific request headers or request parameters corresponding to the authentication protocol type to obtain the authentication protocol type in the authentication request.

[0038] Understandably, the format and content of authentication requests may differ depending on the authentication protocol and the associated authentication system used. Common authentication requests include authentication headers in HTTP requests, LDAP authentication requests, OAuth2 authentication requests, etc., each of which may have its own specific specifications and parameter requirements.

[0039] Authentication protocols can include, for example, LDAP (Lightweight Directory Access Protocol), RADIUS (Remote Authentication Dial-In User Service), OAuth 2.0 (Open Authorization Protocol), and CAS (Central Authentication Service). Taking OAuth 2.0 as an example, the OAuth2 protocol uses parameters in the authorization request and tokens in the response to achieve authentication and authorization. Protocol parameters used in the OAuth2 authentication request include the client ID (client_id), client secret (client_secret), access token (access_token), and refresh token (refresh_token).

[0040] In step S120 above, after receiving the authentication request, the authentication request is sent to the authentication interface corresponding to the authentication protocol type. The authentication interface is pre-generated, and each authentication protocol type corresponds to one authentication interface. The protocol authentication method within the authentication interface is executed. In response to the authentication request, the protocol processing engine is called to execute the authentication protocol logic and obtain the authentication result.

[0041] The authentication interface can be generated in ways such as: obtaining the authentication source information configured by the user based on the authentication protocol type. The authentication source information refers to the authentication source information of the authentication server that processes the authentication protocol of that type. The authentication source information may include the execution IP of the authentication server, the server port, the username, and password information, etc.

[0042] The authentication source information is encapsulated to generate a configuration authentication source. This configuration authentication source is then input into the authentication protocol engine, which loads the authentication protocol logic corresponding to the authentication protocol type and generates the authentication interface for that type. The authentication protocol logic corresponding to the authentication protocol type is internally encapsulated and stored in a storage device accessible to the service.

[0043] An authentication interface can be viewed as a form of authentication plugin. It provides a definition and convention that specifies how external programs or components interact with it. By implementing the interface, authentication functionality or services can be encapsulated as independent plugins, allowing for flexible integration into other systems or applications when needed. This enables the unified management of different types of authentication protocols within a single system.

[0044] The authentication interface also defines corresponding protocol authentication methods. Through this interface, different plugins can adhere to the same contract, thus achieving pluggability and extensibility. This makes the system more flexible, allowing plugins to be added, replaced, or combined as needed to implement different protocol authentication functions.

[0045] In the above implementation process, the acquired authentication source is input into the authentication protocol engine. After loading the authentication protocol logic, authentication interfaces corresponding to different authentication protocol types are generated. Upon receiving an authentication request, the authentication protocol is sent to the corresponding authentication interface according to the authentication protocol type in the request, thus enabling authentication using that protocol. By adopting a plugin engine approach, dynamic loading and unloading of different protocols is achieved, improving the scalability of authentication protocols and mitigating the inefficiency caused by re-developing code when adding new protocols, thereby improving work efficiency.

[0046] Optionally, in this embodiment of the application, before sending the authentication request to the pre-generated authentication interface according to the authentication protocol type, the method further includes: obtaining a pre-determined authentication protocol type; configuring authentication source information according to the authentication protocol type; encapsulating the authentication source information to generate a configured authentication source; inputting the configured authentication source into the authentication protocol engine, loading the authentication protocol logic through the authentication protocol engine, and generating the authentication interface.

[0047] In the specific implementation process: the pre-determined authentication protocol type is the authentication protocol that needs to generate the authentication interface. The authentication source information configured by the user according to the authentication protocol type is obtained. Taking LDAP authentication source as an example, the authentication source information may include the execution IP of the authentication server, the server port, the username, and password information. Taking OAuth2 protocol as an example, the authentication source information may also include an OAuth2 token.

[0048] Encapsulating authentication source information generates a configuration authentication source. Encapsulating authentication source information improves information security and portability, and facilitates authentication and access control.

[0049] The process of encapsulating authentication source information is described below through examples. Choosing a suitable encapsulation protocol: Different authentication and access control protocols typically use different encapsulation protocols to encapsulate authentication source information. For example, applications based on the OAuth2 protocol can use JSON Web Tokens (JWTs) to encapsulate authentication source information.

[0050] The authentication server can then verify and authorize the identity information in the authentication source information. After verification and authorization, it encapsulates the authentication source information into the defined encapsulation protocol. For example, if JWT is used to encapsulate the authentication source information, the authentication server can encode the information into JSON format and sign it using the JWT signature algorithm to generate the configuration authentication source.

[0051] The generated configuration authentication source is input into the authentication protocol engine, which loads the authentication protocol logic corresponding to the authentication protocol type and generates the authentication interface.

[0052] In the above implementation process, the authentication source is generated using the authentication protocol type and authentication source information. Then, the authentication protocol logic corresponding to the authentication protocol type is loaded through the authentication protocol engine to generate the authentication interface. This encapsulates different authentication functions or authentication services into independent interfaces or plugins, and integrates different types of authentication protocols into the same system for unified management, so that the interfaces can be flexibly called to perform authentication when needed.

[0053] Optionally, in this embodiment, configuring authentication source information according to the authentication protocol type includes: determining the protocol configuration parameters corresponding to the authentication protocol type from the template library according to the authentication protocol type; rendering the corresponding protocol configuration page based on the protocol configuration parameters; receiving the authentication source information configured by the user based on the protocol configuration page; the authentication source information includes the interface information corresponding to the authentication protocol type.

[0054] In the specific implementation process: the template library pre-stores the protocol configuration parameters corresponding to the authentication protocol type, and the protocol configuration parameters are the parameters to be configured for that authentication protocol type.

[0055] First, determine the overall structure and layout of the configuration page, including the location and organization of different configuration items. The page structure and style can be defined using HTML and CSS. Create corresponding form elements based on the protocol configuration parameters, such as checkboxes, radio buttons, text boxes, and dropdown lists.

[0056] Use server-side programming languages ​​(such as Python, Java, PHP, etc.) or front-end frameworks (such as React, Vue, etc.) to dynamically generate configuration pages. Based on the defined configuration parameters, generate page content programmatically on the server or client side. You can also use a template engine to more easily render pages, defining the names, default values, types, and other information of each configuration item in the protocol configuration parameters within the template.

[0057] The system displays a rendered protocol configuration page to the user, who then configures the authentication source information for the authentication protocol type. The system receives this configured authentication source information. This information may include interface information corresponding to the authentication protocol type, such as authorization and verification interfaces.

[0058] In the above implementation process, the corresponding protocol configuration page is rendered based on the protocol configuration parameters. Users can use the authentication source information configured on the protocol configuration page to reduce the workload of users and improve work efficiency.

[0059] Optionally, in this embodiment of the application, loading the authentication protocol logic through the authentication protocol engine to generate the authentication interface includes: using the authentication protocol engine to parse the protocol structure in the authentication protocol logic according to the protocol definition and / or protocol rules corresponding to the authentication protocol logic, and obtaining the structure parsing result; encapsulating the structure parsing result to generate the authentication interface.

[0060] In the specific implementation process: the role of the authentication protocol engine is protocol parsing and verification. The authentication protocol engine can parse authentication protocol messages, check their structure, format, and validity, and perform relevant verifications. For example, it can verify message signatures, message integrity, timestamps, etc., to ensure the authenticity and integrity of the message.

[0061] The authentication protocol engine understands the structure, format, and content of the authentication protocol logic based on the protocol definition and / or protocol rules, obtaining the structure parsing results. Specifically, it parses and extracts parts such as message headers, parameters, tags, and payloads.

[0062] The authentication protocol engine generates the authentication interface based on the structure parsing results of the above steps. This typically includes generating an authentication token, generating authorization information, and setting an expiration time. The authentication protocol engine then encapsulates these results into the return value of the authentication interface and provides it to the caller.

[0063] In the above implementation process, the authentication protocol logic is loaded through the authentication protocol engine to generate the authentication interface, which improves the efficiency caused by the need to redevelop the code when adding new protocols and improves work efficiency.

[0064] Optionally, in this embodiment of the application, the structure parsing result is encapsulated to generate an authentication interface, including: performing parameter verification on the structure parsing result to obtain parameter verification results; the parameter verification results include parameter validity verification results and parameter integrity verification results; if the parameter validity verification results and parameter integrity verification results indicate that the verification is passed, the structure parsing result is encapsulated to generate an authentication interface.

[0065] In the specific implementation process, the authentication protocol engine can also verify the validity and completeness of parameters in the authentication protocol logic. Specifically, this includes verifying the signature of the authentication protocol logic, checking the message version and format, and ensuring that the necessary parameters and information exist and are correct.

[0066] In the above implementation process, the authentication protocol engine verifies the legality and completeness of the authentication protocol logic parameters to avoid authentication failure due to incorrect or incomplete authentication protocol logic parameters, thereby improving the accuracy of authentication.

[0067] Optionally, in this embodiment of the application, after obtaining the structure parsing result, the method further includes: obtaining identity information and permission information from the authentication protocol logic; verifying the identity information through the authentication protocol engine to obtain the authentication result; verifying the permission information through the authentication protocol engine to obtain the permission verification result; and encapsulating the structure parsing result to generate an authentication interface, including: encapsulating the structure parsing result, the authentication result, and the permission verification result to generate an authentication interface.

[0068] In the specific implementation process: After parsing the authentication protocol logic, identity and permission information can be obtained from it. The authentication protocol engine will use relevant authentication mechanisms or services to verify the identity credentials in the message. For example, it can communicate with the authentication server, query the user database, or interact with other authentication systems to authenticate the identity information and obtain the authentication result.

[0069] The authentication protocol engine can also verify the permissions and authorization information in the message, such as checking user roles and permissions, and confirming resource access permissions. This allows the authentication protocol engine to verify permission information and obtain the permission verification result.

[0070] After obtaining the authentication and permission verification results, the structure parsing results, authentication results, and permission verification results are encapsulated to generate an authentication interface.

[0071] In an optional embodiment, if an error or anomaly is detected during the process of loading the authentication protocol logic and performing authentication and authorization verification, the authentication protocol engine will generate an appropriate error message or response so that appropriate actions can be taken after reviewing the error message.

[0072] In the above implementation process, authentication and permission verification are performed separately through the authentication protocol engine. The structure parsing results, authentication results, and permission verification results are encapsulated to generate an authentication interface, thereby improving the security of the authentication interface and thus improving the security of protocol authentication.

[0073] Optionally, in this embodiment, executing the protocol authentication method within the authentication interface to obtain the authentication result includes: sending an authentication request to the protocol interface engine through the authentication interface; the protocol interface engine is used to maintain and manage the authentication interface; maintenance and management include adding authentication interfaces, deleting authentication interfaces, and modifying the protocol authentication method within the authentication interface; forwarding the authentication request to the unified authentication manager using the protocol interface engine; the unified authentication manager is used to receive and process the authentication request; and the unified authentication manager calls the protocol processing engine according to the authentication protocol type to execute the authentication protocol logic and obtain the authentication result.

[0074] In the specific implementation process: the authentication protocol interface engine provides a unified interface for requesters to call, and receives authentication requests from requesters. The protocol interface engine is used for maintenance and management of the authentication interface; maintenance and management include adding authentication interfaces, deleting authentication interfaces, and modifying the protocol authentication methods within the authentication interfaces.

[0075] The authentication protocol interface engine forwards authentication requests to the Unified Authentication Manager (UAM) engine, which receives and processes authentication requests, i.e., handles authentication-related tasks.

[0076] The Unified Authentication Manager (UAM) receives authentication requests, and based on the authentication protocol type, invokes the protocol processing engine to execute the authentication protocol logic. Specifically, this includes tasks such as filtering and validation based on the request information to obtain the authentication result. The obtained authentication result can then be sent back to the authentication interface so that the requesting party can receive the authentication result. It is understood that the Unified Authentication Manager (UAM) engine can process authentication requests using preset protocol-defined processing methods.

[0077] In the above implementation process, different authentication functions or services are encapsulated into independent interfaces or plugins. When authentication is required, the authentication request is sent to the pre-generated authentication interface to execute the protocol authentication method within the authentication interface and obtain the authentication result. By integrating different types of authentication protocols into the same system for unified management, a single system can implement the protocol authentication methods of multiple authentication interfaces, improving the convenience of authentication.

[0078] In an alternative embodiment, considering that different protocols may have different security and reliability requirements, the security and reliability of the system can be enhanced during the design and implementation process. For example, the security of authentication information can be ensured by employing encryption and secure communication methods, while the reliability of the authentication system can be ensured by conducting thorough testing and verification.

[0079] Please see Figure 2 The diagram shows a component schematic of a unified authentication system supporting authentication sources for different protocols, as illustrated in an embodiment of this application.

[0080] Protocol Template Engine: The protocol template engine dynamically loads the specified authentication protocol configuration information from the template library according to the specified authentication protocol, renders it to the page, and generates the protocol configuration page.

[0081] Authentication source adaptation engine: The authentication source adaptation engine dynamically loads and generates authentication source configuration information based on the authentication protocol configuration, and injects it into the configuration authentication source of the authentication protocol processing engine.

[0082] Protocol Processing Engine: The protocol processing engine implements the authentication logic for specific protocols and can be dynamically loaded and unloaded. Internally, the engine includes modules for parsing, processing, and responding to the protocol. The protocol engine employs a plug-in architecture, allowing support for new, existing, or modified protocols by adding, modifying, or removing specific protocol plugins.

[0083] Unified Authentication Manager (UAM) Engine: Handles all tasks related to identity authentication, including identity authentication requests from different protocols passed by the interface engine, and loading the corresponding protocol templates and engine logic.

[0084] Protocol Interface Engine: The authentication protocol interface engine provides a unified interface for application systems to call. It receives authentication requests from application systems and sends the authentication information in the request to the Unified Authentication Manager (UAM) engine. The authentication interface can be provided to application systems via API.

[0085] Engine Manager: The Engine Manager is responsible for managing engines with different protocol functions. It can dynamically load and unload engines using DLLs or SOs. The Engine Manager receives and parses call requests from different functions, and selects the appropriate engine plugin for processing based on the protocol type in the request.

[0086] Please see Figure 3 The diagram shown is a schematic representation of the protocol authentication device provided in an embodiment of this application; this embodiment of the application provides a protocol authentication device 200, including:

[0087] The request receiving module 210 is used to receive authentication requests; the authentication request includes the authentication protocol type.

[0088] The protocol authentication module 220 is used to send the authentication request to the pre-generated authentication interface according to the authentication protocol type, so as to execute the protocol authentication method in the authentication interface and obtain the authentication result. The authentication interface generates a configuration authentication source based on the authentication protocol type and authentication source information, and inputs the configuration authentication source into the authentication protocol engine, and generates the authentication protocol after loading the authentication protocol logic corresponding to the authentication protocol type. The authentication protocol logic corresponding to the authentication protocol type is pre-set and stored.

[0089] Optionally, in this embodiment of the application, the protocol authentication device includes an authentication interface generation module, which is used to obtain a predetermined authentication protocol type; configure authentication source information according to the authentication protocol type; encapsulate the authentication source information to generate a configured authentication source; input the configured authentication source into the authentication protocol engine; load the authentication protocol logic through the authentication protocol engine; and generate an authentication interface.

[0090] Optionally, in this embodiment of the application, the protocol authentication device, the authentication interface generation module, includes a protocol configuration unit, used to determine the protocol configuration parameters corresponding to the authentication protocol type from the template library according to the authentication protocol type; render the corresponding protocol configuration page based on the protocol configuration parameters; and receive the authentication source information configured by the user based on the protocol configuration page; the authentication source information includes the interface information corresponding to the authentication protocol type.

[0091] Optionally, in this embodiment of the application, the protocol authentication device includes an authentication interface generation module, which is used to parse the protocol structure in the authentication protocol logic through the authentication protocol engine according to the protocol definition and / or protocol rules corresponding to the authentication protocol logic, and obtain the structure parsing result; and encapsulate the structure parsing result to generate an authentication interface.

[0092] Optionally, in this embodiment of the application, the protocol authentication device and the authentication interface generation module further include a parsing result verification unit, which is used to perform parameter verification on the structure parsing result to obtain parameter verification results; the parameter verification results include parameter validity verification results and parameter integrity verification results; if the parameter validity verification results and parameter integrity verification results indicate that the verification is passed, the structure parsing result is encapsulated to generate an authentication interface.

[0093] Optionally, in this embodiment of the application, the protocol authentication device and the authentication interface generation module further include an authentication unit, used to obtain identity information and permission information from the authentication protocol logic; to authenticate the identity information through the authentication protocol engine and obtain the authentication result; to verify the permission information through the authentication protocol engine and obtain the permission verification result; and to encapsulate the structure parsing result to generate an authentication interface, including: encapsulating the structure parsing result, the authentication result, and the permission verification result to generate the authentication interface.

[0094] Optionally, in this embodiment, the protocol authentication device, protocol authentication module 220, is further configured to send an authentication request to a protocol interface engine through an authentication interface; the protocol interface engine is configured to maintain and manage the authentication interface; maintenance and management include adding authentication interfaces, deleting authentication interfaces, and modifying the protocol authentication methods within the authentication interfaces; the protocol interface engine is used to forward the authentication request to a unified authentication manager; the unified authentication manager is configured to receive and process the authentication request; the unified authentication manager, according to the authentication protocol type, calls the protocol processing engine to execute the authentication protocol logic and obtain the authentication result.

[0095] It should be understood that this device corresponds to the above-described protocol authentication method embodiment and is capable of performing the various steps involved in the above method embodiment. The specific functions of this device can be found in the description above, and detailed descriptions are omitted here to avoid repetition. The device includes at least one software functional module that can be stored in memory or embedded in the device's operating system (OS) in the form of software or firmware.

[0096] Please see Figure 4 The diagram shows the structure of an electronic device provided in an embodiment of this application. An electronic device 300 provided in this application includes a processor 310 and a memory 320. The memory 320 stores machine-readable instructions executable by the processor 310. When the machine-readable instructions are executed by the processor 310, the method described above is performed.

[0097] This application also provides a storage medium storing a computer program, which is executed by a processor to perform the above-described method.

[0098] The storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as Static Random Access Memory (SRAM), Electrically Erasable Programmable Read-Only Memory (EEPROM), Erasable Programmable Read Only Memory (EPROM), Programmable Red-Only Memory (PROM), Read-Only Memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.

[0099] It should be understood that the disclosed apparatus and methods can also be implemented in other ways, given the several embodiments provided in this application. The apparatus embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of apparatus, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code, which contains one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks may occur in a different order than those marked in the drawings. For example, two consecutive blocks may actually be executed substantially in parallel, or they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in a block diagram and / or flowchart, and combinations of blocks in block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or action, or using a combination of dedicated hardware and computer instructions.

[0100] In addition, the functional modules in the various embodiments of this application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.

[0101] The above description is only an optional implementation of the embodiments of this application, but the protection scope of the embodiments of this application is not limited thereto. Any changes or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the embodiments of this application should be covered within the protection scope of the embodiments of this application.

Claims

1. A protocol authentication method characterized by, include: Receive authentication request; The authentication request includes the authentication protocol type; According to the authentication protocol type, the authentication request is sent to the pre-generated authentication interface to execute the protocol authentication method within the authentication interface and obtain the authentication result; The authentication interface generates a configuration authentication source based on the authentication protocol type and authentication source information, and inputs the configuration authentication source into the authentication protocol engine to load the authentication protocol logic corresponding to the authentication protocol type; wherein, the authentication protocol logic corresponding to the authentication protocol type is pre-set and stored; The step of executing the protocol authentication method within the authentication interface to obtain the authentication result includes: The authentication request is sent to the protocol interface engine through the authentication interface; the protocol interface engine is used to maintain and manage the authentication interface; the maintenance and management includes adding authentication interfaces, deleting authentication interfaces, and modifying the protocol authentication methods within the authentication interfaces; The authentication request is forwarded to the unified authentication manager using the protocol interface engine; the unified authentication manager receives and processes the authentication request. The unified authentication manager invokes the protocol processing engine based on the authentication protocol type to execute the authentication protocol logic and obtain the authentication result. The engine manager is responsible for managing engines with different protocol functions, and uses DLLs or SOs to dynamically load and unload engines. The engine manager receives and parses call requests from different functions, and selects the appropriate engine plugin for processing according to the protocol type in the request.

2. The method of claim 1, wherein, Before sending the authentication request to the pre-generated authentication interface according to the authentication protocol type, the method further includes: Obtain the predetermined authentication protocol type; Configure the authentication source information according to the authentication protocol type; The authentication source information is encapsulated to generate the configured authentication source; The configuration authentication source is input into the authentication protocol engine, and the authentication protocol logic is loaded by the authentication protocol engine to generate the authentication interface.

3. The method of claim 2, wherein, The step of configuring the authentication source information according to the authentication protocol type includes: Based on the authentication protocol type, determine the protocol configuration parameters corresponding to the authentication protocol type from the template library; Render the corresponding protocol configuration page based on the aforementioned protocol configuration parameters; Receive the authentication source information configured by the user based on the protocol configuration page; the authentication source information includes the interface information corresponding to the authentication protocol type.

4. The method of claim 2, wherein, The step of loading the authentication protocol logic through the authentication protocol engine to generate the authentication interface includes: The authentication protocol engine parses the protocol structure in the authentication protocol logic according to the protocol definition and / or protocol rules corresponding to the authentication protocol logic, and obtains the structure parsing result. The structure parsing result is encapsulated to generate the authentication interface.

5. The method according to claim 4, characterized in that, The step of encapsulating the structure parsing result to generate the authentication interface includes: The structural analysis results are then subjected to parameter verification to obtain parameter verification results; the parameter verification results include parameter validity verification results and parameter integrity verification results. If the parameter validity verification result and parameter integrity verification result pass the verification, the structure parsing result is encapsulated to generate the authentication interface.

6. The method according to claim 4, characterized in that, After obtaining the structural analysis results, the method further includes: Obtain identity and permission information from the authentication protocol logic; The identity information is authenticated using the authentication protocol engine to obtain the authentication result. The authentication protocol engine is used to verify the permission information and obtain the permission verification result. The step of encapsulating the structure parsing result to generate the authentication interface includes: The structure parsing result, the authentication result, and the permission verification result are encapsulated to generate the authentication interface.

7. A protocol authentication device, characterized in that, include: The request receiving module is used to receive authentication requests; The authentication request includes the authentication protocol type; The protocol authentication module is used to send the authentication request to a pre-generated authentication interface according to the authentication protocol type, so as to execute the protocol authentication method within the authentication interface and obtain the authentication result; The authentication interface generates a configuration authentication source based on the authentication protocol type and authentication source information, and inputs the configuration authentication source into the authentication protocol engine to load the authentication protocol logic corresponding to the authentication protocol type; wherein, the authentication protocol logic corresponding to the authentication protocol type is pre-set and stored; The protocol authentication module is further configured to send the authentication request to the protocol interface engine through the authentication interface; the protocol interface engine is configured to maintain and manage the authentication interface; the maintenance and management includes adding authentication interfaces, deleting authentication interfaces, and modifying the protocol authentication methods within the authentication interfaces; The authentication request is forwarded to the unified authentication manager using the protocol interface engine; the unified authentication manager receives and processes the authentication request. The unified authentication manager invokes the protocol processing engine based on the authentication protocol type to execute the authentication protocol logic and obtain the authentication result. The engine manager is responsible for managing engines with different protocol functions, and uses DLLs or SOs to dynamically load and unload engines. The engine manager receives and parses call requests from different functions, and selects the appropriate engine plugin for processing according to the protocol type in the request.

8. An electronic device, characterized in that, include: A processor and a memory, the memory storing machine-readable instructions executable by the processor, which, when executed by the processor, perform the method as described in any one of claims 1 to 6.

9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the method as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Access method supporting multiple IPTV services platform and IPTV terminal unit

    CN101247344A

  • System, apparatus, and method for providing generic internet protocol authentication

    US20040225878A1

  • Security module for auto-generating secure channels

    US20210136116A1