Video playback method, device, equipment and medium
By carrying authentication parameters in the video playback request and performing server-side authentication, the problem of requiring user authorization in mobile client video applications is solved, and the video is safe and smooth playback is achieved.
Patent Information
- Application Number
- CN202110713390.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-06-25
- Publication Date
- 2025-04-29
- Estimated Expiration
- 2041-06-25
AI Technical Summary
Video applications in mobile clients, especially short video applications, often require user authorization to play normally, which affects the smoothness of users' viewing videos.
By carrying the authentication parameters in the video playback request, the server and the account center perform authentication, and after successful authentication success information is generated, the client obtains the playback address and plays the video based on this information. The entire process is transparent to the user.
It realizes safe playback and smooth viewing of videos, avoids the problem of interrupting user experience during authentication, and improves user viewing efficiency.
Smart Images

Figure CN115529493B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present disclosure relate to video processing technology, and more particularly to a video playback method, apparatus, device, and medium. Background Art
[0002] Video applications in mobile clients, especially short video applications, often require user authorization for normal playback. In this case, the user's video viewing will be interrupted, and the user is required to enter a verification code, scan a code, or enter information in a pop-up window. If multiple videos require user authorization, each video must be authorized separately, which is inefficient. Summary of the invention
[0003] The embodiments of the present disclosure provide a video playback method, apparatus, device and medium, which ensure the smoothness of video viewing for users on the basis of safe video playback.
[0004] In a first aspect, an embodiment of the present disclosure provides a method for playing a video, the method comprising:
[0005] Sending a first play request according to first video information of the current video to be played, so that the server receives the first play request, wherein the first video information includes an authentication identifier, and the first play request carries a first authentication parameter;
[0006] The currently played video is played according to the first playback address, where the first playback address is generated by first authentication success information, and the first authentication success information is obtained by the server through successful authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
[0007] In a second aspect, an embodiment of the present disclosure provides a method for playing a video, the method comprising:
[0008] Obtaining a first playback request of a client, where the first playback request is generated by the client according to first video information of a currently played video, where the first video information includes an authentication identifier, and the first playback request carries a first authentication parameter;
[0009] If authentication is successful based on the first authentication parameter in the first play request and the second authentication parameter of the account center, first authentication success information is generated, so that the client plays the current video to be played according to the first play address generated by the first authentication success information.
[0010] In a third aspect, an embodiment of the present disclosure provides a video playback device, the device comprising:
[0011] A request module, configured to send a first play request according to first video information of a currently to-be-played video, so that the server receives the first play request, wherein the first video information includes an authentication identifier, and the first play request carries a first authentication parameter;
[0012] The playback module plays the current video to be played according to the first playback address, the first playback address is generated by the first authentication success information, and the first authentication success information is obtained by the server through successful authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
[0013] In a fourth aspect, an embodiment of the present disclosure provides a video playback device, the device comprising:
[0014] An acquisition module, configured to acquire a first playback request of a client, wherein the first playback request is generated by the client according to first video information of a currently played video, wherein the first video information includes an authentication identifier, and the first playback request carries a first authentication parameter;
[0015] The authentication module is used to generate first authentication success information if the authentication is successful based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, so that the client plays the current video to be played based on the first playback address generated by the first authentication success information.
[0016] In a fifth aspect, an embodiment of the present disclosure provides an electronic device, including:
[0017] one or more processors;
[0018] a memory for storing one or more programs,
[0019] When the one or more programs are executed by the one or more processors, the one or more processors implement the video playback method as described in the embodiment of the present disclosure.
[0020] In a sixth aspect, an embodiment of the present disclosure provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the video playback method as described in the embodiment of the present disclosure.
[0021] In the disclosed embodiment, for videos that require authentication, the client carries a first authentication parameter in the first playback request sent to the server. The first authentication parameter is generated by the account center when the user logs in. The server performs authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, thereby ensuring safe playback of the video and avoiding hotlinking. After the server successfully authenticates, the client plays the current video to be played based on the first playback address. The first playback address is generated by the first authentication success information generated by the server after successful authentication. The entire authentication process is transparent and invisible to the user, so as not to interrupt the user's video viewing and ensure the smoothness of the user's video viewing. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] The above and other features, advantages and aspects of the embodiments of the present disclosure will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. Throughout the accompanying drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic and the originals and elements are not necessarily drawn to scale.
[0023] Figure 1 A flowchart of a video playback method provided in Embodiment 1 of the present disclosure;
[0024] Figure 2 A flowchart of a video playback method provided in Embodiment 2 of the present disclosure;
[0025] Figure 3 A structural diagram of a video playback device provided in Embodiment 3 of the present disclosure;
[0026] Figure 4 A structural diagram of a video playback device provided in Embodiment 4 of the present disclosure
[0027] Figure 5 This is a structural diagram of an electronic device provided in Embodiment 5 of the present disclosure. DETAILED DESCRIPTION
[0028] Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments described herein, which are instead provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes and are not intended to limit the scope of protection of the present disclosure.
[0029] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0030] The term "including" and its variations used herein are open inclusions, i.e., "including but not limited to". The term "based on" means "based at least in part on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". The relevant definitions of other terms will be given in the following description.
[0031] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0032] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".
[0033] The names of the messages or information exchanged between multiple devices in the embodiments of the present disclosure are only used for illustrative purposes and are not used to limit the scope of these messages or information.
[0034] Embodiment 1
[0035] Figure 1 This is a flowchart of a video playback method provided in the first embodiment of the present disclosure. The method can be executed by a video playback application, and the video playback application can be set in a mobile terminal, such as a mobile phone, a tablet computer, etc. This embodiment includes steps S110 and S120. Figure 1 As shown, the method specifically comprises the following steps:
[0036] S110. Send a first play request according to first video information of the current video to be played, so that the server receives the first play request, wherein the first video information includes an authentication identifier, and the first play request carries a first authentication parameter.
[0037] The server pre-sends video information of the video, which includes long videos and short videos. The video length of the short video is about ten seconds, and the video length of the long video is greater than that of the short video. For example, the video length of the long video is 1 minute, or the video length of the long video is 3 minutes, and so on.
[0038] If the video information includes an authentication identifier, the corresponding video needs authentication, which means that the corresponding video needs user authorization before it can be played normally; if the video information does not include an authentication identifier, the corresponding video does not need authentication, which means that the corresponding video can be played normally without user authorization.
[0039] For videos that require authentication, the client carries a first authentication parameter in the first play request. Optionally, before sending the first play request to the server according to the first video information of the current video to be played, it also includes: obtaining the account information of the user when logging in; sending the account information to the account center; receiving the first authentication parameter saved by the account center, the first authentication parameter is obtained by the account center through a hash algorithm based on the account information when the user registers.
[0040] When a client newly installs a video playback application or updates the account information of an already installed video playback application, when a user logs in to the video playback application of the client, the client sends the account information of the user when logging in to the account center, and the account center sends the hash value obtained by hashing the account information when the user registers as the first authentication parameter to the client. For example, the account center obtains the first authentication parameter by hashing the user ID, the current timestamp, and the random number when the user registers.
[0041] Optionally, the client stores the first authentication parameter in a local storage space of the operating system. Since the first authentication parameter is stored in the local storage space of the operating system, the security of the first authentication parameter is at the same level as the security of the operating system.
[0042] When the user logs in to the video playback application of the client again, the client obtains the first authentication parameter from the local storage space of the operating system according to the account information of the user when logging in. The first authentication parameter is a preset hash value, and the preset hash value is obtained by the account center through a hash algorithm operation according to the account information when the user registers. For example, the account center obtains the preset hash value through a hash algorithm operation according to the user ID, current timestamp and random number when the user registers.
[0043] Optionally, the second authentication parameter of the account center is obtained by matching the first authentication parameter stored in the account center according to the authorization scope information of the current video to be played. That is, the first authentication parameter corresponding to the authorized user in the account center is the second authentication parameter.
[0044] User ID
[0045] S120. Play the current video to be played according to the first playback address, where the first playback address is generated by first authentication success information, and the first authentication success information is obtained by the server through successful authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
[0046] The server requests the second authentication parameter from the account center, and compares the first authentication parameter in the first play request with the second authentication parameter of the account center. If the first authentication parameter is within the second authentication parameter, the authentication is successful, and a first authentication success message is generated. If the authentication is successful, the client plays the current video to be played according to the first play address, and the first play address is generated by the first authentication success message.
[0047] Furthermore, the disclosed embodiment may also include: displaying a first prompt indicating that the current video to be played has failed to be played, wherein the first prompt is generated by first authentication failure information, and the first authentication failure information is obtained by the server based on the first authentication parameter in the first playback request and the second authentication parameter of the account center after authentication failure.
[0048] If the first authentication parameter is not in the second authentication parameter, the authentication fails, and the server generates a first authentication failure message. If the authentication fails, the client displays a first prompt that the current video to be played failed, and the first prompt is generated by the first authentication failure message, and enters the next video to be played. The specific content of the first prompt can be preset, such as "the current video to be played failed to play" or "the current video to be played failed to authenticate" or "the current video to be played is not authorized", etc.
[0049] Furthermore, the disclosed embodiment may also include: sending a second playback request based on the second video information of the current video to be played, so that the server receives the second playback request, the second video information does not include an authentication identifier, and the second playback request does not carry a first authentication parameter; playing the current video to be played according to a second playback address, the second playback address is generated based on the first unauthenticated information, and the first unauthenticated information is obtained by the server based on the second video information sent down that does not include an authentication identifier.
[0050] If the second video information does not include the authentication identifier, the current video to be played does not need authentication, which means that the current video to be played can be played normally without user authorization. For the current video to be played that does not require authentication, the client does not carry the first authentication parameter in the second play request. The server determines that the current video to be played does not require user authorization based on the fact that the second video information sent does not include the authentication identifier. Therefore, after receiving the second play request, the server generates the first unauthenticated information, and the client plays the current video to be played according to the second play address, which is generated based on the first unauthenticated information.
[0051] Further, the disclosed embodiment may also include: sending a third play request in parallel according to third video information of two or more preloaded videos, so that the server receives the third play request in parallel, the third video information includes an authentication identifier, then the corresponding third play request carries the first authentication parameter, and the third video information does not include the authentication identifier, then the corresponding third play request does not carry the first authentication parameter;
[0052] Preloading a corresponding video in a video playlist according to a third playback address, wherein the third playback address is generated by third authentication success information or second unauthenticated information, wherein the third authentication success information is obtained by the server through successful authentication according to the first authentication parameter in the third playback request and the second authentication parameter of the account center, and the second unauthenticated information is obtained by the server according to the third video information not including an authentication identifier;
[0053] Alternatively, a second prompt indicating that the corresponding video preloading failure has occurred is displayed in the video playlist, wherein the second prompt is generated by second authentication failure information, and the second authentication failure information is obtained by the server based on the first authentication parameter in the third playback request and the second authentication parameter of the account center after authentication failure.
[0054] For the video playback application of the client, its video playback list can be used for video preloading. The disclosed embodiment can also perform user-imperceptible (transparent) authentication for the preloaded videos. For the third video information of two or more preloaded videos, a third playback request is sent in parallel, and the server receives the third playback request in parallel. If the third video information of the preloaded video includes an authentication identifier, the preloaded video requires user authorization to play normally, and the corresponding third playback request carries the first authentication parameter. If the third video information of the preloaded video does not include an authentication identifier, the preloaded video can be played normally without user authorization, and the corresponding third playback request does not carry the first authentication parameter.
[0055] Correspondingly, when the third video information includes an authentication identifier, the server compares the first authentication parameter in the third playback request with the second authentication parameter of the account center. If the first authentication parameter is consistent with the second authentication parameter, the authentication is successful and the third authentication success information is generated; if the first authentication parameter is inconsistent with the second authentication parameter, the authentication fails and the second authentication failure information is generated. If the authentication is successful, the third playback address is generated by the third authentication success information; if the authentication fails, the second authentication failure information generates a second prompt, which is used to indicate that the video preloading failed. The specific content of the second prompt can be preset, such as "video playback failed" or "video authentication failed" or "video unauthorized", etc. If the third video information does not include an authentication identifier, the server generates the second unauthenticated information, and the third playback address is generated by the second unauthenticated information.
[0056] Furthermore, the disclosed embodiment may also include: opening the first playback address through a browser or a video playback program that is not associated with an account; prompting a playback failure on the browser interface or the interface that is not associated with an account. Alternatively, opening the second playback address through a browser or an interface of a video playback program that is not associated with an account; playing the currently played video on the browser interface or the interface of the video playback program that is not associated with an account.
[0057] The disclosed embodiment provides a verification method for the playback address. In the case where the first video information of the current video to be played includes an authentication identifier, the first playback address can only be played through a video playback application that has successfully been authenticated, and cannot be played through other applications of the user terminal, for example, it cannot be played through a video playback program that the browser user is not logged in to. If the first playback address is opened through a browser or a video playback program that is not associated with an account, a playback failure prompt will be displayed on the browser interface or the video playback program interface that is not associated with an account. In the case where the first video information of the current video to be played does not include an authentication identifier, the second playback address can be played through a video playback application that has successfully been authenticated, or through other applications of the client, for example, through a browser or a video playback program that is not associated with an account. If the second playback address is opened through a browser or a video playback program that is not associated with an account, the current video to be played can be played on the browser interface or the video playback program interface that is not associated with an account.
[0058] In the disclosed embodiment, for videos that require authentication, the client carries a first authentication parameter in the first playback request sent to the server. The first authentication parameter is generated by the account center when the user logs in. The server performs authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, thereby ensuring safe playback of the video and avoiding hotlinking. After the server successfully authenticates, the client plays the current video to be played based on the first playback address. The first playback address is generated by the first authentication success information generated by the server after successful authentication. The entire authentication process is transparent and invisible (imperceptible) to the user, so as not to interrupt the user's video viewing and ensure the smoothness of the user's video viewing.
[0059] Embodiment 2
[0060] Figure 2 This is a flowchart of a video playback method provided in the second embodiment of the present disclosure. The method can be executed by a video management application, and the video management application can be set in a server. This embodiment includes steps S210 and S220. Figure 2 As shown, the method specifically comprises the following steps:
[0061] S210. Obtain a first playback request from the client, where the first playback request is generated by the client according to first video information of a currently played video, where the first video information includes an authentication identifier, and the first playback request carries a first authentication parameter.
[0062] The server sends the first video information of the current video to be played to the client in advance.
[0063] S220. If authentication is successful according to the first authentication parameter in the first play request and the second authentication parameter of the account center, first authentication success information is generated, so that the client plays the current video to be played according to the first play address generated by the first authentication success information.
[0064] When a user logs in to the video playback application of the client, the client sends the account information of the user when logging in to the account center. The account center obtains a hash value based on the account information through a hash algorithm when the user registers. The account center saves the obtained hash value. When the user logs in, the account center sends the saved hash value as the first authentication parameter to the client.
[0065] When the first video information includes an authentication identifier, the server receives the first playback request and requests the second authentication parameter from the account center. The server compares the first authentication parameter in the first playback request with the second authentication parameter in the account center. If the first authentication parameter is in the second authentication parameter, the authentication is successful and the first authentication success information is generated. If the authentication is successful, the client plays the current video to be played according to the first playback address, and the first playback address is generated by the first authentication success information. The second authentication parameter of the account center is obtained by matching the first authentication parameter stored in the account center according to the authorization scope information of the current video to be played.
[0066] Furthermore, the disclosed embodiment may also include: if authentication fails between the first authentication parameter in the first playback request and the second authentication parameter of the account center, a first authentication failure message is generated, so that the client displays a first prompt indicating that the playback of the current video to be played has failed, and the first prompt is generated by the first authentication failure message.
[0067] When the first video information includes an authentication identifier, the server receives the first playback request and requests the second authentication parameter from the account center. The server compares the first authentication parameter in the first playback request with the second authentication parameter of the account center. If the first authentication parameter is not in the second authentication parameter, the authentication fails and a first authentication failure message is generated. If the authentication fails, the client displays a first prompt indicating that the current video to be played has failed, and the first prompt is generated by the first authentication failure message, and proceeds to the next video.
[0068] Furthermore, the disclosed embodiment may also include: obtaining a second playback request from the client, the second playback request is generated by the client based on second video information of the current video to be played, the second video information does not include an authentication identifier, and the second playback request does not carry a first authentication parameter; based on the fact that the second video information sent does not include an authentication identifier, generating first unauthenticated information, so that the client plays the current video to be played according to a second playback address, the second playback address being generated by the first unauthenticated information.
[0069] The server sends the second video information of the current video to be played to the client in advance. The server determines that the current video to be played does not require user authorization because the sent second video information does not include the authentication identifier. Therefore, after receiving the second play request, the server sends the first unauthenticated information to the client, and the client plays the current video to be played according to the second play address, which is generated by the first unauthenticated information.
[0070] Further, the disclosed embodiment may also include: obtaining a third playback request sent in parallel by the client, wherein the third playback request is generated by the client according to third video information of two or more preloaded videos, wherein the third video information includes an authentication identifier, then the corresponding third playback request carries a first authentication parameter, and the third video information does not include an authentication identifier, then the corresponding third playback request does not carry the first authentication parameter;
[0071] The third authentication success information is generated according to the first authentication parameter in the third playback request and the second authentication parameter of the account center through successful authentication, or the second unauthenticated information is generated according to the third video information not including the authentication identifier, so that the client preloads the corresponding video in the video play list according to the third playback address, and the third playback address is generated by the third authentication success information or the second unauthenticated information;
[0072] Alternatively, a second authentication failure message is generated based on the authentication failure between the first authentication parameter in the third playback request and the second authentication parameter of the account center, so that the client displays a second prompt of the corresponding video preloading failure in the video playback list, and the second prompt is generated by the second authentication failure message.
[0073] For the video playback application of the client, its video playback list can preload videos, and the server pre-sends the third video information of the preloaded video. The server receives the third playback request sent by the client in parallel. If the third video information of the preloaded video includes an authentication identifier, the preloaded video requires user authorization to play normally, and the corresponding third playback request carries the first authentication parameter; if the third video information of the preloaded video does not include the authentication identifier, the preloaded video can be played normally without user authorization, and the corresponding third playback request does not carry the first authentication parameter.
[0074] Correspondingly, when the third video information includes an authentication identifier, the server compares the first authentication parameter in the third playback request with the second authentication parameter of the account center. If the first authentication parameter is in the second authentication parameter, the authentication is successful and the third authentication success information is generated; if the first authentication parameter is not in the second authentication parameter, the authentication fails and the second authentication failure information is generated. The second prompt is generated by the second authentication failure information, and the specific content of the second prompt can be preset, such as "video playback failed" or "video authentication failed" or "video unauthorized", etc. When the third video information does not include an authentication identifier, the server generates the second unauthenticated information.
[0075] In the disclosed embodiment, for videos that require authentication, the client carries a first authentication parameter in the first playback request sent to the server. The first authentication parameter is generated by the account center when the user logs in. The server performs authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, thereby ensuring safe playback of the video and avoiding hotlinking. After the server successfully authenticates, it generates a first authentication success message, and the client plays the current video to be played based on the first playback address. The first playback address is generated by the first authentication success message. The entire authentication process is transparent and invisible (imperceptible) to the user, so as not to interrupt the user's video viewing and ensure the smoothness of the user's video viewing.
[0076] Embodiment 3
[0077] Figure 3 This is a structural diagram of a video playback device provided in Embodiment 3 of the present disclosure. The device can execute the video playback method in Embodiment 1 above and can be configured in a client, such as Figure 3 As shown, the device may include a request module 310 and a play module 320.
[0078] The request module 310 is used to send a first play request according to the first video information of the current video to be played, so that the server receives the first play request, wherein the first video information includes an authentication identifier, and the first play request carries a first authentication parameter.
[0079] The playback module 320 is used to play the current video to be played according to the first playback address, where the first playback address is generated by the first authentication success information, which is obtained by the server through successful authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
[0080] In the disclosed embodiment, for videos that require authentication, the client carries a first authentication parameter in the first playback request sent to the server. The first authentication parameter is generated by the account center when the user logs in. The server performs authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, thereby ensuring safe playback of the video and avoiding hotlinking. After the server successfully authenticates, it generates a first authentication success message, and the client plays the current video to be played based on the first playback address. The first playback address is generated by the first authentication success message. The entire authentication process is transparent and invisible (imperceptible) to the user, so as not to interrupt the user's video viewing and ensure the smoothness of the user's video viewing.
[0081] On the basis of the above embodiment, the request module is also used to send a second playback request according to the second video information of the current video to be played, so that the server receives the second playback request, wherein the second video information does not include an authentication identifier, and the second playback request does not carry a first authentication parameter; the playback module is also used to play the current video to be played according to a second playback address, the second playback address is generated by the first unauthenticated information, and the first unauthenticated information is obtained by the server according to the second video information sent down that does not include an authentication identifier.
[0082] Based on the above embodiment, it also includes a first acquisition unit, which is used to obtain account information when the user logs in; send the account information to the account center; receive a first authentication parameter saved by the account center, and the first authentication parameter is obtained by the account center through a hash algorithm based on the account information when the user registers.
[0083] Based on the above embodiment, the first acquisition unit is further used to store the first authentication parameter into a local storage space of the operating system.
[0084] Based on the above embodiment, it also includes a second acquisition unit, which is used to obtain a first authentication parameter from the local storage space of the operating system according to the account information when the user logs in, and the first authentication parameter is a preset hash value, which is obtained by the account center through a hash algorithm based on the account information when the user registers.
[0085] On the basis of the above embodiment, the request module is further used to send a third playback request in parallel according to the third video information of two or more preloaded videos, so that the server receives the third playback request in parallel, the third video information includes an authentication identifier, then the corresponding third playback request carries the first authentication parameter, the third video information does not include the authentication identifier, then the corresponding third playback request does not carry the first authentication parameter; preload the corresponding video in the video play list according to the third playback address, the third playback address is generated by the third authentication success information or the second unauthenticated information, the third authentication success information is obtained by the server according to the first authentication parameter in the third playback request and the second authentication parameter of the account center through successful authentication, the second unauthenticated information is obtained by the server according to the third video information does not include the authentication identifier; or, display a second prompt of the corresponding video preloading failure in the video play list, the second prompt is generated by the second authentication failure information, the second authentication failure information is obtained by the server according to the first authentication parameter in the third playback request and the second authentication parameter of the account center through failed authentication.
[0086] Based on the above embodiment, it also includes a video playback program that is not associated with a browser or an account, which is used to open the first playback address and prompt that the playback fails; or, it is used to open the second playback address and play the current video to be played.
[0087] The video playback device provided in the embodiment of the present disclosure and the video playback method provided in the above-mentioned embodiment 1 belong to the same inventive concept. The technical details not fully described in this embodiment can be referred to the above-mentioned embodiment, and this embodiment has the same beneficial effects as executing the video playback method.
[0088] Embodiment 4
[0089] Figure 4 This is a structural diagram of a video playback device provided in Embodiment 4 of the present disclosure. The device can execute the video playback method in Embodiment 2 above and can be configured in a server, such as Figure 4 As shown, the device may include an acquisition module 410 and an authentication module 420.
[0090] The acquisition module 410 is used to acquire a first playback request from the client, where the first playback request is generated by the client according to first video information of the current video to be played, where the first video information includes an authentication identifier, and the first playback request carries a first authentication parameter.
[0091] The authentication module 420 is used to generate first authentication success information if the authentication is successful based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, so that the client plays the current video to be played based on the first playback address generated by the first authentication success information.
[0092] In the disclosed embodiment, for videos that require authentication, the client carries a first authentication parameter in the first playback request sent to the server. The first authentication parameter is generated by the account center when the user logs in. The server performs authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, thereby ensuring safe playback of the video and avoiding hotlinking. After the server successfully authenticates, it generates a first authentication success message, and the client plays the current video to be played based on the first playback address. The first playback address is generated by the first authentication success message. The entire authentication process is transparent and invisible (imperceptible) to the user, so as not to interrupt the user's video viewing and ensure the smoothness of the user's video viewing.
[0093] Based on the above embodiment, the authentication module is also used to generate first authentication failure information if authentication fails between the first authentication parameter in the first playback request and the second authentication parameter of the account center, so that the client displays a first prompt of the failure to play the current video to be played, and the first prompt is generated by the first authentication failure information.
[0094] On the basis of the above embodiment, the acquisition module is further used to obtain a second playback request from the client, where the second playback request is generated by the client based on second video information of the current video to be played, the second video information does not include an authentication identifier, and the second playback request does not carry a first authentication parameter; the authentication module is further used to generate first unauthenticated information based on the fact that the second video information sent does not include an authentication identifier, so that the client plays the current video to be played based on a second playback address, where the second playback address is generated by the first unauthenticated information.
[0095] On the basis of the above embodiment, the acquisition module is further used to acquire the third playback request sent in parallel by the client, the third playback request is generated by the client according to the third video information of two or more preloaded videos, wherein the third video information includes an authentication identifier, then the corresponding third playback request carries the first authentication parameter, and the third video information does not include the authentication identifier, then the corresponding third playback request does not carry the first authentication parameter; the authentication module is also used to generate third authentication success information according to the first authentication parameter in the third playback request and the second authentication parameter of the account center if the authentication is successful, or to generate second unauthenticated information according to the third video information not including the authentication identifier, so that the client preloads the corresponding video in the video play list according to the third playback address, and the third playback address is generated by the third authentication success information or the second unauthenticated information; or, generate second authentication failure information according to the first authentication parameter in the third playback request and the second authentication parameter of the account center if the authentication fails, so that the client displays a second prompt of the corresponding video preloading failure in the video play list, and the second prompt is generated by the second authentication failure information.
[0096] The video playback device provided in the embodiment of the present disclosure and the video playback method provided in the above-mentioned embodiment 2 belong to the same inventive concept. The technical details not fully described in this embodiment can be referred to the above-mentioned embodiment, and this embodiment has the same beneficial effects as executing the video playback method.
[0097] Embodiment 5
[0098] Reference below Figure 5 , which shows a structural diagram of an electronic device 900 suitable for implementing the embodiment of the present disclosure. The electronic device in the embodiment of the present disclosure has a video playback function, and may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablet computers), PMPs (portable multimedia players), vehicle terminals (such as vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 5The electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0099] like Figure 5 As shown, the electronic device 900 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 901, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 902 or a program loaded from a storage device 908 into a random access memory (RAM) 903. In the RAM 903, various programs and data required for the operation of the electronic device 900 are also stored. The processing device 901, the ROM 902, and the RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.
[0100] Typically, the following devices may be connected to the I / O interface 905: an input device 906 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 907 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 908 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 909. The communication device 909 may allow the electronic device 900 to communicate with other devices wirelessly or by wire to exchange data. Although Figure 5 The electronic device 900 is shown with various devices, but it should be understood that it is not required to implement or possess all the devices shown. More or fewer devices may be implemented or possessed instead.
[0101] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a non-transitory computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device 909, or installed from a storage device 908, or installed from a ROM 902. When the computer program is executed by the processing device 901, the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.
[0102] Embodiment 6
[0103] The computer-readable medium disclosed above may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in combination with an instruction execution system, device or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, in which a computer-readable program code is carried. This propagated data signal may take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. The computer readable signal medium may also be any computer readable medium other than a computer readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer readable medium may be transmitted using any suitable medium, including but not limited to: wires, optical cables, RF (radio frequency), etc., or any suitable combination of the above.
[0104] In some embodiments, the client and the server may communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and may be interconnected with any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), an internet (e.g., the Internet), and a peer-to-peer network (e.g., an ad hoc peer-to-peer network), as well as any currently known or future developed network.
[0105] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0106] The above-mentioned computer-readable medium carries one or more programs. When the above-mentioned one or more programs are executed by the electronic device, the electronic device: sends a first playback request according to the first video information of the current video to be played, so that the server receives the first playback request, wherein the first video information includes an authentication identifier, and the first playback request carries a first authentication parameter; plays the current video to be played according to a first playback address, the first playback address is generated by first authentication success information, and the first authentication success information is obtained by the server through successful authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
[0107] Alternatively, the computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device: obtains a first playback request from the client, the first playback request is generated by the client based on first video information of a currently played video, the first video information includes an authentication identifier, the first playback request carries a first authentication parameter, and the first authentication parameter is generated by an account center when a user logs in; if authentication is successful based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, a first authentication success message is generated, so that the client plays the currently played video based on the first playback address generated by the first authentication success message.
[0108] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages or a combination thereof, including, but not limited to, object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., through the Internet using an Internet service provider).
[0109] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some implementations as replacements, the functions marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two square boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0110] The modules involved in the embodiments described in the present disclosure may be implemented by software or hardware. The name of the module does not limit the module itself in some cases. For example, the request module may also be described as "a module for sending a first play request according to the first video information of the current video to be played".
[0111] The functions described above herein may be performed at least in part by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips (SOCs), complex programmable logic devices (CPLDs), and the like.
[0112] In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, device, or equipment. A machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium may include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0113] According to one or more embodiments of the present disclosure, the present disclosure provides a method for playing a video, the method comprising:
[0114] Sending a first play request according to first video information of the current video to be played, so that the server receives the first play request, wherein the first video information includes an authentication identifier, and the first play request carries a first authentication parameter;
[0115] The currently played video is played according to the first playback address, where the first playback address is generated by first authentication success information, and the first authentication success information is obtained by the server through successful authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
[0116] According to one or more embodiments of the present disclosure, in the video playback method provided by the present disclosure, the second authentication parameter of the account center is obtained by matching the first authentication parameter stored in the account center according to the authorization scope information of the current video to be played.
[0117] According to one or more embodiments of the present disclosure, the video playback method provided by the present disclosure further includes:
[0118] A first prompt is displayed indicating that the current video to be played has failed to be played, wherein the first prompt is generated by first authentication failure information, wherein the first authentication failure information is obtained by the server through authentication failure based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
[0119] According to one or more embodiments of the present disclosure, in the video playback method provided by the present disclosure, before sending a first playback request according to the first video information of the current video to be played, it also includes:
[0120] Get the user's account information when logging in;
[0121] Sending the account information to an account center;
[0122] A first authentication parameter saved by the account center is received, where the first authentication parameter is obtained by the account center through a hash algorithm operation based on account information when the user registers.
[0123] According to one or more embodiments of the present disclosure, the video playback method provided by the present disclosure further includes:
[0124] The first authentication parameter is stored in the local storage space of the operating system.
[0125] According to one or more embodiments of the present disclosure, in the video playback method provided by the present disclosure, before sending a first playback request according to the first video information of the current video to be played, it also includes:
[0126] A first authentication parameter is obtained from the local storage space of the operating system according to the account information when the user logs in. The first authentication parameter is a preset hash value, and the preset hash value is obtained by the account center through a hash algorithm operation according to the account information when the user registers.
[0127] According to one or more embodiments of the present disclosure, the video playback method provided by the present disclosure further includes:
[0128] According to the third video information of the two or more preloaded videos, a third play request is sent in parallel, so that the server receives the third play request in parallel, the third video information includes an authentication identifier, then the corresponding third play request carries the first authentication parameter, and the third video information does not include the authentication identifier, then the corresponding third play request does not carry the first authentication parameter;
[0129] Preloading a corresponding video in a video playlist according to a third playback address, wherein the third playback address is generated by third authentication success information or second unauthenticated information, wherein the third authentication success information is obtained by the server through successful authentication according to the first authentication parameter in the third playback request and the second authentication parameter of the account center, and the second unauthenticated information is obtained by the server according to the third video information not including an authentication identifier;
[0130] Alternatively, a second prompt indicating that the corresponding video preloading failure has occurred is displayed in the video playlist, wherein the second prompt is generated by second authentication failure information, and the second authentication failure information is obtained by the server based on the first authentication parameter in the third playback request and the second authentication parameter of the account center after authentication failure.
[0131] According to one or more embodiments of the present disclosure, the video playback method provided by the present disclosure further includes:
[0132] Open the first playback address through a browser or a video playback program that is not associated with the account;
[0133] The playback fails in the browser interface or the interface of the video player program that is not associated with the account.
[0134] According to one or more embodiments of the present disclosure, the present disclosure provides a method for playing a video, the method comprising:
[0135] Obtaining a first playback request of a client, where the first playback request is generated by the client according to first video information of a currently played video, where the first video information includes an authentication identifier, and the first playback request carries a first authentication parameter;
[0136] If authentication is successful based on the first authentication parameter in the first play request and the second authentication parameter of the account center, first authentication success information is generated, so that the client plays the current video to be played according to the first play address generated by the first authentication success information.
[0137] According to one or more embodiments of the present disclosure, the video playback method provided by the present disclosure further includes:
[0138] If authentication fails between the first authentication parameter in the first playback request and the second authentication parameter of the account center, first authentication failure information is generated, so that the client displays a first prompt that the playback of the current video to be played fails, and the first prompt is generated by the first authentication failure information.
[0139] According to one or more embodiments of the present disclosure, the video playback method provided by the present disclosure further includes:
[0140] Obtaining a third playback request sent in parallel by the client, wherein the third playback request is generated by the client according to third video information of two or more preloaded videos, wherein if the third video information includes an authentication identifier, then the corresponding third playback request carries a first authentication parameter, and if the third video information does not include an authentication identifier, then the corresponding third playback request does not carry the first authentication parameter;
[0141] The third authentication success information is generated according to the first authentication parameter in the third playback request and the second authentication parameter of the account center through successful authentication, or the second unauthenticated information is generated according to the third video information not including the authentication identifier, so that the client preloads the corresponding video in the video play list according to the third playback address, and the third playback address is generated by the third authentication success information or the second unauthenticated information;
[0142] Alternatively, a second authentication failure message is generated based on the authentication failure between the first authentication parameter in the third playback request and the second authentication parameter of the account center, so that the client displays a second prompt of the corresponding video preloading failure in the video playback list, and the second prompt is generated by the second authentication failure message.
[0143] According to one or more embodiments of the present disclosure, the present disclosure provides a video playback device, the device comprising:
[0144] A request module, configured to send a first play request according to first video information of a currently to-be-played video, so that the server receives the first play request, wherein the first video information includes an authentication identifier, and the first play request carries a first authentication parameter;
[0145] The playback module plays the current video to be played according to the first playback address, the first playback address is generated by the first authentication success information, and the first authentication success information is obtained by the server through successful authentication based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
[0146] According to one or more embodiments of the present disclosure, the present disclosure provides a video playback device, the device comprising:
[0147] An acquisition module, configured to acquire a first playback request of a client, wherein the first playback request is generated by the client according to first video information of a currently played video, wherein the first video information includes an authentication identifier, and the first playback request carries a first authentication parameter;
[0148] The authentication module is used to generate first authentication success information if the authentication is successful based on the first authentication parameter in the first playback request and the second authentication parameter of the account center, so that the client plays the current video to be played based on the first playback address generated by the first authentication success information.
[0149] According to one or more embodiments of the present disclosure, the present disclosure provides an electronic device, including:
[0150] one or more processors;
[0151] a memory for storing one or more programs,
[0152] When the one or more programs are executed by the one or more processors, the one or more processors implement the video playback method as described in any one of the present disclosures.
[0153] According to one or more embodiments of the present disclosure, the present disclosure provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements a video playback method as described in any one of the present disclosure.
[0154] The above description is only a preferred embodiment of the present disclosure and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in the present disclosure (but not limited to) by each other to form a technical solution.
[0155] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details are included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.
[0156] Although the subject matter has been described in language specific to structural features and / or methodological logical actions, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or actions described above. On the contrary, the specific features and actions described above are merely example forms of implementing the claims.
Claims
1. A video playback method, characterized in that: The method comprises: Sending a first play request according to first video information of the current video to be played, so that the server receives the first play request, wherein the first video information includes an authentication identifier, and the authentication identifier is used to indicate whether the video requires an authentication operation; the first play request carries a first authentication parameter, and the first authentication parameter is a preset hash value, and the preset hash value is obtained by the account center through a hash algorithm operation according to the account information when the user registers; Play the current video to be played according to the first playback address, where the first playback address is generated by first authentication success information, where the first authentication success information is obtained by the server through successful authentication according to the first authentication parameter in the first playback request and the second authentication parameter of the account center; The method further includes: sending a second play request according to second video information of the current video to be played, so that the server receives the second play request, the second video information does not include an authentication identifier, and the second play request does not carry a first authentication parameter; playing the current video to be played according to a second play address, the second play address is generated according to first unauthenticated information, and the first unauthenticated information is obtained by the server according to the second video information; The second authentication parameter of the account center is obtained by matching the first authentication parameter stored in the account center according to the authorization scope information of the current video to be played; Among them, the method for generating the first authentication success information includes: comparing the first authentication parameter in the first playback request with the second authentication parameter of the account center through the server, if the first authentication parameter is within the second authentication parameter, the authentication is successful and the first authentication success information is generated.
2. The method according to claim 1, characterized in that Also includes: A first prompt is displayed indicating that the current video to be played has failed to be played, wherein the first prompt is generated by first authentication failure information, wherein the first authentication failure information is obtained by the server through authentication failure based on the first authentication parameter in the first playback request and the second authentication parameter of the account center.
3. The method according to claim 1, characterized in that Before sending a first play request according to the first video information of the current video to be played, the method further includes: Get the user's account information when logging in; Sending the account information to the account center; Receive a first authentication parameter stored in the account center.
4. The method according to claim 3, characterized in that Also includes: The first authentication parameter is stored in the local storage space of the operating system.
5. The method according to claim 1, characterized in that Before sending a first play request according to the first video information of the current video to be played, the method further includes: A first authentication parameter is obtained from the local storage space of the operating system according to the account information when the user logs in. The first authentication parameter is a preset hash value, and the preset hash value is obtained by the account center through a hash algorithm operation according to the account information when the user registers.
6. The method according to any one of claims 1 to 5, characterized in that: Also includes: According to the third video information of the two or more preloaded videos, a third play request is sent in parallel, so that the server receives the third play request in parallel, the third video information includes an authentication identifier, then the corresponding third play request carries the first authentication parameter, and the third video information does not include the authentication identifier, then the corresponding third play request does not carry the first authentication parameter; Preloading a corresponding video in a video playlist according to a third playback address, wherein the third playback address is generated by third authentication success information or second unauthenticated information, wherein the third authentication success information is obtained by the server through successful authentication according to the first authentication parameter in the third playback request and the second authentication parameter of the account center, and the second unauthenticated information is obtained by the server according to the third video information not including an authentication identifier; Alternatively, a second prompt indicating that the corresponding video preloading failure has occurred is displayed in the video playlist, wherein the second prompt is generated by second authentication failure information, and the second authentication failure information is obtained by the server based on the first authentication parameter in the third playback request and the second authentication parameter of the account center after authentication failure.
7. The method according to claim 1, characterized in that Also includes: Open the first playback address through a browser or a video playback program that is not associated with an account; The browser interface or the interface of the video player program that is not associated with an account prompts that the playback failed.
8. A video playback method, characterized in that: The method comprises: Obtaining a first playback request from a client, where the first playback request is generated by the client according to first video information of a currently played video, where the first video information includes an authentication identifier, where the authentication identifier is used to indicate whether the video requires an authentication operation; the first playback request carries a first authentication parameter, where the first authentication parameter is a preset hash value, where the preset hash value is obtained by an account center through a hash algorithm operation based on account information when the user registers; If the authentication is successful according to the first authentication parameter in the first play request and the second authentication parameter of the account center, a first authentication success message is generated, so that the client plays the current to-be-played video according to the first play address generated by the first authentication success message; The method further includes: obtaining a second playback request of the client, the second playback request is generated by the client according to second video information of the current video to be played, the second video information does not include an authentication identifier, and the second playback request does not carry a first authentication parameter; generating first unauthenticated information according to the fact that the second video information sent does not include an authentication identifier, so that the client plays the current video to be played according to a second playback address, the second playback address is generated by the first unauthenticated information; The second authentication parameter of the account center is obtained by matching the first authentication parameter stored in the account center according to the authorization scope information of the current video to be played; Among them, the method for generating the first authentication success information includes: comparing the first authentication parameter in the first playback request with the second authentication parameter of the account center through the server, if the first authentication parameter is within the second authentication parameter, the authentication is successful and the first authentication success information is generated.
9. The method according to claim 8, characterized in that Also includes: If authentication fails between the first authentication parameter in the first playback request and the second authentication parameter of the account center, first authentication failure information is generated, so that the client displays a first prompt that the playback of the current video to be played fails, and the first prompt is generated by the first authentication failure information.
10. The method according to claim 8 or 9, characterized in that: Also includes: Obtaining a third playback request sent in parallel by the client, wherein the third playback request is generated by the client according to third video information of two or more preloaded videos, wherein if the third video information includes an authentication identifier, then the corresponding third playback request carries a first authentication parameter, and if the third video information does not include an authentication identifier, then the corresponding third playback request does not carry the first authentication parameter; The third authentication success information is generated according to the first authentication parameter in the third playback request and the second authentication parameter of the account center through successful authentication, or the second unauthenticated information is generated according to the third video information not including the authentication identifier, so that the client preloads the corresponding video in the video play list according to the third playback address, and the third playback address is generated by the third authentication success information or the second unauthenticated information; Alternatively, a second authentication failure message is generated based on the authentication failure between the first authentication parameter in the third playback request and the second authentication parameter of the account center, so that the client displays a second prompt of the corresponding video preloading failure in the video playback list, and the second prompt is generated by the second authentication failure message.
11. A video playback device, characterized in that: The device comprises: A request module, configured to send a first play request according to first video information of a currently to-be-played video, so that a server receives the first play request, wherein the first video information includes an authentication identifier, and the authentication identifier is used to indicate whether the video requires an authentication operation; the first play request carries a first authentication parameter, and the first authentication parameter is a preset hash value, and the preset hash value is obtained by an account center through a hash algorithm operation according to account information when a user registers; A playback module, playing the current to-be-played video according to a first playback address, wherein the first playback address is generated by first authentication success information, wherein the first authentication success information is obtained by the server through successful authentication based on a first authentication parameter in the first playback request and a second authentication parameter of an account center; The request module is further used to send a second playback request according to the second video information of the current video to be played, so that the server receives the second playback request, the second video information does not include the authentication identifier, and the second playback request does not carry the first authentication parameter; the playback module is further used to play the current video to be played according to the second playback address, the second playback address is generated by the first unauthenticated information, and the first unauthenticated information is obtained by the server according to the second video information sent down does not include the authentication identifier; The second authentication parameter of the account center is obtained by matching the first authentication parameter stored in the account center according to the authorization scope information of the current video to be played; Among them, the method for generating the first authentication success information includes: comparing the first authentication parameter in the first playback request with the second authentication parameter of the account center through the server, if the first authentication parameter is within the second authentication parameter, the authentication is successful and the first authentication success information is generated.
12. A video playback device, characterized in that: The device comprises: an acquisition module, configured to acquire a first playback request from a client, wherein the first playback request is generated by the client according to first video information of a currently played video, wherein the first video information includes an authentication identifier, and the authentication identifier is used to indicate whether the video requires an authentication operation; the first playback request carries a first authentication parameter, and the first authentication parameter is a preset hash value, and the preset hash value is obtained by an account center through a hash algorithm operation according to account information when a user registers; an authentication module, configured to generate first authentication success information if authentication is successful according to a first authentication parameter in the first playback request and a second authentication parameter of the account center, so that the client plays the current to-be-played video according to a first playback address generated by the first authentication success information; The acquisition module is further used to acquire a second playback request of the client, the second playback request is generated by the client according to second video information of the current video to be played, the second video information does not include an authentication identifier, and the second playback request does not carry a first authentication parameter; the authentication module is further used to generate first unauthenticated information according to the fact that the second video information sent does not include an authentication identifier, so that the client plays the current video to be played according to a second playback address, the second playback address is generated by the first unauthenticated information; The second authentication parameter of the account center is obtained by matching the first authentication parameter stored in the account center according to the authorization scope information of the current video to be played; Among them, the method for generating the first authentication success information includes: comparing the first authentication parameter in the first playback request with the second authentication parameter of the account center through the server, if the first authentication parameter is within the second authentication parameter, the authentication is successful and the first authentication success information is generated.
13. An electronic device, characterized in that: include: one or more processors; a memory for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the video playback method as described in any one of claims 1-10.
14. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the video playing method as described in any one of claims 1 to 10 is implemented.
Citation Information
Patent Citations
Video playing method and terminal
CN104837035A
Video playing chain authentication method, device and system, server and storage medium
CN110248215A