Patent ID: 8774413

Claim:
A method for processing entitlement control message (ECM) packets, the method comprising: receiving, by a terminal, a broadcast code stream multiplexing frame, and acquiring an ECM packet from the received broadcast code stream multiplexing frame; and in response to an indicator of the ECM packet is consistent with a locally stored ECM packet indicator, discarding the ECM packet; in response to the indicator of the ECM packet is inconsistent with the locally stored ECM packet indicator, updating the indicator of the local ECM packet and analyzing the ECM packet; wherein the step of analyzing the ECM packet comprises: obtaining data packets that encapsulated with a key for descrambling audio and video data (MTK mikey packets) from the ECM packet and analyze them one by one; in response to that a key indicator corresponding to a MTK mikey packet is consistent with a locally stored key indicator, ignoring the MTK mikey packet and analyzing the next MTK mikey packet; in response to that a key indicator corresponding to a MTK mikey packet is inconsistent with the locally stored key indicator, further judging whether the MTK mikey packet is an error packet, when the MTK mikey packet is not an error packet, obtaining the MTK using the MTK mikey packet; if the MTK mikey packet is an error packet, discarding the MTK mikey packet, and receiving and analyzing the next ECM packet while continue playing as long as the current MTK is valid; and when the current MTK become invalid, stop playing.