CN111050213B - Video playing method and device, electronic equipment and storage medium - Google Patents

Video playing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN111050213B
CN111050213B CN202010055825.9A CN202010055825A CN111050213B CN 111050213 B CN111050213 B CN 111050213B CN 202010055825 A CN202010055825 A CN 202010055825A CN 111050213 B CN111050213 B CN 111050213B
Authority
CN
China
Prior art keywords
video
player
played
encrypted
decryption key
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010055825.9A
Other languages
Chinese (zh)
Other versions
CN111050213A (en
Inventor
帅龙成
苍鹏
李金海
王涛
刘玉鑫
蒋鹏程
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202010055825.9A priority Critical patent/CN111050213B/en
Publication of CN111050213A publication Critical patent/CN111050213A/en
Application granted granted Critical
Publication of CN111050213B publication Critical patent/CN111050213B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/4405Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving video stream decryption

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The disclosure relates to a video playing method, a video playing device, an electronic device and a storage medium, wherein the method comprises the following steps: responding to a video playing instruction, and detecting an encrypted identifier in a video to be played by a player; if the player detects that the video to be played has the encrypted identifier, the player loads a decryption key matched with the encrypted identifier; and the player decrypts the video to be played according to the decryption key to obtain decrypted video data. It can be understood that before the player plays the video, the video to be kept secret is still in an encrypted state, so that the video can be prevented from being stolen or leaked in advance, and the confidentiality and the safety of the video and related information before playing are improved.

Description

Video playing method and device, electronic equipment and storage medium
Technical Field
The present disclosure relates to the field of video processing technologies, and in particular, to a video playing method and apparatus, an electronic device, and a storage medium.
Background
In some scenes, it is often necessary to inform the user of the activity information of the related activity by playing some videos, so that the user can know the purpose of the activity, the arrangement of the activity and the like more intuitively and from multiple angles.
In the related art, in order to ensure that a video can be played smoothly, a client downloads some related videos from a server in advance and stores the videos in the client for playing when needed.
However, with the related art, the stored video is extremely vulnerable to leakage before playing, resulting in low security and safety of related information before playing.
Disclosure of Invention
The present disclosure provides a video playing method, an apparatus, an electronic device and a storage medium, so as to solve at least the problem that the security and safety of related information before playing are not high due to the fact that videos stored in related technologies are easily leaked before playing. The technical scheme of the disclosure is as follows:
according to a first aspect of the embodiments of the present disclosure, there is provided a video playing method, including:
responding to a video playing instruction, and detecting an encrypted identifier in a video to be played by a player;
if the player detects that the video to be played has the encrypted identifier, the player loads a decryption key matched with the encrypted identifier;
and the player decrypts the video to be played according to the decryption secret key to obtain decrypted video data.
In one embodiment, the step of detecting, by the player, the encrypted identifier in the video to be played in response to the video playing instruction includes:
responding to a video playing instruction, and acquiring identification information of the video to be played by a player;
the player detects the encrypted identification in the identification information.
In one embodiment, the identification information includes a uniform resource identifier and the encrypted identification includes an encrypted string.
In one embodiment, the video playing method further includes:
responding to a video playing instruction, the player receives a decryption key sent by a client, wherein the decryption key is obtained by analyzing a picture file stored by the client through the client, and the picture file comprises the decryption key.
In one embodiment, the format of the video is MP4 format.
In one embodiment, the video playing method further includes:
and the player plays the video according to the decrypted video data.
In one embodiment, the player determines a video segment to be played in the video;
the player decrypts the video clip to be played according to the decryption key to obtain a decrypted video clip;
and the player plays the decrypted video clip and parallelly executes decryption on the video clip to be played next.
According to a second aspect of the embodiments of the present disclosure, there is provided a video playing method, including:
caching a video sent by a server side by a client side;
responding to a video playing instruction, the client sends the cached video and the decryption key to a player, so that when the player detects that the encrypted identifier exists in the video, the player decrypts the video according to the decryption key to obtain decrypted video data.
In one embodiment, before the step of sending the cached video and the decryption key to the player, the client further includes:
the client reads a stored picture file containing a decryption key;
and the client analyzes the picture file to obtain the decryption secret key.
In one embodiment, the picture file is an encrypted picture file;
the step of analyzing the picture file by the client to obtain the decryption key by the client comprises the following steps:
the client decrypts the encrypted picture file to obtain a decrypted picture file;
and the client analyzes the decrypted picture file to obtain the decryption key.
According to a third aspect of the embodiments of the present disclosure, there is provided a video playing device, the video playing device being applied to a player, the video playing device including:
the detection unit is configured to execute the detection of the encrypted identification in the video to be played in response to the video playing instruction;
the loading unit is configured to load a decryption key matched with the encryption identifier if the encryption identifier is detected to exist in the video to be played;
and the decryption unit is configured to decrypt the video to be played according to the decryption key to obtain decrypted video data.
In one embodiment, the detection unit is specifically configured to execute, in response to a video playing instruction, acquiring identification information of the video to be played; and detecting the encrypted identification in the identification information.
In one embodiment, the identification information includes a uniform resource identifier and the encrypted identification includes an encrypted string.
In one embodiment, the video playing apparatus further includes:
the receiving unit is configured to execute a video playing instruction, and receive a decryption key sent by a client, wherein the decryption key is obtained by analyzing a picture file stored by the client through the client, and the picture file is a picture file including the decryption key.
In one embodiment, the video is in MP4 format.
In one embodiment, the video playing apparatus further includes:
a playback unit configured to perform playback of the video according to the decrypted video data.
In one embodiment, the decryption unit is specifically configured to perform determining a video segment to be played in the video; decrypting the video clip to be played according to the decryption key to obtain a decrypted video clip; and playing the decrypted video clip, and parallelly executing decryption on the video clip to be played next.
According to a fourth aspect of the embodiments of the present disclosure, there is provided a video playback device, which is applied to a client, the video playback device including:
the caching unit is configured to execute caching of the video sent by the server;
the sending unit is configured to execute sending the cached video and the decryption key to a player in response to a video playing instruction, so that when the player detects that an encryption identifier exists in the video, the player decrypts the video according to the decryption key to obtain decrypted video data.
In one embodiment, the video playing apparatus further includes:
a decryption key obtaining unit configured to perform reading of a stored picture file containing a decryption key; and analyzing the picture file to obtain the decryption key.
In one embodiment, the picture file is an encrypted picture file,
the decryption key obtaining unit is specifically configured to decrypt the encrypted picture file to obtain a decrypted picture file; and analyzing the decrypted picture file to obtain the decryption secret key.
According to a fifth aspect of embodiments of the present disclosure, there is provided an electronic apparatus including:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the video playing method in any embodiment of the first aspect or the second aspect.
According to a sixth aspect of embodiments of the present disclosure, there is provided a storage medium, where instructions, when executed by a processor of an electronic device, enable the electronic device to perform the video playing method described in any one of the first or second aspects.
According to a seventh aspect of embodiments of the present disclosure, there is provided a computer program product, the program product comprising a computer program, the computer program being stored in a readable storage medium, from which at least one processor of a device reads and executes the computer program, so that the device performs the video playback method described in any one of the embodiments of the first aspect.
The technical scheme provided by the embodiment of the disclosure at least brings the following beneficial effects: when a video playing requirement exists, the player firstly carries out encryption detection on a video to be played, and if the video is detected to be encrypted, the player acquires a decryption key to decrypt the video, so that the video can be played according to the decrypted video data. It can be understood that before the player plays the video, the video to be kept secret is still in an encrypted state, so that the video can be prevented from being stolen or leaked in advance, and the confidentiality and the safety of the video and related information before playing are improved.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the disclosure and are not to be construed as limiting the disclosure.
Fig. 1 is a diagram illustrating an application environment of a video playing method according to an exemplary embodiment.
Fig. 2 is a flow chart illustrating a video playback method according to an example embodiment.
Fig. 3 is a flow diagram illustrating a complementary scheme for a player to detect an encrypted identification in a video to be played in response to a video play instruction according to an example embodiment.
Fig. 4 is a flowchart illustrating a complementary scheme for decrypting, by a player, a video to be played according to a decryption key to obtain decrypted video data according to an exemplary embodiment.
Fig. 5 is a block diagram illustrating a video playback device according to an example embodiment.
Fig. 6 is a block diagram illustrating a video playback device according to an example embodiment.
Fig. 7 is an internal block diagram of an electronic device shown in accordance with an example embodiment.
Detailed Description
In order to make the technical solutions of the present disclosure better understood by those of ordinary skill in the art, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the above-described drawings are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the disclosure described herein are capable of operation in sequences other than those illustrated or otherwise described herein. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
The video playing method provided by the present disclosure may be applied to the application environment shown in fig. 1. The encryption client 102 interacts with a source station 104 in a Content Delivery Network (CDN) through a network, the source station 104 interacts with a CDN node 106 in the content delivery network through the network, each client 108 interacts with the CDN node 106 through the network, and a player is configured in each client 108 for video playing. Specifically, the encryption client 102 is configured to encrypt a video to be secured and upload the secured video and/or unsecured video to the source station 104. The source station 104 is configured to distribute the secure and/or unsecured video to the CDN nodes 106 such that the clients 108 can download the secure and/or unsecured video through the CDN nodes 106. When the video needs to be played, the player 110 reads the cached secure video and/or unsecure video from the client 108, and the client 108 sends the decryption key encrypted and stored in the picture file to the player 110. Next, the player 110 detects an encrypted identifier in the video to be played, and if it is detected that the encrypted identifier exists in the video, loads a decryption key matched with the encrypted identifier, and further decrypts the video according to the decryption key to obtain a decrypted video. If the video is not encrypted, the video can be directly played.
In another application environment, the encryption operation on the video to be encrypted can be implemented by using the server, and then, in combination with the last application scenario, as an adjustment, the encryption client 102 only needs to upload the video to be encrypted to the server, and then the subsequent encryption task is completed by the server. In yet another application environment, the encryption client 102 may be discarded, i.e. the encryption client 102 is not required to upload video, but the server directly reads its stored video data and encrypts the video to be kept secret. It can be understood that the video playing method provided by the present disclosure can be applied to various application scenarios, and the three application scenarios are also only exemplary, and the video playing method is not limited to the three application scenarios.
Fig. 2 is a flowchart illustrating a video playing method according to an exemplary embodiment, where the video playing method is used in a player, as shown in fig. 2, and includes the following steps.
In step S202, in response to a video playing instruction, the player detects an encryption identifier in a video to be played.
The player refers to software capable of playing video files stored in a digital signal form, and may also refer to an electronic device product having a function of playing the video files. Illustratively, the player may be an application embedded in the client.
Alternatively, the player is embedded in the client for example. First, before step S202, the client needs to download and cache a corresponding video from the server. When a video playing requirement is detected, the client sends the video to the player in response to the video playing instruction. The player will detect the encrypted identification in the video to be played. Wherein the encrypted identifier is used to distinguish between encrypted video and unencrypted video. Optionally, the format of the video is MP4 format.
In step S204, if the player detects that the video to be played has the encrypted identifier, the player loads a decryption key matching the encrypted identifier.
Specifically, if the player detects that the encrypted identifier exists in the video, the player first matches the corresponding decryption key, and loads the decryption key after the matching is successful. Alternatively, the decryption key may be sent by the client to the player so that the player can obtain the decryption key conveniently and quickly.
In step S206, the player decrypts the video to be played according to the decryption key, so as to obtain decrypted video data.
The decrypted video data may be understood as video data with the encryption identifier removed.
Specifically, after loading the decryption key, the player decrypts the encrypted video according to the decryption key, thereby obtaining decrypted video data. And then the player plays the video according to the decrypted video data.
In the video playing method, when a video playing requirement exists, the player firstly carries out encryption detection on the video to be played, and if the video is detected to be encrypted, the player acquires the decryption key to decrypt the video, so that the video can be played according to the decrypted video data. It can be understood that before the player plays the video, the video to be kept secret is still in an encrypted state, so that the video can be prevented from being stolen or leaked in advance, and the confidentiality and the safety of the video and related information before playing are improved.
In an exemplary embodiment, as shown in fig. 3, step S202 includes the steps of:
in step S2022, in response to the video playing instruction, the player acquires identification information of a video to be played.
In step S2024, the player detects the encrypted identification in the identification information.
The identification information is used for marking the attribute of the video resource. Optionally, the identification information may include a uniform resource identifier, uri. The encrypted identification may be integrated in the uniform resource identifier. The encrypted identification may be in a consistent identification format with the identification information, such as: the identification information adopts a character string format, so that the encrypted identification also adopts the character string format for the convenience of identification and analysis. Of course, the encrypted identifier may adopt an identifier format different from that of the positioning identifier, as long as the player can recognize the encrypted identifier and read the information therein, so as to complete the subsequent decryption process.
Specifically, when the player reads a video cached by the client, the player acquires identification information corresponding to the video, such as the video uri. Then, the player detects whether the identification information contains an encrypted identifier, and if the identification information contains the encrypted identifier, the player determines that the video is encrypted. And if the identification information is judged not to contain the encrypted identification, judging that the video is not encrypted. Optionally, as mentioned above, when the video uri is used for the encryption judgment, since the video uri is in the character string format, the encryption identifier is correspondingly in the character string format. It is understood that the character string corresponding to the encrypted identifier is substantially a substring in the character string corresponding to the video uri, so that once the player detects that the video uri includes the substring corresponding to the encrypted identifier, it can determine that the video uri is encrypted. The encryption mode realizes the encryption of the video by an external intervention means, and whether the video is encrypted can be judged by only detecting the external means when the video is encrypted and detected, so that the integrity of video information can be ensured.
For example, assume that an initial uri of a video is: http://192.168.1.100:8080/video/1. avi. To encrypt video, specific strings are used such as: sf540p as an encryption identifier, and added to the original uri, that results in encrypted video uri: http://192.168.1.100:8080/video/1.avi _ sf540p _. In this way, the player can determine that the video is encrypted as long as it detects that the video uri includes the specific character string of _ sf540 p-. On the contrary, if the specific character string of _ sf540 _ 540p _ is not detected in the video uri, it is determined that the video is not encrypted, and the player can play the video without decrypting the key.
In an exemplary embodiment, the method further comprises the steps of:
s203, in response to the video playing instruction, the player receives the decryption key sent by the client.
The decryption key is obtained by analyzing the image file stored by the client through the client, and the image file is the image file comprising the decryption key.
Specifically, before step S203, the client stores the decryption key in the picture file included therein. Further, in order to improve storage security, the client encrypts the picture file so that the decryption key is also in an encrypted state. Based on this, when the player determines that the video is encrypted, the required decryption key needs to be obtained from the encrypted picture file after the encrypted picture file is decrypted. Alternatively, the client may send the decryption key along with the video when sending it to the player. In addition, the client may also send the decryption key to the player after the player determines that the video is encrypted.
Optionally, the picture file may be a png file, a jpg file, a bmp file, or the like, and of course, may also be a picture file in other formats, which is not limited in this embodiment.
For example, taking the png file as an example, the png file is stored in the client, and the png file can be stored in an encrypted manner as a decryption key, for example, a carrier of the decryption key. Optionally, the picture encryption method may select a modified picture suffix name method, a compressed encryption method, and the like. As an example, the png file is securely encrypted by adopting a compression encryption mode. Furthermore, the png file can be packaged into an installation package corresponding to the client, so that the security of video storage can be improved by increasing the difficulty in acquiring the decryption key, and the video content is prevented from being leaked in advance.
In an exemplary embodiment, as shown in fig. 4, step S206 includes the steps of:
in step S2062, the player determines a video segment to be played in the video.
In step S2064, the player decrypts the video segment to be played according to the decryption key, so as to obtain a decrypted video segment.
In step S2066, the player plays the decrypted video segment and performs decryption on the video segment to be played next in parallel.
Specifically, before step S206, a plurality of video segments obtained by the video according to the preset division mode need to be encrypted by the encryption device, respectively, so as to obtain encrypted video segments, for example, 16 bytes are used as an encryption unit for encryption. Therefore, when the video is played, the player can also play according to the video clips, so that the video of any clip can be extracted to play, and the flexibility of video playing is improved. Before the player plays the video clip, the video clip to be played needs to be decrypted according to the decryption key, so as to obtain the decrypted video clip. For example, a decryption unit of 16 bytes, for example, of the video segment to be played is decrypted by the decryption key. Therefore, the effect of playing while decrypting can be realized, and the playing efficiency is higher.
Based on the same inventive concept, a video playing method is also provided, which is exemplified by the application of the method to the client 108. The method comprises the following steps:
in step S212, the client caches the video sent by the server.
Wherein the video comprises encrypted video and/or non-encrypted video. Specifically, the client receives the video sent by the server and caches the video in the client.
In step S214, in response to the video playing instruction, the client sends the cached video and the decryption key to the player, so that when the player detects that the encrypted identifier exists in the video, the player decrypts the video according to the decryption key to obtain decrypted video data.
When the playing requirement exists, the client responds to the video playing instruction and sends the cached video and the decryption key to the player. And when detecting that the encrypted identifier exists in the video, the player decrypts the video according to the decryption key to obtain decrypted video data, and then plays the video according to the decrypted video data.
In the video playing method, the encrypted video is cached in the client, so that the video to be kept secret cached by the client is still in an encrypted state before the player plays the video, and the confidentiality and the safety of the video and the related information before playing are improved.
In an exemplary embodiment, the video playing method further includes the steps of:
in step S222, the client reads the stored picture file containing the decryption key;
in step S224, the client parses the picture file to obtain a decryption key.
Specifically, before step S222, the client stores the decryption key in the picture file included therein in advance. Further, in order to improve storage security, the client encrypts the picture file so that the decryption key is also in an encrypted state. Furthermore, when the decryption key is needed, the client side decrypts the image file and then analyzes the image file to obtain the decryption key.
In this embodiment, by increasing the difficulty in obtaining the decryption key, the security of video storage can be improved, and video content is prevented from leaking in advance.
Further, in one embodiment, the picture file may be packaged in the client's installation package in advance, so that the picture file is downloaded along with other download resources when the client is downloaded. When the client side obtains the picture file, the compression packet needs to be decompressed first to obtain the picture file. It can be understood that, by adding the operation step of obtaining the picture file, the difficulty of obtaining the decryption key can be further increased.
It should be understood that although the various steps in the flow diagrams of fig. 2-4 are shown in order as indicated by the arrows, the steps are not necessarily performed in order as indicated by the arrows. The steps are not limited to being performed in the exact order illustrated and, unless explicitly stated herein, may be performed in other orders. Moreover, at least some of the steps in fig. 2-4 may include multiple steps or multiple stages, which are not necessarily performed at the same time, but may be performed at different times, which are not necessarily performed in sequence, but may be performed in turn or alternately with other steps or at least some of the other steps.
Fig. 5 is a block diagram illustrating a video playback device according to an example embodiment. Referring to fig. 5, the video playing apparatus is applied to a player, and includes a detection unit 302, a loading unit 304, and a decryption unit 306.
The detection unit 302 is configured to perform detection of an encryption identifier in a video to be played in response to a video playing instruction;
the loading unit 304 is configured to load a decryption key matching the encryption identifier if it is detected that the encryption identifier exists in the video to be played;
the decryption unit 306 is configured to perform decryption on the video to be played according to the decryption key, so as to obtain decrypted video data.
In the above video playing device, when there is a video playing requirement, the player first performs encryption detection on the video to be played, and if it is detected that the video is encrypted, the player acquires the decryption key to decrypt the video, so that the video can be played according to the decrypted video data. It can be understood that before the player plays the video, the video to be kept secret is still in an encrypted state, so that the video can be prevented from being stolen or leaked in advance, and the confidentiality and the safety of the video and related information before playing are improved.
In an exemplary embodiment, the detecting unit 302 is specifically configured to execute, in response to a video playing instruction, acquiring identification information of a video to be played; and detecting the encrypted identification in the identification information.
In an exemplary embodiment, the identification information includes a uniform resource identifier and the encrypted identification includes an encrypted string.
In an exemplary embodiment, the video playing apparatus further includes a receiving unit (not shown). The receiving unit is configured to execute receiving a decryption key sent by a client in response to a video playing instruction, wherein the decryption key is obtained by parsing, by the client, from a picture file stored by the client, and the picture file is a picture file including the decryption key.
In an exemplary embodiment, the format of the video is MP4 format.
In an exemplary embodiment, the video playing apparatus further includes a playing unit (not shown). The playback unit is configured to perform playback of video from the decrypted video data.
In an exemplary embodiment, the decryption unit 306 is specifically configured to perform determining a video segment to be played in the video; decrypting the video clip to be played according to the decryption key to obtain a decrypted video clip; and playing the decrypted video clip, and parallelly executing decryption on the video clip to be played next.
Fig. 6 is a block diagram illustrating a video playback device according to an example embodiment. Referring to fig. 6, the video playback device 40 is applied to a client, and the video playback device 40 includes a buffer unit 402 and a transmission unit 404.
The caching unit 402 is configured to perform caching of the video sent by the server;
the sending unit 404 is configured to execute sending the cached video and the decryption key to the player in response to a video playing instruction, so that when the player detects that the encrypted identifier exists in the video, the player decrypts the video according to the decryption key to obtain decrypted video data.
According to the video playing device, the encrypted video is cached in the client, so that the video needing to be kept secret and cached by the client is still in an encrypted state before the player plays the video, and the confidentiality and the safety of the video and related information before playing are improved.
In one embodiment, the video playing apparatus further includes a decryption key obtaining unit (not shown). The decryption key obtaining unit is configured to read a stored picture file containing a decryption key; and analyzing the picture file to obtain a decryption key.
In one embodiment, the picture file is an encrypted picture file. The decryption key obtaining unit is specifically configured to decrypt the encrypted picture file to obtain a decrypted picture file; and analyzing the decrypted picture file to obtain a decryption key.
With regard to the apparatus in the above-described embodiment, the specific manner in which each module performs the operation has been described in detail in the embodiment related to the method, and will not be elaborated here.
Fig. 7 is a block diagram illustrating an apparatus 700 for performing a video playback method according to an example embodiment. For example, device 700 may be a mobile phone, computer, digital broadcast client, messaging device, game console, tablet device, medical device, fitness device, personal digital assistant, and so forth.
Referring to fig. 7, device 700 may include one or more of the following components: a processing component 702, a memory 704, a power component 706, a multimedia component 708, an audio component 710, an input/output (I/O) interface 712, a sensor component 714, and a communication component 716.
The processing component 702 generally controls the overall operation of the device 700, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing components 702 may include one or more processors 720 to execute instructions to perform all or a portion of the steps of the methods described above. Further, the processing component 702 may include one or more modules that facilitate interaction between the processing component 702 and other components. For example, the processing component 702 may include a multimedia module to facilitate interaction between the multimedia component 708 and the processing component 702.
The memory 704 is configured to store various types of data to support operation at the device 700. Examples of such data include instructions for any application or method operating on device 700, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 704 may be implemented by any type or combination of volatile or non-volatile storage devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
The power supply component 706 provides power to the various components of the device 700. The power components 706 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device 700.
The multimedia component 708 includes a screen that provides an output interface between the device 700 and a user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 708 includes a front facing camera and/or a rear facing camera. The front camera and/or the rear camera may receive external multimedia data when the device 700 is in an operating mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 710 is configured to output and/or input audio signals. For example, the audio component 710 includes a Microphone (MIC) configured to receive external audio signals when the device 700 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signal may further be stored in the memory 704 or transmitted via the communication component 716. In some embodiments, audio component 710 also includes a speaker for outputting audio signals.
The I/O interface 712 provides an interface between the processing component 702 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor assembly 714 includes one or more sensors for providing status assessment of various aspects of the device 700. For example, the sensor component 714 may detect an open/closed state of the device 700, the relative positioning of components, such as a display and keypad of the device 700, the sensor component 714 may also detect a change in position of the device 700 or a component of the device 700, the presence or absence of user contact with the device 700, orientation or acceleration/deceleration of the device 700, and a change in temperature of the device 700. The sensor assembly 714 may include a proximity sensor configured to detect the presence of nearby objects in the absence of any physical contact. The sensor assembly 714 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 714 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 716 is configured to facilitate wired or wireless communication between the device 700 and other devices. The device 700 may access a wireless network based on a communication standard, such as WiFi, an operator network (such as 2G, 3G, 4G, or 5G), or a combination thereof. In an exemplary embodiment, the communication component 716 receives a broadcast signal or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 716 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the device 700 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the above-described methods.
In an exemplary embodiment, a non-transitory computer readable storage medium comprising instructions, such as the memory 704 comprising instructions, executable by the processor 720 of the device 700 to perform the above-described method is also provided. For example, the non-transitory computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (12)

1.A video playing method is characterized by comprising the following steps:
responding to a video playing instruction, and acquiring a uniform resource identifier of a video to be played by a player;
the player detects a character string corresponding to an encrypted identifier in the uniform resource identifier;
if the player detects that the character string corresponding to the encrypted identifier exists in the uniform resource identifier, the player judges that the video to be played is an encrypted video, and loads a decryption key matched with the encrypted identifier; the decryption key is obtained by decrypting the encrypted picture file stored by the client when the player judges that the video to be played is encrypted, analyzing the decrypted picture file, and sending the decrypted picture file to the player by the client, wherein the picture file is a picture file comprising the decryption key;
the player determines a video clip to be played in the video; the video clip is obtained by dividing and encrypting the video according to a preset dividing mode;
the player decrypts the video clip to be played according to the decryption key to obtain a decrypted video clip;
and the player plays the decrypted video clip and parallelly executes decryption on the video clip to be played next.
2. The video playback method according to claim 1, further comprising:
and responding to a video playing instruction, and receiving a decryption key sent by the client by the player.
3. The video playback method of claim 1, wherein the video format is MP4 format.
4. The video playback method according to any one of claims 1 to 3, wherein the video playback method further comprises:
and the player plays the video according to the decrypted video data.
5. A video playing method is characterized by comprising the following steps:
caching a video sent by a server at a client;
responding to a video playing instruction, the client sends the cached video to a player so that the player responds to the video playing instruction, the player obtains a uniform resource identifier of the video to be played, detects a character string corresponding to an encryption identifier in the uniform resource identifier, and judges that the video to be played is the encrypted video when detecting that the character string corresponding to the encryption identifier exists in the uniform resource identifier;
when the player judges that the video to be played is encrypted, the client decrypts the encrypted picture file stored by the client, obtains a decryption key matched with the encryption identifier based on analysis in the decrypted picture file, and sends the decryption key to the player;
the player is used for loading the decryption key when detecting that an encryption identifier exists in the video, determining a video clip to be played in the video, decrypting the video clip to be played according to the decryption key to obtain a decrypted video clip, playing the decrypted video clip, and parallelly executing decryption on the next video clip to be played; the video clip is obtained by dividing and encrypting the video according to a preset dividing mode.
6. A video playing apparatus, wherein the video playing apparatus is applied to a player, and the video playing apparatus comprises:
the detection unit is configured to execute and respond to a video playing instruction to acquire a uniform resource identifier of a video to be played; detecting an encrypted identification in the identifier;
the loading unit is configured to execute the steps of judging that the video to be played is an encrypted video if the fact that the character string corresponding to the encrypted identifier exists in the uniform resource identifier is detected, and loading a decryption key matched with the encrypted identifier; the decryption key is obtained by decrypting the encrypted picture file stored by the client when the player judges that the video to be played is encrypted, analyzing the decrypted picture file, and sending the decrypted picture file to the player by the client, wherein the picture file is a picture file comprising the decryption key;
a decryption unit configured to perform determining a video segment to be played in the video; decrypting the video clip to be played according to the decryption key to obtain a decrypted video clip; and playing the decrypted video clip, and parallelly executing decryption on the next video clip to be played, wherein the video clip is obtained by dividing and encrypting the video according to a preset dividing mode.
7. The video playback device according to claim 6, further comprising:
and the receiving unit is configured to execute the decryption key sent by the client in response to the video playing instruction.
8. The video playback device of claim 6, wherein the video format is MP4 format.
9. The video playback device according to any one of claims 6 to 8, wherein the video playback device further comprises:
a playback unit configured to perform playback of the video according to the decrypted video data.
10. A video playing apparatus, wherein the video playing apparatus is applied to a client, the video playing apparatus comprises:
the caching unit is configured to execute caching of the video sent by the server;
the sending unit is configured to execute responding to a video playing instruction, send the cached video to a player, so that the player responds to the video playing instruction, the player obtains a uniform resource identifier of the video to be played, detects a character string corresponding to an encryption identifier in the uniform resource identifier, and judges that the video to be played is the encrypted video when detecting that the character string corresponding to the encryption identifier exists in the uniform resource identifier;
the video playing device is further configured to decrypt the stored encrypted picture file when the player determines that the video to be played is encrypted, obtain a decryption key matched with the encryption identifier based on analysis in the decrypted picture file, and send the decryption key to the player by the client;
the player is used for loading the decryption key when detecting that an encryption identifier exists in the video, determining a video clip to be played in the video, decrypting the video clip to be played according to the decryption key to obtain a decrypted video clip, playing the decrypted video clip, and parallelly executing decryption on the next video clip to be played; the video clip is obtained by dividing and encrypting the video according to a preset dividing mode.
11. An electronic device, comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the video playback method of any one of claims 1 to 4 or the video playback method of claim 5.
12. A storage medium in which instructions, when executed by a processor of an electronic device, enable the electronic device to perform the video playback method of any one of claims 1 to 4 or the video playback method of claim 5.
CN202010055825.9A 2020-01-17 2020-01-17 Video playing method and device, electronic equipment and storage medium Active CN111050213B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010055825.9A CN111050213B (en) 2020-01-17 2020-01-17 Video playing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010055825.9A CN111050213B (en) 2020-01-17 2020-01-17 Video playing method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN111050213A CN111050213A (en) 2020-04-21
CN111050213B true CN111050213B (en) 2022-08-26

Family

ID=70230750

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010055825.9A Active CN111050213B (en) 2020-01-17 2020-01-17 Video playing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111050213B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112969094A (en) * 2021-02-26 2021-06-15 江西格灵如科科技有限公司 Virtual reality video decryption system and method
CN113727191A (en) * 2021-08-30 2021-11-30 山谷网安科技股份有限公司 Portable encrypted mobile training system and device and encrypted training method

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104270614A (en) * 2014-10-16 2015-01-07 浙江宇视科技有限公司 Video encryption and decryption method and device
CN105611318A (en) * 2014-11-25 2016-05-25 上海天脉聚源文化传媒有限公司 Method and system for video encryption playing
CN107659829A (en) * 2017-11-06 2018-02-02 网宿科技股份有限公司 A kind of method and system of video-encryption
CN107809436A (en) * 2017-11-10 2018-03-16 北京世纪鼎点软件有限公司 Authority discrimination method, encryption method, the apparatus and system of Internet video access
CN108156152A (en) * 2017-12-22 2018-06-12 北京百度网讯科技有限公司 Streaming Media downloads method, apparatus, storage medium and the terminal device with playing
CN109862424A (en) * 2019-03-29 2019-06-07 北京金山安全软件有限公司 Video playing method and device and electronic equipment

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI510066B (en) * 2010-03-22 2015-11-21 Echostar Technologies Llc Systems and methods for securely streaming media content
US8983076B2 (en) * 2011-12-22 2015-03-17 Adobe Systems Incorporated Methods and apparatus for key delivery in HTTP live streaming
US9892239B2 (en) * 2013-01-29 2018-02-13 Mobitv, Inc. Digital rights management for HTTP-based media streaming
US9075962B1 (en) * 2014-02-11 2015-07-07 Ramp Holdings, Inc. Secure video delivery
US9838202B2 (en) * 2015-08-31 2017-12-05 Microsoft Technology Licensing, Llc Modifying a content descriptor to facilitate delivery of token-authorized encrypted data
CN108156479B (en) * 2016-12-06 2021-04-02 创盛视联数码科技(北京)有限公司 Encryption and decryption method for video playing uri of video cloud platform
US10142684B2 (en) * 2017-03-21 2018-11-27 Cisco Technology, Inc. Pinning encryption metadata to segment URIs
CN106973310A (en) * 2017-04-13 2017-07-21 中国联合网络通信集团有限公司 The player method of Streaming Media, EPG server and CDN server in a kind of IPTV system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104270614A (en) * 2014-10-16 2015-01-07 浙江宇视科技有限公司 Video encryption and decryption method and device
CN105611318A (en) * 2014-11-25 2016-05-25 上海天脉聚源文化传媒有限公司 Method and system for video encryption playing
CN107659829A (en) * 2017-11-06 2018-02-02 网宿科技股份有限公司 A kind of method and system of video-encryption
CN107809436A (en) * 2017-11-10 2018-03-16 北京世纪鼎点软件有限公司 Authority discrimination method, encryption method, the apparatus and system of Internet video access
CN108156152A (en) * 2017-12-22 2018-06-12 北京百度网讯科技有限公司 Streaming Media downloads method, apparatus, storage medium and the terminal device with playing
CN109862424A (en) * 2019-03-29 2019-06-07 北京金山安全软件有限公司 Video playing method and device and electronic equipment

Also Published As

Publication number Publication date
CN111050213A (en) 2020-04-21

Similar Documents

Publication Publication Date Title
CN110619220B (en) Method and device for encrypting neural network model and storage medium
CN105049213A (en) File signature method and device
US20220382884A1 (en) Method and device for parsing shared password
CN111050213B (en) Video playing method and device, electronic equipment and storage medium
CN106372517A (en) File encryption method, file decryption method, file encryption device and equipment
CN109246110B (en) Data sharing method and device and computer readable storage medium
CN108900553B (en) Communication method, device and computer readable storage medium
CN109241423B (en) Information recommendation method and device, electronic equipment and storage medium
CN113301431A (en) Video data encryption and decryption method and device, electronic equipment and system
CN115146285A (en) File encryption and decryption method and device
CN115333813A (en) Data encryption transmission method and device, electronic equipment and storage medium
CN104331672A (en) Method and device for performing confidential treatment on pictures upon bracelet
CN105681365B (en) Method and apparatus for file transmission
CN105282162A (en) Processing method and device for account management business
CN110677551B (en) Image encryption method, device, equipment and storage medium
CN113055169B (en) Data encryption method and device, electronic equipment and storage medium
CN105120452A (en) Information transmission method, device and system
CN107566354B (en) Webpage content detection method and device and storage medium
CN112733092B (en) Information processing method and device
CN114189950A (en) Information interaction method, information interaction device, server and storage medium
CN107302519B (en) Identity authentication method and device for terminal equipment, terminal equipment and server
CN113868505A (en) Data processing method and device, electronic equipment, server and storage medium
CN114553552A (en) Data encryption method and device, data decryption method and device and storage medium
CN115277117A (en) File viewing method and device, electronic equipment and storage medium
CN113591120A (en) Information issuing method and device, electronic equipment and storage medium

Legal Events

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