308 lines
18 KiB
HTML
308 lines
18 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.8.17"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>Shaka Packager SDK: shaka::media::DecryptConfig Class Reference</title>
|
|
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="../../jquery.js"></script>
|
|
<script type="text/javascript" src="../../dynsections.js"></script>
|
|
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="../../search/searchdata.js"></script>
|
|
<script type="text/javascript" src="../../search/search.js"></script>
|
|
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td id="projectalign" style="padding-left: 0.5em;">
|
|
<div id="projectname">Shaka Packager SDK
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.8.17 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="../../menudata.js"></script>
|
|
<script type="text/javascript" src="../../menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
$(function() {
|
|
initMenu('../../',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
/* @license-end */</script>
|
|
<div id="main-nav"></div>
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
<div id="nav-path" class="navpath">
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="../../d8/daf/namespaceshaka.html">shaka</a></li><li class="navelem"><b>media</b></li><li class="navelem"><a class="el" href="../../de/d49/classshaka_1_1media_1_1DecryptConfig.html">DecryptConfig</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="summary">
|
|
<a href="#pub-methods">Public Member Functions</a> |
|
|
<a href="#pub-static-attribs">Static Public Attributes</a> |
|
|
<a href="../../d4/d5c/classshaka_1_1media_1_1DecryptConfig-members.html">List of all members</a> </div>
|
|
<div class="headertitle">
|
|
<div class="title">shaka::media::DecryptConfig Class Reference</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
|
|
<p><code>#include <<a class="el" href="../../df/dad/decrypt__config_8h_source.html">decrypt_config.h</a>></code></p>
|
|
<table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
|
|
Public Member Functions</h2></td></tr>
|
|
<tr class="memitem:a24035bb6edcb3aaaa9923bf385376ae5"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d49/classshaka_1_1media_1_1DecryptConfig.html#a24035bb6edcb3aaaa9923bf385376ae5">DecryptConfig</a> (const std::vector< uint8_t > &key_id, const std::vector< uint8_t > &iv, const std::vector< <a class="el" href="../../d1/d34/structshaka_1_1media_1_1SubsampleEntry.html">SubsampleEntry</a> > &subsamples)</td></tr>
|
|
<tr class="separator:a24035bb6edcb3aaaa9923bf385376ae5"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ab2dfe0a2ee285539843ac55b5f1ac7c7"><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d49/classshaka_1_1media_1_1DecryptConfig.html#ab2dfe0a2ee285539843ac55b5f1ac7c7">DecryptConfig</a> (const std::vector< uint8_t > &key_id, const std::vector< uint8_t > &iv, const std::vector< <a class="el" href="../../d1/d34/structshaka_1_1media_1_1SubsampleEntry.html">SubsampleEntry</a> > &subsamples, FourCC protection_scheme, uint8_t crypt_byte_block, uint8_t skip_byte_block)</td></tr>
|
|
<tr class="separator:ab2dfe0a2ee285539843ac55b5f1ac7c7"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a36681ecf1eeb8a4effb0f00b232bda58"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d49/classshaka_1_1media_1_1DecryptConfig.html#a36681ecf1eeb8a4effb0f00b232bda58">AddSubsample</a> (uint16_t clear_bytes, uint32_t cipher_bytes)</td></tr>
|
|
<tr class="separator:a36681ecf1eeb8a4effb0f00b232bda58"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:af01188eb9ea205e60f992f32fe2f4a11"><td class="memItemLeft" align="right" valign="top">size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d49/classshaka_1_1media_1_1DecryptConfig.html#af01188eb9ea205e60f992f32fe2f4a11">GetTotalSizeOfSubsamples</a> () const</td></tr>
|
|
<tr class="separator:af01188eb9ea205e60f992f32fe2f4a11"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:ada34addfb2c1d889db44ee4d6d48bd01"><td class="memItemLeft" align="right" valign="top"><a id="ada34addfb2c1d889db44ee4d6d48bd01"></a>
|
|
const std::vector< uint8_t > & </td><td class="memItemRight" valign="bottom"><b>key_id</b> () const</td></tr>
|
|
<tr class="separator:ada34addfb2c1d889db44ee4d6d48bd01"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a9ead874ca9a856e83eb559a65dc11bc3"><td class="memItemLeft" align="right" valign="top"><a id="a9ead874ca9a856e83eb559a65dc11bc3"></a>
|
|
const std::vector< uint8_t > & </td><td class="memItemRight" valign="bottom"><b>iv</b> () const</td></tr>
|
|
<tr class="separator:a9ead874ca9a856e83eb559a65dc11bc3"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a0795a62e6f52ffd8f642875896ecb3a8"><td class="memItemLeft" align="right" valign="top"><a id="a0795a62e6f52ffd8f642875896ecb3a8"></a>
|
|
const std::vector< <a class="el" href="../../d1/d34/structshaka_1_1media_1_1SubsampleEntry.html">SubsampleEntry</a> > & </td><td class="memItemRight" valign="bottom"><b>subsamples</b> () const</td></tr>
|
|
<tr class="separator:a0795a62e6f52ffd8f642875896ecb3a8"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a67d71547eafac158dac9f8436efe8d9a"><td class="memItemLeft" align="right" valign="top"><a id="a67d71547eafac158dac9f8436efe8d9a"></a>
|
|
FourCC </td><td class="memItemRight" valign="bottom"><b>protection_scheme</b> () const</td></tr>
|
|
<tr class="separator:a67d71547eafac158dac9f8436efe8d9a"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:aabb3e097623cdabb66c93c289df07c7d"><td class="memItemLeft" align="right" valign="top"><a id="aabb3e097623cdabb66c93c289df07c7d"></a>
|
|
uint8_t </td><td class="memItemRight" valign="bottom"><b>crypt_byte_block</b> () const</td></tr>
|
|
<tr class="separator:aabb3e097623cdabb66c93c289df07c7d"><td class="memSeparator" colspan="2"> </td></tr>
|
|
<tr class="memitem:a6879ab0b52b5181582f68867cc8aff8c"><td class="memItemLeft" align="right" valign="top"><a id="a6879ab0b52b5181582f68867cc8aff8c"></a>
|
|
uint8_t </td><td class="memItemRight" valign="bottom"><b>skip_byte_block</b> () const</td></tr>
|
|
<tr class="separator:a6879ab0b52b5181582f68867cc8aff8c"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table><table class="memberdecls">
|
|
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-attribs"></a>
|
|
Static Public Attributes</h2></td></tr>
|
|
<tr class="memitem:afa140203b87d3e46d5fd94b231734f53"><td class="memItemLeft" align="right" valign="top"><a id="afa140203b87d3e46d5fd94b231734f53"></a>
|
|
static const size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d49/classshaka_1_1media_1_1DecryptConfig.html#afa140203b87d3e46d5fd94b231734f53">kDecryptionKeySize</a> = 16</td></tr>
|
|
<tr class="memdesc:afa140203b87d3e46d5fd94b231734f53"><td class="mdescLeft"> </td><td class="mdescRight">Keys are always 128 bits. <br /></td></tr>
|
|
<tr class="separator:afa140203b87d3e46d5fd94b231734f53"><td class="memSeparator" colspan="2"> </td></tr>
|
|
</table>
|
|
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
|
|
<div class="textblock"><p>Contains all the information that a decryptor needs to decrypt a media sample. </p>
|
|
|
|
<p class="definition">Definition at line <a class="el" href="../../df/dad/decrypt__config_8h_source.html#l00040">40</a> of file <a class="el" href="../../df/dad/decrypt__config_8h_source.html">decrypt_config.h</a>.</p>
|
|
</div><h2 class="groupheader">Constructor & Destructor Documentation</h2>
|
|
<a id="a24035bb6edcb3aaaa9923bf385376ae5"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a24035bb6edcb3aaaa9923bf385376ae5">◆ </a></span>DecryptConfig() <span class="overload">[1/2]</span></h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">shaka::media::DecryptConfig::DecryptConfig </td>
|
|
<td>(</td>
|
|
<td class="paramtype">const std::vector< uint8_t > & </td>
|
|
<td class="paramname"><em>key_id</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">const std::vector< uint8_t > & </td>
|
|
<td class="paramname"><em>iv</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">const std::vector< <a class="el" href="../../d1/d34/structshaka_1_1media_1_1SubsampleEntry.html">SubsampleEntry</a> > & </td>
|
|
<td class="paramname"><em>subsamples</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
<p>Create a 'cenc' decrypt config. </p><dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">key_id</td><td>is the ID that references the decryption key. </td></tr>
|
|
<tr><td class="paramname">iv</td><td>is the initialization vector defined by the encryptor. </td></tr>
|
|
<tr><td class="paramname">subsamples</td><td>defines the clear and encrypted portions of the sample as described in <a class="el" href="../../d1/d34/structshaka_1_1media_1_1SubsampleEntry.html">SubsampleEntry</a>. A decrypted buffer will be equal in size to the sum of the subsample sizes. </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
|
|
<p class="definition">Definition at line <a class="el" href="../../d3/d56/decrypt__config_8cc_source.html#l00012">12</a> of file <a class="el" href="../../d3/d56/decrypt__config_8cc_source.html">decrypt_config.cc</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="ab2dfe0a2ee285539843ac55b5f1ac7c7"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#ab2dfe0a2ee285539843ac55b5f1ac7c7">◆ </a></span>DecryptConfig() <span class="overload">[2/2]</span></h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">shaka::media::DecryptConfig::DecryptConfig </td>
|
|
<td>(</td>
|
|
<td class="paramtype">const std::vector< uint8_t > & </td>
|
|
<td class="paramname"><em>key_id</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">const std::vector< uint8_t > & </td>
|
|
<td class="paramname"><em>iv</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">const std::vector< <a class="el" href="../../d1/d34/structshaka_1_1media_1_1SubsampleEntry.html">SubsampleEntry</a> > & </td>
|
|
<td class="paramname"><em>subsamples</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">FourCC </td>
|
|
<td class="paramname"><em>protection_scheme</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">uint8_t </td>
|
|
<td class="paramname"><em>crypt_byte_block</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">uint8_t </td>
|
|
<td class="paramname"><em>skip_byte_block</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
<p>Create a general decrypt config with possible pattern-based encryption. </p><dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">key_id</td><td>is the ID that references the decryption key. </td></tr>
|
|
<tr><td class="paramname">iv</td><td>is the initialization vector defined by the encryptor. </td></tr>
|
|
<tr><td class="paramname">subsamples</td><td>defines the clear and encrypted portions of the sample as described in <a class="el" href="../../d1/d34/structshaka_1_1media_1_1SubsampleEntry.html">SubsampleEntry</a>. A decrypted buffer will be equal in size to the sum of the subsample sizes. </td></tr>
|
|
<tr><td class="paramname">protection_scheme</td><td>specifies the protection scheme: 'cenc', 'cens', 'cbc1', 'cbcs'. </td></tr>
|
|
<tr><td class="paramname">crypt_byte_block</td><td>indicates number of encrypted blocks (16-byte) in pattern based encryption, 'cens' and 'cbcs'. Ignored otherwise. </td></tr>
|
|
<tr><td class="paramname">skip_byte_block</td><td>indicates number of unencrypted blocks (16-byte) in pattern based encryption, 'cens' and 'cbcs'. Ignored otherwise. </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
|
|
<p class="definition">Definition at line <a class="el" href="../../d3/d56/decrypt__config_8cc_source.html#l00017">17</a> of file <a class="el" href="../../d3/d56/decrypt__config_8cc_source.html">decrypt_config.cc</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<h2 class="groupheader">Member Function Documentation</h2>
|
|
<a id="a36681ecf1eeb8a4effb0f00b232bda58"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#a36681ecf1eeb8a4effb0f00b232bda58">◆ </a></span>AddSubsample()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="mlabels">
|
|
<tr>
|
|
<td class="mlabels-left">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">void shaka::media::DecryptConfig::AddSubsample </td>
|
|
<td>(</td>
|
|
<td class="paramtype">uint16_t </td>
|
|
<td class="paramname"><em>clear_bytes</em>, </td>
|
|
</tr>
|
|
<tr>
|
|
<td class="paramkey"></td>
|
|
<td></td>
|
|
<td class="paramtype">uint32_t </td>
|
|
<td class="paramname"><em>cipher_bytes</em> </td>
|
|
</tr>
|
|
<tr>
|
|
<td></td>
|
|
<td>)</td>
|
|
<td></td><td></td>
|
|
</tr>
|
|
</table>
|
|
</td>
|
|
<td class="mlabels-right">
|
|
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
<dl class="params"><dt>Parameters</dt><dd>
|
|
<table class="params">
|
|
<tr><td class="paramname">clear_bytes</td><td>is the size of clear bytes in the subsample to be added. </td></tr>
|
|
<tr><td class="paramname">cipher_bytes</td><td>is the size of cipher bytes in the subsample to be added. </td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
|
|
<p class="definition">Definition at line <a class="el" href="../../df/dad/decrypt__config_8h_source.html#l00080">80</a> of file <a class="el" href="../../df/dad/decrypt__config_8h_source.html">decrypt_config.h</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<a id="af01188eb9ea205e60f992f32fe2f4a11"></a>
|
|
<h2 class="memtitle"><span class="permalink"><a href="#af01188eb9ea205e60f992f32fe2f4a11">◆ </a></span>GetTotalSizeOfSubsamples()</h2>
|
|
|
|
<div class="memitem">
|
|
<div class="memproto">
|
|
<table class="memname">
|
|
<tr>
|
|
<td class="memname">size_t shaka::media::DecryptConfig::GetTotalSizeOfSubsamples </td>
|
|
<td>(</td>
|
|
<td class="paramname"></td><td>)</td>
|
|
<td> const</td>
|
|
</tr>
|
|
</table>
|
|
</div><div class="memdoc">
|
|
<dl class="section return"><dt>Returns</dt><dd>The total size of subsamples. </dd></dl>
|
|
|
|
<p class="definition">Definition at line <a class="el" href="../../d3/d56/decrypt__config_8cc_source.html#l00034">34</a> of file <a class="el" href="../../d3/d56/decrypt__config_8cc_source.html">decrypt_config.cc</a>.</p>
|
|
|
|
</div>
|
|
</div>
|
|
<hr/>The documentation for this class was generated from the following files:<ul>
|
|
<li>packager/media/base/<a class="el" href="../../df/dad/decrypt__config_8h_source.html">decrypt_config.h</a></li>
|
|
<li>packager/media/base/<a class="el" href="../../d3/d56/decrypt__config_8cc_source.html">decrypt_config.cc</a></li>
|
|
</ul>
|
|
</div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated on Tue Jun 22 2021 00:16:05 for Shaka Packager SDK by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="../../doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.17
|
|
</small></address>
|
|
</body>
|
|
</html>
|