Update content of files

This commit is contained in:
GitHub Action 2023-12-09 19:16:24 +00:00
parent 63bf5f9afc
commit 252c91e311
34 changed files with 599 additions and 345 deletions

View file

@ -142,6 +142,8 @@
<p>Bots can install attachment menu entries, offering conveniently accessible, versatile mini apps.</p>
<h4><a class="anchor" href="#stories" id="stories" name="stories"><i class="anchor-icon"></i></a><a href="/api/stories">Stories</a></h4>
<p>Telegram users and channels can easily post and view <a href="https://telegram.org/blog/stories">stories</a> through the API.</p>
<h4><a class="anchor" href="#accent-colors" id="accent-colors" name="accent-colors"><i class="anchor-icon"></i></a><a href="/api/colors">Accent colors</a></h4>
<p>Telegram users and channels can change the accent color and background pattern of their profile page and their messages!</p>
<h4><a class="anchor" href="#privacy-settings" id="privacy-settings" name="privacy-settings"><i class="anchor-icon"></i></a><a href="/api/privacy">Privacy settings</a></h4>
<p>Telegram allows users to specify granular privacy settings, choosing which users can or can't interact with them in certain ways.</p>
<h4><a class="anchor" href="#search-amp-filters" id="search-amp-filters" name="search-amp-filters"><i class="anchor-icon"></i></a><a href="/api/search">Search &amp; filters</a></h4>

View file

@ -142,6 +142,8 @@
<p>Bots can install attachment menu entries, offering conveniently accessible, versatile mini apps.</p>
<h4><a class="anchor" href="#stories" id="stories" name="stories"><i class="anchor-icon"></i></a><a href="/api/stories">Stories</a></h4>
<p>Telegram users and channels can easily post and view <a href="https://telegram.org/blog/stories">stories</a> through the API.</p>
<h4><a class="anchor" href="#accent-colors" id="accent-colors" name="accent-colors"><i class="anchor-icon"></i></a><a href="/api/colors">Accent colors</a></h4>
<p>Telegram users and channels can change the accent color and background pattern of their profile page and their messages!</p>
<h4><a class="anchor" href="#privacy-settings" id="privacy-settings" name="privacy-settings"><i class="anchor-icon"></i></a><a href="/api/privacy">Privacy settings</a></h4>
<p>Telegram allows users to specify granular privacy settings, choosing which users can or can't interact with them in certain ways.</p>
<h4><a class="anchor" href="#search-amp-filters" id="search-amp-filters" name="search-amp-filters"><i class="anchor-icon"></i></a><a href="/api/search">Search &amp; filters</a></h4>

View file

@ -166,9 +166,9 @@
<li>Added <a href="/method/payments.applyGiftCode">payments.applyGiftCode</a> - </li>
<li>Added <a href="/method/payments.getGiveawayInfo">payments.getGiveawayInfo</a> - </li>
<li>Added <a href="/method/payments.launchPrepaidGiveaway">payments.launchPrepaidGiveaway</a> - </li>
<li>Added <a href="/method/account.updateColor">account.updateColor</a> - </li>
<li>Added <a href="/method/channels.updateColor">channels.updateColor</a> - </li>
<li>Added <a href="/method/account.getDefaultBackgroundEmojis">account.getDefaultBackgroundEmojis</a> - </li>
<li>Added <a href="/method/account.updateColor">account.updateColor</a> - Update the <a href="/api/colors">accent color and background custom emoji »</a> of the current account.</li>
<li>Added <a href="/method/channels.updateColor">channels.updateColor</a> - Update the <a href="/api/colors">accent color and background custom emoji »</a> of a channel.</li>
<li>Added <a href="/method/account.getDefaultBackgroundEmojis">account.getDefaultBackgroundEmojis</a> - Get a set of suggested <a href="/api/custom-emoji">custom emoji stickers</a> that can be used in an <a href="/api/colors">accent color pattern</a>.</li>
<li>Added <a href="/method/premium.getBoostsList">premium.getBoostsList</a> - </li>
<li>Added <a href="/method/premium.getMyBoosts">premium.getMyBoosts</a> - </li>
<li>Added <a href="/method/premium.applyBoost">premium.applyBoost</a> - </li>

View file

@ -234,14 +234,16 @@
<p>Telegram users and channels can easily post and view stories through the API.</p>
<h4><a class="anchor" href="#blocklist" id="blocklist" name="blocklist"><i class="anchor-icon"></i></a><a href="/api/block">Blocklist</a></h4>
<p>Working with the blocklist.</p>
<h4><a class="anchor" href="#messagessetchatwallpaper" id="messagessetchatwallpaper" name="messagessetchatwallpaper"><i class="anchor-icon"></i></a><a href="/method/messages.setChatWallPaper">messages.setChatWallPaper</a></h4>
<p>Set a custom <a href="/api/wallpapers">wallpaper »</a> in a specific private chat with another user.</p>
<h4><a class="anchor" href="#wallpapers" id="wallpapers" name="wallpapers"><i class="anchor-icon"></i></a><a href="/api/wallpapers">Wallpapers</a></h4>
<p>Telegram apps support generating, sharing and synchronizing chat backgrounds.</p>
<h4><a class="anchor" href="#pinned-messages" id="pinned-messages" name="pinned-messages"><i class="anchor-icon"></i></a><a href="/api/pin">Pinned messages</a></h4>
<p>Telegram allows pinning multiple messages on top of a specific chat.</p>
<h4><a class="anchor" href="#folders" id="folders" name="folders"><i class="anchor-icon"></i></a><a href="/api/folders">Folders</a></h4>
<p>Telegram allows placing chats into folders, based on their type, mute status, or other custom criteria, thanks to folder blacklists and whitelists.</p>
<h4><a class="anchor" href="#admin-banned-default-rights" id="admin-banned-default-rights" name="admin-banned-default-rights"><i class="anchor-icon"></i></a><a href="/api/rights">Admin, banned, default rights</a></h4>
<p>How to handle admin permissions, granular bans and global permissions in channels, groups and supergroups.</p>
<h4><a class="anchor" href="#wallpapers" id="wallpapers" name="wallpapers"><i class="anchor-icon"></i></a><a href="/api/wallpapers">Wallpapers</a></h4>
<p>Telegram apps support generating, sharing and synchronizing chat backgrounds.</p></div>
<p>How to handle admin permissions, granular bans and global permissions in channels, groups and supergroups.</p></div>
</div>

View file

@ -4,28 +4,10 @@
<meta charset="utf-8">
<title>account.getDefaultBackgroundEmojis</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta property="description" content="Parameters
Name
Type
Description
hash
long
Hash for pagination, for more info click here
Result
EmojiList
Bots can use…">
<meta property="description" content="Get a set of suggested custom emoji stickers that can be used in an accent color pattern.">
<meta property="og:title" content="account.getDefaultBackgroundEmojis">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
Name
Type
Description
hash
long
Hash for pagination, for more info click here
Result
EmojiList
Bots can use…">
<meta property="og:description" content="Get a set of suggested custom emoji stickers that can be used in an accent color pattern.">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -60,7 +42,8 @@ Bots can use…">
<div class="dev_page_bread_crumbs"><ul class="breadcrumb clearfix"><li><a href="/api" >API</a></li><i class="icon icon-breadcrumb-divider"></i><li><a href="/methods" >All Methods</a></li><i class="icon icon-breadcrumb-divider"></i><li><a href="/method/account.getDefaultBackgroundEmojis" >account.getDefaultBackgroundEmojis</a></li></ul></div>
<h1 id="dev_page_title">account.getDefaultBackgroundEmojis</h1>
<div id="dev_page_content"><p><div class="clearfix">
<div id="dev_page_content"><p>Get a set of suggested <a href="/api/custom-emoji">custom emoji stickers</a> that can be used in an <a href="/api/colors">accent color pattern</a>.</p>
<p><div class="clearfix">
<ul class="dev_layer_select slightly-pull-right nav nav-pills">
<li class="dropdown">
<a class="dropdown-toggle" onclick="return dropdownClick(this, event)" href="#">Layer 167 <b class="caret"></b></a>
@ -95,10 +78,13 @@ Bots can use…">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/EmojiList">EmojiList</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#pagination-in-the-api" id="pagination-in-the-api" name="pagination-in-the-api"><i class="anchor-icon"></i></a><a href="/api/offsets">Pagination in the API</a></h4>
<p>How to fetch results from large lists of objects.</p></div>
<p>How to fetch results from large lists of objects.</p>
<h4><a class="anchor" href="#custom-emojis" id="custom-emojis" name="custom-emojis"><i class="anchor-icon"></i></a><a href="/api/custom-emoji">Custom emojis</a></h4>
<p>Telegram allows including animated and static custom emojis inside of messages.</p>
<h4><a class="anchor" href="#accent-colors" id="accent-colors" name="accent-colors"><i class="anchor-icon"></i></a><a href="/api/colors">Accent colors</a></h4>
<p>Telegram users and channels can change the accent color and background pattern of their profile page and their messages!</p></div>
</div>

View file

@ -4,32 +4,10 @@
<meta charset="utf-8">
<title>account.updateColor</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta property="description" content="Parameters
Name
Type
Description
flags
#
Flags, see TL conditional fields
for_profile
flags.1?true
 
color
flags.2?int…">
<meta property="description" content="Update the accent color and background custom emoji » of the current account.">
<meta property="og:title" content="account.updateColor">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
Name
Type
Description
flags
#
Flags, see TL conditional fields
for_profile
flags.1?true
 
color
flags.2?int…">
<meta property="og:description" content="Update the accent color and background custom emoji » of the current account.">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -64,7 +42,8 @@ flags.2?int…">
<div class="dev_page_bread_crumbs"><ul class="breadcrumb clearfix"><li><a href="/api" >API</a></li><i class="icon icon-breadcrumb-divider"></i><li><a href="/methods" >All Methods</a></li><i class="icon icon-breadcrumb-divider"></i><li><a href="/method/account.updateColor" >account.updateColor</a></li></ul></div>
<h1 id="dev_page_title">account.updateColor</h1>
<div id="dev_page_content"><p><div class="clearfix">
<div id="dev_page_content"><p>Update the <a href="/api/colors">accent color and background custom emoji »</a> of the current account.</p>
<p><div class="clearfix">
<ul class="dev_layer_select slightly-pull-right nav nav-pills">
<li class="dropdown">
<a class="dropdown-toggle" onclick="return dropdownClick(this, event)" href="#">Layer 167 <b class="caret"></b></a>
@ -98,23 +77,42 @@ flags.2?int…">
<tr>
<td><strong>for_profile</strong></td>
<td style="text-align: center;"><a href="/mtproto/TL-combinators#conditional-fields">flags</a>.1?<a href="/constructor/true">true</a></td>
<td> </td>
<td>Whether to change the accent color emoji pattern of the profile page; otherwise, the accent color and emoji pattern of messages will be changed.</td>
</tr>
<tr>
<td><strong>color</strong></td>
<td style="text-align: center;"><a href="/mtproto/TL-combinators#conditional-fields">flags</a>.2?<a href="/type/int">int</a></td>
<td> </td>
<td><a href="/api/colors">ID of the accent color palette »</a> to use (not RGB24, see <a href="/api/colors">here »</a> for more info).</td>
</tr>
<tr>
<td><strong>background_emoji_id</strong></td>
<td style="text-align: center;"><a href="/mtproto/TL-combinators#conditional-fields">flags</a>.0?<a href="/type/long">long</a></td>
<td> </td>
<td>Custom emoji ID used in the accent color pattern.</td>
</tr>
</tbody>
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/Bool">Bool</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>COLOR_INVALID</td>
<td> </td>
</tr>
</tbody>
</table>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#accent-colors" id="accent-colors" name="accent-colors"><i class="anchor-icon"></i></a><a href="/api/colors">Accent colors</a></h4>
<p>Telegram users and channels can change the accent color and background pattern of their profile page and their messages!</p></div>
</div>

View file

@ -104,6 +104,11 @@
</thead>
<tbody>
<tr>
<td>406</td>
<td>BANNED_RIGHTS_INVALID</td>
<td>You provided some invalid flags in the banned rights.</td>
</tr>
<tr>
<td>400</td>
<td>CHANNEL_INVALID</td>
<td>The provided channel is invalid.</td>

View file

@ -13,7 +13,11 @@ InputChannel
 
Result
messages.Chats
Bots can use this method">
Possible errors
Code
Type
Description
400…">
<meta property="og:title" content="channels.getChannelRecommendations">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -25,7 +29,11 @@ InputChannel
 
Result
messages.Chats
Bots can use this method">
Possible errors
Code
Type
Description
400…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -95,7 +103,23 @@ Bots can use this method">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/messages.Chats">messages.Chats</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>CHANNEL_INVALID</td>
<td>The provided channel is invalid.</td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -16,7 +16,10 @@ Bool
 
Result
Updates
Bots can use this method">
Possible errors
Code
Type
Description…">
<meta property="og:title" content="channels.toggleViewForumAsMessages">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -31,7 +34,10 @@ Bool
 
Result
Updates
Bots can use this method">
Possible errors
Code
Type
Description…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -111,7 +117,23 @@ Bots can use this method">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/Updates">Updates</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>CHANNEL_INVALID</td>
<td>The provided channel is invalid.</td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -4,36 +4,10 @@
<meta charset="utf-8">
<title>channels.updateColor</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta property="description" content="Parameters
Name
Type
Description
flags
#
Flags, see TL conditional fields
channel
InputChannel
 
color
int
 
background_emoji_id…">
<meta property="description" content="Update the accent color and background custom emoji » of a channel.">
<meta property="og:title" content="channels.updateColor">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
Name
Type
Description
flags
#
Flags, see TL conditional fields
channel
InputChannel
 
color
int
 
background_emoji_id…">
<meta property="og:description" content="Update the accent color and background custom emoji » of a channel.">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -68,7 +42,8 @@ background_emoji_id…">
<div class="dev_page_bread_crumbs"><ul class="breadcrumb clearfix"><li><a href="/api" >API</a></li><i class="icon icon-breadcrumb-divider"></i><li><a href="/methods" >All Methods</a></li><i class="icon icon-breadcrumb-divider"></i><li><a href="/method/channels.updateColor" >channels.updateColor</a></li></ul></div>
<h1 id="dev_page_title">channels.updateColor</h1>
<div id="dev_page_content"><p><div class="clearfix">
<div id="dev_page_content"><p>Update the <a href="/api/colors">accent color and background custom emoji »</a> of a channel.</p>
<p><div class="clearfix">
<ul class="dev_layer_select slightly-pull-right nav nav-pills">
<li class="dropdown">
<a class="dropdown-toggle" onclick="return dropdownClick(this, event)" href="#">Layer 167 <b class="caret"></b></a>
@ -107,23 +82,49 @@ background_emoji_id…">
<tr>
<td><strong>channel</strong></td>
<td style="text-align: center;"><a href="/type/InputChannel">InputChannel</a></td>
<td> </td>
<td>Channel whose accent color should be changed.</td>
</tr>
<tr>
<td><strong>color</strong></td>
<td style="text-align: center;"><a href="/type/int">int</a></td>
<td> </td>
<td><a href="/api/colors">ID of the accent color palette »</a> to use (not RGB24, see <a href="/api/colors">here »</a> for more info).</td>
</tr>
<tr>
<td><strong>background_emoji_id</strong></td>
<td style="text-align: center;"><a href="/mtproto/TL-combinators#conditional-fields">flags</a>.0?<a href="/type/long">long</a></td>
<td> </td>
<td>Custom emoji ID used in the accent color pattern.</td>
</tr>
</tbody>
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/Updates">Updates</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>BOOSTS_REQUIRED</td>
<td>The specified channel must first be <a href="/api/boost">boosted by its users</a> in order to be able to post stories.</td>
</tr>
<tr>
<td>400</td>
<td>CHANNEL_INVALID</td>
<td>The provided channel is invalid.</td>
</tr>
</tbody>
</table>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#accent-colors" id="accent-colors" name="accent-colors"><i class="anchor-icon"></i></a><a href="/api/colors">Accent colors</a></h4>
<p>Telegram users and channels can change the accent color and background pattern of their profile page and their messages!</p>
<h4><a class="anchor" href="#channel-boosts" id="channel-boosts" name="channel-boosts"><i class="anchor-icon"></i></a><a href="/api/boost">Channel boosts</a></h4>
<p>Telegram Premium users can grant their favorite channels additional features like the ability to post stories by giving them boosts.</p></div>
</div>

View file

@ -13,7 +13,7 @@ int
Hash for pagination, for more info click here
Result
help.PeerColors
Bots can…">
Related…">
<meta property="og:title" content="help.getPeerColors">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -25,7 +25,7 @@ int
Hash for pagination, for more info click here
Result
help.PeerColors
Bots can…">
Related…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -95,7 +95,6 @@ Bots can…">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/help.PeerColors">help.PeerColors</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#pagination-in-the-api" id="pagination-in-the-api" name="pagination-in-the-api"><i class="anchor-icon"></i></a><a href="/api/offsets">Pagination in the API</a></h4>
<p>How to fetch results from large lists of objects.</p></div>

View file

@ -13,7 +13,7 @@ int
Hash for pagination, for more info click here
Result
help.PeerColors
Bots can…">
Related…">
<meta property="og:title" content="help.getPeerProfileColors">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -25,7 +25,7 @@ int
Hash for pagination, for more info click here
Result
help.PeerColors
Bots can…">
Related…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -95,7 +95,6 @@ Bots can…">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/help.PeerColors">help.PeerColors</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#pagination-in-the-api" id="pagination-in-the-api" name="pagination-in-the-api"><i class="anchor-icon"></i></a><a href="/api/offsets">Pagination in the API</a></h4>
<p>How to fetch results from large lists of objects.</p></div>

View file

@ -118,7 +118,6 @@ hash…">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/messages.FoundStickerSets">messages.FoundStickerSets</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#pagination-in-the-api" id="pagination-in-the-api" name="pagination-in-the-api"><i class="anchor-icon"></i></a><a href="/api/offsets">Pagination in the API</a></h4>
<p>How to fetch results from large lists of objects.</p></div>

View file

@ -170,6 +170,11 @@
<tbody>
<tr>
<td>400</td>
<td>ADMIN_RIGHTS_EMPTY</td>
<td> </td>
</tr>
<tr>
<td>400</td>
<td>BOT_DOMAIN_INVALID</td>
<td>Bot domain invalid.</td>
</tr>

View file

@ -4,10 +4,10 @@
<meta charset="utf-8">
<title>messages.sendReaction</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta property="description" content="React to message.">
<meta property="description" content="React to message. Starting from layer 159, the reaction will be sent from the peer specified using messages.saveDefaultSendAs.">
<meta property="og:title" content="messages.sendReaction">
<meta property="og:image" content="">
<meta property="og:description" content="React to message.">
<meta property="og:description" content="React to message. Starting from layer 159, the reaction will be sent from the peer specified using messages.saveDefaultSendAs.">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -141,6 +141,11 @@
</tr>
<tr>
<td>400</td>
<td>CUSTOM_REACTIONS_TOO_MANY</td>
<td> </td>
</tr>
<tr>
<td>400</td>
<td>MESSAGE_ID_INVALID</td>
<td>The provided message id is invalid.</td>
</tr>

View file

@ -133,10 +133,17 @@
<td>WALLPAPER_INVALID</td>
<td>The specified wallpaper is invalid.</td>
</tr>
<tr>
<td>400</td>
<td>WALLPAPER_NOT_FOUND</td>
<td> </td>
</tr>
</tbody>
</table>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#telegram-premium" id="telegram-premium" name="telegram-premium"><i class="anchor-icon"></i></a><a href="/api/premium">Telegram Premium</a></h4>
<p>Telegram Premium is an optional subscription service that unlocks additional exclusive client-side and API-side features, while helping support the development of the app.</p>
<h4><a class="anchor" href="#wallpapers" id="wallpapers" name="wallpapers"><i class="anchor-icon"></i></a><a href="/api/wallpapers">Wallpapers</a></h4>
<p>Telegram apps support generating, sharing and synchronizing chat backgrounds.</p>
<h4><a class="anchor" href="#messageactionsetchatwallpaper" id="messageactionsetchatwallpaper" name="messageactionsetchatwallpaper"><i class="anchor-icon"></i></a><a href="/constructor/messageActionSetChatWallPaper">messageActionSetChatWallPaper</a></h4>

View file

@ -13,7 +13,12 @@ string
 
Result
Updates
Bots can use this method">
Possible errors
Code
Type
Description
406
GIFTCODE_NOT_ALLOWED…">
<meta property="og:title" content="payments.applyGiftCode">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -25,7 +30,12 @@ string
 
Result
Updates
Bots can use this method">
Possible errors
Code
Type
Description
406
GIFTCODE_NOT_ALLOWED…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -100,7 +110,23 @@ Bots can use this method">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/Updates">Updates</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>406</td>
<td>GIFTCODE_NOT_ALLOWED</td>
<td> </td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -13,7 +13,11 @@ string
 
Result
payments.CheckedGiftCode
Bots can use this method">
Possible errors
Code
Type
Description
400…">
<meta property="og:title" content="payments.checkGiftCode">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -25,7 +29,11 @@ string
 
Result
payments.CheckedGiftCode
Bots can use this method">
Possible errors
Code
Type
Description
400…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -94,7 +102,23 @@ Bots can use this method">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/payments.CheckedGiftCode">payments.CheckedGiftCode</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>GIFT_SLUG_INVALID</td>
<td> </td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -16,7 +16,10 @@ int
 
Result
payments.GiveawayInfo
Bots can use this method">
Possible errors
Code
Type
Description…">
<meta property="og:title" content="payments.getGiveawayInfo">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -31,7 +34,10 @@ int
 
Result
payments.GiveawayInfo
Bots can use this method">
Possible errors
Code
Type
Description…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -106,7 +112,23 @@ Bots can use this method">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/payments.GiveawayInfo">payments.GiveawayInfo</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>PEER_ID_INVALID</td>
<td>The provided peer id is invalid.</td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -101,8 +101,7 @@ Vector…">
</tbody>
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/Vector%20t">Vector</a>&lt;<a href="/type/PremiumGiftCodeOption">PremiumGiftCodeOption</a>&gt;</p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<p><a href="/type/Vector%20t">Vector</a>&lt;<a href="/type/PremiumGiftCodeOption">PremiumGiftCodeOption</a>&gt;</p></div>
</div>

View file

@ -120,7 +120,23 @@ Updates…">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/Updates">Updates</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>PEER_ID_INVALID</td>
<td>The provided peer id is invalid.</td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -110,7 +110,23 @@ InputPeer
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/premium.MyBoosts">premium.MyBoosts</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>PEER_ID_INVALID</td>
<td>The provided peer id is invalid.</td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -122,7 +122,23 @@ offset…">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/premium.BoostsList">premium.BoostsList</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>PEER_ID_INVALID</td>
<td>The provided peer id is invalid.</td>
</tr>
</tbody>
</table>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#pagination-in-the-api" id="pagination-in-the-api" name="pagination-in-the-api"><i class="anchor-icon"></i></a><a href="/api/offsets">Pagination in the API</a></h4>
<p>How to fetch results from large lists of objects.</p></div>

View file

@ -13,7 +13,11 @@ InputPeer
 
Result
premium.BoostsStatus
Bots can use this method">
Possible errors
Code
Type
Description
400…">
<meta property="og:title" content="premium.getBoostsStatus">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -25,7 +29,11 @@ InputPeer
 
Result
premium.BoostsStatus
Bots can use this method">
Possible errors
Code
Type
Description
400…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -94,7 +102,23 @@ Bots can use this method">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/premium.BoostsStatus">premium.BoostsStatus</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>PEER_ID_INVALID</td>
<td>The provided peer id is invalid.</td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -7,15 +7,13 @@
<meta property="description" content="Parameters
This constructor does not require any parameters.
Result
premium.MyBoosts
Bots can use this method">
premium.MyBoosts">
<meta property="og:title" content="premium.getMyBoosts">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
This constructor does not require any parameters.
Result
premium.MyBoosts
Bots can use this method">
premium.MyBoosts">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -68,8 +66,7 @@ Bots can use this method">
<h3><a class="anchor" href="#parameters" id="parameters" name="parameters"><i class="anchor-icon"></i></a>Parameters</h3>
<p>This constructor does not require any parameters.</p>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/premium.MyBoosts">premium.MyBoosts</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<p><a href="/type/premium.MyBoosts">premium.MyBoosts</a></p></div>
</div>

View file

@ -16,7 +16,9 @@ InputUser
 
Result
premium.BoostsList
Bots can use this method">
Possible errors
Code
Type…">
<meta property="og:title" content="premium.getUserBoosts">
<meta property="og:image" content="">
<meta property="og:description" content="Parameters
@ -31,7 +33,9 @@ InputUser
 
Result
premium.BoostsList
Bots can use this method">
Possible errors
Code
Type…">
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
@ -105,6 +109,23 @@ Bots can use this method">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/premium.BoostsList">premium.BoostsList</a></p>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>PEER_ID_INVALID</td>
<td>The provided peer id is invalid.</td>
</tr>
</tbody>
</table>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
</div>

View file

@ -121,7 +121,23 @@ Maximum number of results to return…">
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/stats.PublicForwards">stats.PublicForwards</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>PEER_ID_INVALID</td>
<td>The provided peer id is invalid.</td>
</tr>
</tbody>
</table>
<h3><a class="anchor" href="#related-pages" id="related-pages" name="related-pages"><i class="anchor-icon"></i></a>Related pages</h3>
<h4><a class="anchor" href="#pagination-in-the-api" id="pagination-in-the-api" name="pagination-in-the-api"><i class="anchor-icon"></i></a><a href="/api/offsets">Pagination in the API</a></h4>
<p>How to fetch results from large lists of objects.</p></div>

View file

@ -121,7 +121,23 @@ int
</table>
<h3><a class="anchor" href="#result" id="result" name="result"><i class="anchor-icon"></i></a>Result</h3>
<p><a href="/type/stats.StoryStats">stats.StoryStats</a></p>
<h3><a class="anchor" href="#bots-can-use-this-method" id="bots-can-use-this-method" name="bots-can-use-this-method"><i class="anchor-icon"></i></a>Bots can use this method</h3></div>
<h3><a class="anchor" href="#possible-errors" id="possible-errors" name="possible-errors"><i class="anchor-icon"></i></a>Possible errors</h3>
<table class="table">
<thead>
<tr>
<th>Code</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>400</td>
<td>PEER_ID_INVALID</td>
<td>The provided peer id is invalid.</td>
</tr>
</tbody>
</table></div>
</div>

View file

@ -93,6 +93,11 @@
<tbody>
<tr>
<td>400</td>
<td>AES_DECRYPT_FAILED</td>
<td> </td>
</tr>
<tr>
<td>400</td>
<td>CDN_METHOD_INVALID</td>
<td>You can't call this method in a CDN DC.</td>
</tr>

View file

@ -3000,15 +3000,15 @@ Look for updates of telegram&#39;s terms of service…">
</tr>
<tr>
<td><a href="/method/account.updateColor">account.updateColor</a></td>
<td> </td>
<td>Update the <a href="/api/colors">accent color and background custom emoji »</a> of the current account.</td>
</tr>
<tr>
<td><a href="/method/channels.updateColor">channels.updateColor</a></td>
<td> </td>
<td>Update the <a href="/api/colors">accent color and background custom emoji »</a> of a channel.</td>
</tr>
<tr>
<td><a href="/method/account.getDefaultBackgroundEmojis">account.getDefaultBackgroundEmojis</a></td>
<td> </td>
<td>Get a set of suggested <a href="/api/custom-emoji">custom emoji stickers</a> that can be used in an <a href="/api/colors">accent color pattern</a>.</td>
</tr>
<tr>
<td><a href="/method/premium.getBoostsList">premium.getBoostsList</a></td>

View file

@ -53,9 +53,9 @@
<h5><a class="anchor" href="#1-client-sends-query-to-server" id="1-client-sends-query-to-server" name="1-client-sends-query-to-server"><i class="anchor-icon"></i></a>1) Client sends query to server</h5>
<!-- start req_pq_multi -->
<p>Sent payload (excluding transport headers/trailers):</p>
<pre><code>0000 | 00 00 00 00 00 00 00 00 24 8F 02 00 B6 30 72 65
0010 | 14 00 00 00 F1 8E 7E BE A0 C3 6E 98 B7 E1 6B 63
0020 | D0 EF D6 D1 F3 3D 86 13</code></pre>
<pre><code>0000 | 00 00 00 00 00 00 00 00 C4 03 0F 00 3A BB 74 65
0010 | 14 00 00 00 F1 8E 7E BE 12 D2 52 A6 52 49 2F 98
0020 | B3 E7 AC 76 FE FA 89 A4</code></pre>
<p>Payload (de)serialization:</p>
<pre><code>req_pq_multi#be7e8ef1 nonce:int128 = ResPQ;</code></pre>
<table class="table">
@ -77,7 +77,7 @@
<tr>
<td>message_id</td>
<td>8, 8</td>
<td><code>248F0200B6307265</code></td>
<td><code>C4030F003ABB7465</code></td>
<td>Message ID generated as specified <a href="/mtproto/description#message-identifier-msg-id">here »</a> (unixtime() &lt;&lt; 32) + (N*4)</td>
</tr>
<tr>
@ -95,7 +95,7 @@
<tr>
<td>nonce</td>
<td>24, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Random number</td>
</tr>
</tbody>
@ -104,11 +104,11 @@
<h5><a class="anchor" href="#2-server-sends-response-of-the-form" id="2-server-sends-response-of-the-form" name="2-server-sends-response-of-the-form"><i class="anchor-icon"></i></a>2) Server sends response of the form</h5>
<!-- start resPQ -->
<p>Received payload (excluding transport headers/trailers):</p>
<pre><code>0000 | 00 00 00 00 00 00 00 00 01 18 39 A7 B6 30 72 65
0010 | 7C 00 00 00 63 24 16 05 A0 C3 6E 98 B7 E1 6B 63
0020 | D0 EF D6 D1 F3 3D 86 13 A2 00 C9 D3 74 62 9E 4C
0030 | D5 8D 79 8C FF AC 07 F8 08 14 B3 5F 13 6D 99 AF
0040 | C5 00 00 00 15 C4 B5 1C 03 00 00 00 A5 B7 F7 09
<pre><code>0000 | 00 00 00 00 00 00 00 00 01 38 F3 23 3A BB 74 65
0010 | 58 00 00 00 63 24 16 05 12 D2 52 A6 52 49 2F 98
0020 | B3 E7 AC 76 FE FA 89 A4 6C E7 5A 07 8D 3B DA EC
0030 | 6C D2 D6 3A D8 67 9D DA 08 23 8D 10 D1 5D AC AD
0040 | 17 00 00 00 15 C4 B5 1C 03 00 00 00 A5 B7 F7 09
0050 | 35 5F C3 0B 21 6B E8 6C 02 2B B4 C3 85 FD 64 DE
0060 | 85 1D 9D D0</code></pre>
<p>Payload (de)serialization:</p>
@ -132,13 +132,13 @@
<tr>
<td>message_id</td>
<td>8, 8</td>
<td><code>011839A7B6307265</code></td>
<td><code>0138F3233ABB7465</code></td>
<td>Message ID generated as specified <a href="/mtproto/description#message-identifier-msg-id">here »</a> (unixtime() &lt;&lt; 32) + (N*4)</td>
</tr>
<tr>
<td>message_length</td>
<td>16, 4</td>
<td><code>7C000000</code> (124 in decimal)</td>
<td><code>58000000</code> (88 in decimal)</td>
<td>Message body length</td>
</tr>
<tr>
@ -150,19 +150,19 @@
<tr>
<td>nonce</td>
<td>24, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Value generated by client in Step 1</td>
</tr>
<tr>
<td>server_nonce</td>
<td>40, 16</td>
<td><code>A200C9D374629E4CD58D798CFFAC07F8</code></td>
<td><code>6CE75A078D3BDAEC6CD2D63AD8679DDA</code></td>
<td>Server-generated random number</td>
</tr>
<tr>
<td>pq</td>
<td>56, 12</td>
<td><code>0814B35F136D99AFC5000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1491640438637572037</td>
<td><code>08238D10D15DACAD17000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 2561722254449487127</td>
<td>Single-byte prefix denoting length, an 8-byte string, and three bytes of padding</td>
</tr>
<tr>
@ -208,22 +208,22 @@
<h4><a class="anchor" href="#proof-of-work" id="proof-of-work" name="proof-of-work"><i class="anchor-icon"></i></a>Proof of work</h4>
<h5><a class="anchor" href="#3-client-decomposes-pq-into-prime-factors-such-that-p-lt-q" id="3-client-decomposes-pq-into-prime-factors-such-that-p-lt-q" name="3-client-decomposes-pq-into-prime-factors-such-that-p-lt-q"><i class="anchor-icon"></i></a>3) Client decomposes pq into prime factors such that p &lt; q.</h5>
<!-- start pq -->
<pre><code>pq = 1491640438637572037</code></pre>
<p>Decompose into 2 prime cofactors <code>p &lt; q</code>: <code>1491640438637572037 = 1127944757 * 1322441041</code></p>
<pre><code>p = 1127944757
q = 1322441041</code></pre>
<pre><code>pq = 2561722254449487127</code></pre>
<p>Decompose into 2 prime cofactors <code>p &lt; q</code>: <code>2561722254449487127 = 1530421979 * 1673866613</code></p>
<pre><code>p = 1530421979
q = 1673866613</code></pre>
<!-- end pq -->
<h4><a class="anchor" href="#presenting-proof-of-work-server-authentication" id="presenting-proof-of-work-server-authentication" name="presenting-proof-of-work-server-authentication"><i class="anchor-icon"></i></a>Presenting proof of work; Server authentication</h4>
<h5><a class="anchor" href="#4-encrypted-data-payload-generation" id="4-encrypted-data-payload-generation" name="4-encrypted-data-payload-generation"><i class="anchor-icon"></i></a>4) <code>encrypted_data</code> payload generation</h5>
<p>First of all, generate an <code>encrypted_data</code> payload as follows:</p>
<!-- start p_q_inner_data_dc -->
<p>Generated payload (excluding transport headers/trailers):</p>
<pre><code>0000 | 95 5F F5 A9 08 14 B3 5F 13 6D 99 AF C5 00 00 00
0010 | 04 43 3B 12 35 00 00 00 04 4E D2 D9 51 00 00 00
0020 | A0 C3 6E 98 B7 E1 6B 63 D0 EF D6 D1 F3 3D 86 13
0030 | A2 00 C9 D3 74 62 9E 4C D5 8D 79 8C FF AC 07 F8
0040 | 33 D0 B6 D0 C3 ED 1F 0D 74 2D 9E F6 12 3F CE 0E
0050 | 1E 77 47 EE 6F 2B 65 01 6A EE 3E 3E B4 72 1C 57
<pre><code>0000 | 95 5F F5 A9 08 23 8D 10 D1 5D AC AD 17 00 00 00
0010 | 04 5B 38 62 DB 00 00 00 04 63 C5 2D 75 00 00 00
0020 | 12 D2 52 A6 52 49 2F 98 B3 E7 AC 76 FE FA 89 A4
0030 | 6C E7 5A 07 8D 3B DA EC 6C D2 D6 3A D8 67 9D DA
0040 | 56 01 8F A1 6B 1D 5A C2 AC 60 C6 0E A7 BB AD A5
0050 | EE 4A 6B BB 2B 6B 0C 29 F9 63 7F 1E EB DC 02 C9
0060 | 02 00 00 00</code></pre>
<p>Payload (de)serialization:</p>
<pre><code>p_q_inner_data_dc#a9f55f95 pq:string p:string q:string nonce:int128 server_nonce:int128 new_nonce:int256 dc:int = P_Q_inner_data;</code></pre>
@ -246,37 +246,37 @@ q = 1322441041</code></pre>
<tr>
<td>pq</td>
<td>4, 12</td>
<td><code>0814B35F136D99AFC5000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1491640438637572037</td>
<td><code>08238D10D15DACAD17000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 2561722254449487127</td>
<td>Single-byte prefix denoting length, 8-byte string, and three bytes of padding</td>
</tr>
<tr>
<td>p</td>
<td>16, 8</td>
<td><code>04433B1235000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1127944757</td>
<td><code>045B3862DB000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1530421979</td>
<td>First prime cofactor: single-byte prefix denoting length, 4-byte string, and three bytes of padding</td>
</tr>
<tr>
<td>q</td>
<td>24, 8</td>
<td><code>044ED2D951000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1322441041</td>
<td><code>0463C52D75000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1673866613</td>
<td>Second prime cofactor: single-byte prefix denoting length, 4-byte string, and three bytes of padding</td>
</tr>
<tr>
<td>nonce</td>
<td>32, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Value generated by client in Step 1</td>
</tr>
<tr>
<td>server_nonce</td>
<td>48, 16</td>
<td><code>A200C9D374629E4CD58D798CFFAC07F8</code></td>
<td><code>6CE75A078D3BDAEC6CD2D63AD8679DDA</code></td>
<td>Value received from server in Step 2</td>
</tr>
<tr>
<td>new_nonce</td>
<td>64, 32</td>
<td><code>33D0B6D0C3ED1F0D742D9EF6123FCE0E</code> <code>1E7747EE6F2B65016AEE3E3EB4721C57</code></td>
<td><code>56018FA16B1D5AC2AC60C60EA7BBADA5</code> <code>EE4A6BBB2B6B0C29F9637F1EEBDC02C9</code></td>
<td>Client-generated random number</td>
</tr>
<tr>
@ -291,39 +291,39 @@ q = 1322441041</code></pre>
<p>The serialization of <em>P_Q_inner_data</em> produces <strong>data</strong>, which is used to generate <strong>encrypted_data</strong> as specified in <a href="/mtproto/auth_key">step 4.1</a>.<br>
These are the inputs to the algorithm specified in <a href="/mtproto/auth_key">step 4.1</a>:</p>
<!-- start p_q_inner_data_input -->
<pre><code>data = 955FF5A90814B35F136D99AFC500000004433B1235000000044ED2D951000000A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F833D0B6D0C3ED1F0D742D9EF6123FCE0E1E7747EE6F2B65016AEE3E3EB4721C5702000000
random_padding_bytes = 28DA166BE2BFD1D84C9BD4D719D550AA6332D0C3BCFF2780E1060BB1ABB2DB2EF96842F478D13BE8607FB461DAAB03756634B5FE4380E111077D06C91F457314DC37A961CB38AC604526DA8F81C20A012122BC455EC145C1ED65C291</code></pre>
<pre><code>data = 955FF5A908238D10D15DACAD17000000045B3862DB0000000463C52D7500000012D252A652492F98B3E7AC76FEFA89A46CE75A078D3BDAEC6CD2D63AD8679DDA56018FA16B1D5AC2AC60C60EA7BBADA5EE4A6BBB2B6B0C29F9637F1EEBDC02C902000000
random_padding_bytes = 979109065C19335B68C0906AA669492BBDFD4930CC44A561EBA8470770E00BC833E64F4F78733CAB274365CE300CCB3103E3AC9B43E9FC026A98F7728E00628A953690E761A9EE10B9A984B34B0DBCF2BC8DAB15E91A6EEC9BFD8D25</code></pre>
<!-- end p_q_inner_data_input -->
<p>And this is the output:</p>
<!-- start p_q_inner_data_output -->
<pre><code>encrypted_data = 94F50A0AD58828AB86B062DF2F395A6C78243F78D1BC7AC2549E7F3E53E85459E31BC077150335984BFB8FAE8EEA5A8723B6B5C41EB7F892D47A86410519DC4B4F97F1DCF596FB4439366CD33154E2A02DFFE14F93792E708D070FD3505F80FA3892ECBCA4A71C32930D62946F907B1A573965497DE25B82BC48350F4430E5D9B45A1EB8D647914BF3CC148AB7015575F30676302DA808FC167BEF26F4FC1E0C6C68AB3486CAC0F54BB62E9AEB8230D6946E805EF30EA407023DB50A319B5AF06F81C844C1600001E8C8B90719976B1684D185C2DCA609042C3BE1CB47CD546C1FDE6FA6DB0C3D4A8D168FC132F01D8F00141974C3DD1D98DEA8C137E1B14219</code></pre>
<pre><code>encrypted_data = D9CBB19DB9128A9A39832DD1E904E38D4C2B2BF8C713736FDEFA3C340FA2186DC41B66E51C0B99FA9B1DFFA40293E7FCFFD10AF21ADBB21BAEF77C9DD103C39B26F7BB15C57D5384CE3686397318C3D6711259300DB30095160DC84A3B06AD8F491EB226861A9D01F8C4C8C846C0E4789CB023CD2AE265C175B5A0F9BE446CBD66FB11A9AF59DE03065EFE98D3F99D6DCC6DB0E2D37271D12B78F98F7D38DFF35CC7B4DEABFED8272E0D4C72736118263DE2EEE60641C36969B23D3678E9009DE7CF410AE85706937C520319474C39648FB8F7BD37EE85F71CFFB880EA17880EF99DE262E9D5F405FD1998F689B44BFBF4F8DEBA3B0B0190A7C642883D623EE9</code></pre>
<!-- end p_q_inner_data_output -->
<p>The length of the final string is 256 bytes.</p>
<h5><a class="anchor" href="#5-send-req-dh-params-query-with-generated-encrypted-data" id="5-send-req-dh-params-query-with-generated-encrypted-data" name="5-send-req-dh-params-query-with-generated-encrypted-data"><i class="anchor-icon"></i></a>5) Send req_DH_params query with generated <code>encrypted_data</code></h5>
<!-- start req_DH_params -->
<p>Sent payload (excluding transport headers/trailers):</p>
<pre><code>0000 | 00 00 00 00 00 00 00 00 28 8F 02 00 B6 30 72 65
0010 | 40 01 00 00 BE E4 12 D7 A0 C3 6E 98 B7 E1 6B 63
0020 | D0 EF D6 D1 F3 3D 86 13 A2 00 C9 D3 74 62 9E 4C
0030 | D5 8D 79 8C FF AC 07 F8 04 43 3B 12 35 00 00 00
0040 | 04 4E D2 D9 51 00 00 00 85 FD 64 DE 85 1D 9D D0
0050 | FE 00 01 00 94 F5 0A 0A D5 88 28 AB 86 B0 62 DF
0060 | 2F 39 5A 6C 78 24 3F 78 D1 BC 7A C2 54 9E 7F 3E
0070 | 53 E8 54 59 E3 1B C0 77 15 03 35 98 4B FB 8F AE
0080 | 8E EA 5A 87 23 B6 B5 C4 1E B7 F8 92 D4 7A 86 41
0090 | 05 19 DC 4B 4F 97 F1 DC F5 96 FB 44 39 36 6C D3
00A0 | 31 54 E2 A0 2D FF E1 4F 93 79 2E 70 8D 07 0F D3
00B0 | 50 5F 80 FA 38 92 EC BC A4 A7 1C 32 93 0D 62 94
00C0 | 6F 90 7B 1A 57 39 65 49 7D E2 5B 82 BC 48 35 0F
00D0 | 44 30 E5 D9 B4 5A 1E B8 D6 47 91 4B F3 CC 14 8A
00E0 | B7 01 55 75 F3 06 76 30 2D A8 08 FC 16 7B EF 26
00F0 | F4 FC 1E 0C 6C 68 AB 34 86 CA C0 F5 4B B6 2E 9A
0100 | EB 82 30 D6 94 6E 80 5E F3 0E A4 07 02 3D B5 0A
0110 | 31 9B 5A F0 6F 81 C8 44 C1 60 00 01 E8 C8 B9 07
0120 | 19 97 6B 16 84 D1 85 C2 DC A6 09 04 2C 3B E1 CB
0130 | 47 CD 54 6C 1F DE 6F A6 DB 0C 3D 4A 8D 16 8F C1
0140 | 32 F0 1D 8F 00 14 19 74 C3 DD 1D 98 DE A8 C1 37
0150 | E1 B1 42 19</code></pre>
<pre><code>0000 | 00 00 00 00 00 00 00 00 C8 03 0F 00 3A BB 74 65
0010 | 40 01 00 00 BE E4 12 D7 12 D2 52 A6 52 49 2F 98
0020 | B3 E7 AC 76 FE FA 89 A4 6C E7 5A 07 8D 3B DA EC
0030 | 6C D2 D6 3A D8 67 9D DA 04 5B 38 62 DB 00 00 00
0040 | 04 63 C5 2D 75 00 00 00 85 FD 64 DE 85 1D 9D D0
0050 | FE 00 01 00 D9 CB B1 9D B9 12 8A 9A 39 83 2D D1
0060 | E9 04 E3 8D 4C 2B 2B F8 C7 13 73 6F DE FA 3C 34
0070 | 0F A2 18 6D C4 1B 66 E5 1C 0B 99 FA 9B 1D FF A4
0080 | 02 93 E7 FC FF D1 0A F2 1A DB B2 1B AE F7 7C 9D
0090 | D1 03 C3 9B 26 F7 BB 15 C5 7D 53 84 CE 36 86 39
00A0 | 73 18 C3 D6 71 12 59 30 0D B3 00 95 16 0D C8 4A
00B0 | 3B 06 AD 8F 49 1E B2 26 86 1A 9D 01 F8 C4 C8 C8
00C0 | 46 C0 E4 78 9C B0 23 CD 2A E2 65 C1 75 B5 A0 F9
00D0 | BE 44 6C BD 66 FB 11 A9 AF 59 DE 03 06 5E FE 98
00E0 | D3 F9 9D 6D CC 6D B0 E2 D3 72 71 D1 2B 78 F9 8F
00F0 | 7D 38 DF F3 5C C7 B4 DE AB FE D8 27 2E 0D 4C 72
0100 | 73 61 18 26 3D E2 EE E6 06 41 C3 69 69 B2 3D 36
0110 | 78 E9 00 9D E7 CF 41 0A E8 57 06 93 7C 52 03 19
0120 | 47 4C 39 64 8F B8 F7 BD 37 EE 85 F7 1C FF B8 80
0130 | EA 17 88 0E F9 9D E2 62 E9 D5 F4 05 FD 19 98 F6
0140 | 89 B4 4B FB F4 F8 DE BA 3B 0B 01 90 A7 C6 42 88
0150 | 3D 62 3E E9</code></pre>
<p>Payload (de)serialization:</p>
<pre><code>req_DH_params#d712e4be nonce:int128 server_nonce:int128 p:string q:string public_key_fingerprint:long encrypted_data:string = Server_DH_Params;</code></pre>
<table class="table">
@ -345,7 +345,7 @@ random_padding_bytes = 28DA166BE2BFD1D84C9BD4D719D550AA6332D0C3BCFF2780E1060BB1A
<tr>
<td>message_id</td>
<td>8, 8</td>
<td><code>288F0200B6307265</code></td>
<td><code>C8030F003ABB7465</code></td>
<td>Message ID generated as specified <a href="/mtproto/description#message-identifier-msg-id">here »</a> (unixtime() &lt;&lt; 32) + (N*4)</td>
</tr>
<tr>
@ -363,25 +363,25 @@ random_padding_bytes = 28DA166BE2BFD1D84C9BD4D719D550AA6332D0C3BCFF2780E1060BB1A
<tr>
<td>nonce</td>
<td>24, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Value generated by client in Step 1</td>
</tr>
<tr>
<td>server_nonce</td>
<td>40, 16</td>
<td><code>A200C9D374629E4CD58D798CFFAC07F8</code></td>
<td><code>6CE75A078D3BDAEC6CD2D63AD8679DDA</code></td>
<td>Value received from server in Step 2</td>
</tr>
<tr>
<td>p</td>
<td>56, 8</td>
<td><code>04433B1235000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1127944757</td>
<td><code>045B3862DB000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1530421979</td>
<td>First prime cofactor: single-byte prefix denoting length, 4-byte string, and three bytes of padding</td>
</tr>
<tr>
<td>q</td>
<td>64, 8</td>
<td><code>044ED2D951000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1322441041</td>
<td><code>0463C52D75000000</code><br>TL byte deserialization <br>=&gt; bigendian conversion to decimal<br>=&gt; 1673866613</td>
<td>Second prime cofactor: single-byte prefix denoting length, 4-byte string, and three bytes of padding</td>
</tr>
<tr>
@ -393,7 +393,7 @@ random_padding_bytes = 28DA166BE2BFD1D84C9BD4D719D550AA6332D0C3BCFF2780E1060BB1A
<tr>
<td>encrypted_data</td>
<td>80, 260</td>
<td><code>FE00010094F50A0AD58828AB86B062DF</code> <code>2F395A6C78243F78D1BC7AC2549E7F3E</code> <code>53E85459E31BC077150335984BFB8FAE</code> <code>8EEA5A8723B6B5C41EB7F892D47A8641</code> <code>0519DC4B4F97F1DCF596FB4439366CD3</code> <code>3154E2A02DFFE14F93792E708D070FD3</code> <code>505F80FA3892ECBCA4A71C32930D6294</code> <code>6F907B1A573965497DE25B82BC48350F</code> <code>4430E5D9B45A1EB8D647914BF3CC148A</code> <code>B7015575F30676302DA808FC167BEF26</code> <code>F4FC1E0C6C68AB3486CAC0F54BB62E9A</code> <code>EB8230D6946E805EF30EA407023DB50A</code> <code>319B5AF06F81C844C1600001E8C8B907</code> <code>19976B1684D185C2DCA609042C3BE1CB</code> <code>47CD546C1FDE6FA6DB0C3D4A8D168FC1</code> <code>32F01D8F00141974C3DD1D98DEA8C137</code><br> <code>E1B14219</code></td>
<td><code>FE000100D9CBB19DB9128A9A39832DD1</code> <code>E904E38D4C2B2BF8C713736FDEFA3C34</code> <code>0FA2186DC41B66E51C0B99FA9B1DFFA4</code> <code>0293E7FCFFD10AF21ADBB21BAEF77C9D</code> <code>D103C39B26F7BB15C57D5384CE368639</code> <code>7318C3D6711259300DB30095160DC84A</code> <code>3B06AD8F491EB226861A9D01F8C4C8C8</code> <code>46C0E4789CB023CD2AE265C175B5A0F9</code> <code>BE446CBD66FB11A9AF59DE03065EFE98</code> <code>D3F99D6DCC6DB0E2D37271D12B78F98F</code> <code>7D38DFF35CC7B4DEABFED8272E0D4C72</code> <code>736118263DE2EEE60641C36969B23D36</code> <code>78E9009DE7CF410AE85706937C520319</code> <code>474C39648FB8F7BD37EE85F71CFFB880</code> <code>EA17880EF99DE262E9D5F405FD1998F6</code> <code>89B44BFBF4F8DEBA3B0B0190A7C64288</code><br> <code>3D623EE9</code></td>
<td>Value generated above</td>
</tr>
</tbody>
@ -402,47 +402,47 @@ random_padding_bytes = 28DA166BE2BFD1D84C9BD4D719D550AA6332D0C3BCFF2780E1060BB1A
<h5><a class="anchor" href="#6-server-responds-with" id="6-server-responds-with" name="6-server-responds-with"><i class="anchor-icon"></i></a>6) Server responds with:</h5>
<!-- start server_DH_params_ok -->
<p>Received payload (excluding transport headers/trailers):</p>
<pre><code>0000 | 00 00 00 00 00 00 00 00 01 14 3E 65 B7 30 72 65
0010 | BC 02 00 00 5C 07 E8 D0 A0 C3 6E 98 B7 E1 6B 63
0020 | D0 EF D6 D1 F3 3D 86 13 A2 00 C9 D3 74 62 9E 4C
0030 | D5 8D 79 8C FF AC 07 F8 FE 50 02 00 1E DF 50 2B
0040 | 9A DF 93 F3 B8 EA 3A 69 E4 63 4E A6 3D B5 C9 54
0050 | A0 AC E4 E5 7B 21 99 15 9F 19 25 11 FC 0A F1 CB
0060 | 38 D5 B5 53 1C 28 49 ED BE 22 54 34 E0 E8 89 96
0070 | 19 72 58 78 0D 7B F9 C9 FA D8 5A 50 EA F1 29 62
0080 | 34 13 1B 4B FA 7D D2 1E F9 93 E6 70 5D 28 D5 B6
0090 | 52 4B 93 BE 2B 26 D7 1C 4C 81 0C B5 D5 D2 B5 5F
00A0 | EC CD 8B 8C 10 04 2C E4 C4 A6 E7 38 B8 C5 FB 89
00B0 | 89 51 47 08 39 FF 64 A8 E2 2B 90 15 51 32 49 D7
00C0 | 70 55 35 C9 84 33 86 A3 7F 98 EA 36 64 B3 FD C7
00D0 | DE 68 C6 C9 9A 93 0B FE C5 29 AA B3 86 DA 2D F6
00E0 | 78 0F D1 2F 07 A1 02 A6 20 C8 75 E2 47 7C C7 40
00F0 | D3 F5 C4 F0 DA D3 AF 6E E0 79 3A 4A F4 55 C6 7C
0100 | 39 3A 15 AF AE 6A 93 20 60 16 9E 09 B7 DB 67 24
0110 | 96 C6 12 F2 56 61 B0 76 2C F4 43 D8 61 B3 E2 3C
0120 | 01 B4 86 2C FC 9D 0C 98 76 38 42 BA DF 16 79 A7
0130 | F1 43 48 06 16 3F 98 D9 9B 7E D0 E1 AA 11 F5 CC
0140 | AF 23 92 3F A1 D0 DD 69 5C D3 CF F6 A1 41 2F 39
0150 | E0 53 64 46 C4 8A 86 28 AE 8F C0 13 2F 8D 11 1C
0160 | C8 15 B5 AD C5 C5 0E 0A 27 2B 4A F8 D4 47 84 A3
0170 | 13 DE A9 5A 05 30 4A 69 D0 51 46 B6 A2 8C 85 B4
0180 | 09 EC FE 65 4C 3D ED 85 A7 47 A8 DC BC 38 00 7B
0190 | 46 9A 40 3E 06 91 88 40 30 E5 CF 69 93 0A 6A 2F
01A0 | A6 AC CB 01 6C 25 82 EA 14 B4 FB 9A 96 22 C3 86
01B0 | D8 6E 18 B3 F4 14 2F 73 DE E3 73 21 EE 21 78 B9
01C0 | 4C FC A7 89 35 CF EA 0D FE 04 FF 20 22 EC AE 8B
01D0 | AB 7E F1 ED 2E FA 18 A6 75 F9 99 CE BF C5 86 EC
01E0 | 4A 74 A0 58 E5 77 2C 54 7F 6E E7 D3 45 B8 D5 BF
01F0 | E8 D6 E3 B9 81 39 90 09 E7 E1 34 92 C2 F6 D0 24
0200 | B5 C2 A8 7C 3C 13 72 16 0C 06 71 8D BD 5F 20 C9
0210 | 2F BE D5 FF 93 10 EB 1B 85 87 5D D3 A6 33 3B 7B
0220 | 4E BD 71 B1 AC 6F 4D B5 B5 76 F5 E6 B0 47 87 F4
0230 | D5 1D F6 23 F2 BB B1 90 49 AC 59 C8 E7 01 E3 F8
0240 | 64 0A 89 D6 BF 84 44 08 E4 6E 42 46 16 CE 8B 98
0250 | DB AC DE D3 D3 6F 91 DB 45 2F CC E9 B0 16 4D 5E
0260 | 2B 48 E4 18 46 56 B4 3D 3A F3 39 7D 4C 46 D5 38
0270 | 68 F2 9A F0 E6 29 5C 6B 80 32 92 EE BE 7A 91 E1
0280 | A7 29 84 3D 6D E2 2F B0 1F E7 48 CA</code></pre>
<pre><code>0000 | 00 00 00 00 00 00 00 00 01 FC D3 E6 3A BB 74 65
0010 | D4 02 00 00 5C 07 E8 D0 12 D2 52 A6 52 49 2F 98
0020 | B3 E7 AC 76 FE FA 89 A4 6C E7 5A 07 8D 3B DA EC
0030 | 6C D2 D6 3A D8 67 9D DA FE 50 02 00 0E 75 02 FC
0040 | 77 76 13 32 EB BF AC 5A 3D 6F 6B 79 99 5A AA 71
0050 | DD 7D DF 6E F7 4B 23 FE 72 2A D9 96 82 8F 85 28
0060 | 4A A7 6B BF 6D 58 60 51 BC 2E 7E 58 6A DE 76 A9
0070 | 80 E2 66 08 AF 09 E3 6C 83 95 BE 7F E1 E1 15 D2
0080 | 15 DD 16 52 2C 7D E8 84 E7 9D 47 01 BC 42 52 FB
0090 | 1E CC 75 53 23 9D 40 B8 3E 37 65 76 E3 DB 9B 26
00A0 | D2 D0 26 A4 91 33 F2 83 01 EC 76 0A ED 51 DF 08
00B0 | 2D BB 4F 3D 57 F5 30 E5 09 9B E9 51 7F E1 7E F1
00C0 | B7 E8 37 B6 F9 6D E4 E0 7A 24 C2 E5 97 6D 91 83
00D0 | CB 9C 0A 0D 56 26 B2 73 A0 C9 F3 CA CB D2 2F 3E
00E0 | 37 E9 74 84 4D 35 A6 D0 A3 99 AE 18 75 66 1D 08
00F0 | 4D E9 02 00 9B 36 58 1E 9A 26 9A 80 55 0E A8 2A
0100 | D1 DA CD C1 7C 9D 45 DD 64 A4 32 05 4C 67 7B D7
0110 | D8 A2 2B F5 5B 5E 42 26 40 E8 4A 41 DE 8F 32 89
0120 | 6F CB 28 EC 95 8B 6A 72 68 68 FA 50 95 1D 8A 79
0130 | AE C5 AE B8 79 8C 5C D2 F2 FD 23 14 BD 42 B6 FE
0140 | C5 89 C0 40 87 F9 0C 97 94 1F EA 8A F6 6A 7C D2
0150 | 10 B9 A5 46 2C 1C 73 40 39 9D 5B 14 6D BB 57 FC
0160 | 24 4D D0 EF 86 71 68 11 72 2D F1 3B 1B E3 1B 1E
0170 | 73 DD 0F 7A 94 74 34 DF 9D 1F 62 C3 D1 32 1E 48
0180 | 65 29 1B A4 CF 9B 74 27 95 E6 E1 BA 2E 30 AA 46
0190 | 40 9F 20 E9 FE 72 7A 92 1D 0C C9 C5 8B A5 46 81
01A0 | 90 39 0D 43 8F CF 20 98 BD 8F 2D 11 55 0C 20 7D
01B0 | C0 85 63 C9 04 08 0E 8C B7 4F E9 93 61 9B 0A 7C
01C0 | 30 FD 58 C2 C5 88 01 90 FE 91 FA 35 2D 1D EF 76
01D0 | CB 3C 9E FD BD 7C 57 EF C7 B1 E7 06 27 D6 20 CC
01E0 | 85 DF F6 01 A0 10 6E 9D 9E EA A6 3F B4 6D BA 8E
01F0 | 06 5F 4E D0 3A F7 92 E9 68 F0 BF E6 BF 84 6F DD
0200 | 84 09 6A D4 E0 4F 3A 0E 29 94 B1 4C B8 53 9F 88
0210 | 1D 17 32 20 10 0E A3 90 F9 D0 4F 47 B5 B5 97 82
0220 | FA CB E1 B8 54 DA 20 53 E3 13 FA 7A B1 C8 18 04
0230 | 6F E5 5A 31 33 72 86 F2 F1 01 7A 9C 9B 80 8B 78
0240 | C7 21 AA B4 B3 DA AA B6 0C E7 70 D1 91 E9 8F 6E
0250 | 3B FB 69 0A 37 D0 65 11 C2 A4 06 0E 4A E2 25 68
0260 | 97 A0 29 E5 FB 57 99 20 84 BA 0C E2 15 96 CA 78
0270 | E9 8F E4 F3 C4 8A 4D 8C F4 F3 D7 67 DA 6B A0 DC
0280 | 0B F8 30 35 A8 21 D0 3E 0B 9E 26 91</code></pre>
<p>Payload (de)serialization:</p>
<pre><code>server_DH_params_ok#d0e8075c nonce:int128 server_nonce:int128 encrypted_answer:string = Server_DH_Params;</code></pre>
<table class="table">
@ -464,13 +464,13 @@ random_padding_bytes = 28DA166BE2BFD1D84C9BD4D719D550AA6332D0C3BCFF2780E1060BB1A
<tr>
<td>message_id</td>
<td>8, 8</td>
<td><code>01143E65B7307265</code></td>
<td><code>01FCD3E63ABB7465</code></td>
<td>Message ID generated as specified <a href="/mtproto/description#message-identifier-msg-id">here »</a> (unixtime() &lt;&lt; 32) + (N*4)</td>
</tr>
<tr>
<td>message_length</td>
<td>16, 4</td>
<td><code>BC020000</code> (700 in decimal)</td>
<td><code>D4020000</code> (724 in decimal)</td>
<td>Message body length</td>
</tr>
<tr>
@ -482,19 +482,19 @@ random_padding_bytes = 28DA166BE2BFD1D84C9BD4D719D550AA6332D0C3BCFF2780E1060BB1A
<tr>
<td>nonce</td>
<td>24, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Value generated by client in Step 1</td>
</tr>
<tr>
<td>server_nonce</td>
<td>40, 16</td>
<td><code>A200C9D374629E4CD58D798CFFAC07F8</code></td>
<td><code>6CE75A078D3BDAEC6CD2D63AD8679DDA</code></td>
<td>Value received from server in Step 2</td>
</tr>
<tr>
<td>encrypted_answer</td>
<td>56, 596</td>
<td><code>FE5002001EDF502B9ADF93F3B8EA3A69</code> <code>E4634EA63DB5C954A0ACE4E57B219915</code> <code>9F192511FC0AF1CB38D5B5531C2849ED</code> <code>BE225434E0E88996197258780D7BF9C9</code> <code>FAD85A50EAF1296234131B4BFA7DD21E</code> <code>F993E6705D28D5B6524B93BE2B26D71C</code> <code>4C810CB5D5D2B55FECCD8B8C10042CE4</code> <code>C4A6E738B8C5FB898951470839FF64A8</code> <code>E22B9015513249D7705535C9843386A3</code> <code>7F98EA3664B3FDC7DE68C6C99A930BFE</code> <code>C529AAB386DA2DF6780FD12F07A102A6</code> <code>20C875E2477CC740D3F5C4F0DAD3AF6E</code> <code>E0793A4AF455C67C393A15AFAE6A9320</code> <code>60169E09B7DB672496C612F25661B076</code> <code>2CF443D861B3E23C01B4862CFC9D0C98</code> <code>763842BADF1679A7F1434806163F98D9</code> <code>9B7ED0E1AA11F5CCAF23923FA1D0DD69</code> <code>5CD3CFF6A1412F39E0536446C48A8628</code> <code>AE8FC0132F8D111CC815B5ADC5C50E0A</code> <code>272B4AF8D44784A313DEA95A05304A69</code> <code>D05146B6A28C85B409ECFE654C3DED85</code> <code>A747A8DCBC38007B469A403E06918840</code> <code>30E5CF69930A6A2FA6ACCB016C2582EA</code> <code>14B4FB9A9622C386D86E18B3F4142F73</code> <code>DEE37321EE2178B94CFCA78935CFEA0D</code> <code>FE04FF2022ECAE8BAB7EF1ED2EFA18A6</code> <code>75F999CEBFC586EC4A74A058E5772C54</code> <code>7F6EE7D345B8D5BFE8D6E3B981399009</code> <code>E7E13492C2F6D024B5C2A87C3C137216</code> <code>0C06718DBD5F20C92FBED5FF9310EB1B</code> <code>85875DD3A6333B7B4EBD71B1AC6F4DB5</code> <code>B576F5E6B04787F4D51DF623F2BBB190</code> <code>49AC59C8E701E3F8640A89D6BF844408</code> <code>E46E424616CE8B98DBACDED3D36F91DB</code> <code>452FCCE9B0164D5E2B48E4184656B43D</code> <code>3AF3397D4C46D53868F29AF0E6295C6B</code> <code>803292EEBE7A91E1A729843D6DE22FB0</code><br> <code>1FE748CA</code></td>
<td><code>FE5002000E7502FC77761332EBBFAC5A</code> <code>3D6F6B79995AAA71DD7DDF6EF74B23FE</code> <code>722AD996828F85284AA76BBF6D586051</code> <code>BC2E7E586ADE76A980E26608AF09E36C</code> <code>8395BE7FE1E115D215DD16522C7DE884</code> <code>E79D4701BC4252FB1ECC7553239D40B8</code> <code>3E376576E3DB9B26D2D026A49133F283</code> <code>01EC760AED51DF082DBB4F3D57F530E5</code> <code>099BE9517FE17EF1B7E837B6F96DE4E0</code> <code>7A24C2E5976D9183CB9C0A0D5626B273</code> <code>A0C9F3CACBD22F3E37E974844D35A6D0</code> <code>A399AE1875661D084DE902009B36581E</code> <code>9A269A80550EA82AD1DACDC17C9D45DD</code> <code>64A432054C677BD7D8A22BF55B5E4226</code> <code>40E84A41DE8F32896FCB28EC958B6A72</code> <code>6868FA50951D8A79AEC5AEB8798C5CD2</code> <code>F2FD2314BD42B6FEC589C04087F90C97</code> <code>941FEA8AF66A7CD210B9A5462C1C7340</code> <code>399D5B146DBB57FC244DD0EF86716811</code> <code>722DF13B1BE31B1E73DD0F7A947434DF</code> <code>9D1F62C3D1321E4865291BA4CF9B7427</code> <code>95E6E1BA2E30AA46409F20E9FE727A92</code> <code>1D0CC9C58BA5468190390D438FCF2098</code> <code>BD8F2D11550C207DC08563C904080E8C</code> <code>B74FE993619B0A7C30FD58C2C5880190</code> <code>FE91FA352D1DEF76CB3C9EFDBD7C57EF</code> <code>C7B1E70627D620CC85DFF601A0106E9D</code> <code>9EEAA63FB46DBA8E065F4ED03AF792E9</code> <code>68F0BFE6BF846FDD84096AD4E04F3A0E</code> <code>2994B14CB8539F881D173220100EA390</code> <code>F9D04F47B5B59782FACBE1B854DA2053</code> <code>E313FA7AB1C818046FE55A31337286F2</code> <code>F1017A9C9B808B78C721AAB4B3DAAAB6</code> <code>0CE770D191E98F6E3BFB690A37D06511</code> <code>C2A4060E4AE2256897A029E5FB579920</code> <code>84BA0CE21596CA78E98FE4F3C48A4D8C</code> <code>F4F3D767DA6BA0DC0BF83035A821D03E</code><br> <code>0B9E2691</code></td>
<td>See below</td>
</tr>
</tbody>
@ -502,20 +502,20 @@ random_padding_bytes = 28DA166BE2BFD1D84C9BD4D719D550AA6332D0C3BCFF2780E1060BB1A
<!-- end server_DH_params_ok -->
<p>Decrypt <code>encrypted_answer</code> using the reverse of the process specified in <a href="/mtproto/auth_key#6-server-responds-with">step 6</a>:</p>
<!-- start server_DH_inner_data_input -->
<pre><code>encrypted_answer = 1EDF502B9ADF93F3B8EA3A69E4634EA63DB5C954A0ACE4E57B2199159F192511FC0AF1CB38D5B5531C2849EDBE225434E0E88996197258780D7BF9C9FAD85A50EAF1296234131B4BFA7DD21EF993E6705D28D5B6524B93BE2B26D71C4C810CB5D5D2B55FECCD8B8C10042CE4C4A6E738B8C5FB898951470839FF64A8E22B9015513249D7705535C9843386A37F98EA3664B3FDC7DE68C6C99A930BFEC529AAB386DA2DF6780FD12F07A102A620C875E2477CC740D3F5C4F0DAD3AF6EE0793A4AF455C67C393A15AFAE6A932060169E09B7DB672496C612F25661B0762CF443D861B3E23C01B4862CFC9D0C98763842BADF1679A7F1434806163F98D99B7ED0E1AA11F5CCAF23923FA1D0DD695CD3CFF6A1412F39E0536446C48A8628AE8FC0132F8D111CC815B5ADC5C50E0A272B4AF8D44784A313DEA95A05304A69D05146B6A28C85B409ECFE654C3DED85A747A8DCBC38007B469A403E0691884030E5CF69930A6A2FA6ACCB016C2582EA14B4FB9A9622C386D86E18B3F4142F73DEE37321EE2178B94CFCA78935CFEA0DFE04FF2022ECAE8BAB7EF1ED2EFA18A675F999CEBFC586EC4A74A058E5772C547F6EE7D345B8D5BFE8D6E3B981399009E7E13492C2F6D024B5C2A87C3C1372160C06718DBD5F20C92FBED5FF9310EB1B85875DD3A6333B7B4EBD71B1AC6F4DB5B576F5E6B04787F4D51DF623F2BBB19049AC59C8E701E3F8640A89D6BF844408E46E424616CE8B98DBACDED3D36F91DB452FCCE9B0164D5E2B48E4184656B43D3AF3397D4C46D53868F29AF0E6295C6B803292EEBE7A91E1A729843D6DE22FB01FE748CA
tmp_aes_key = C43503B78CE1A7EBA3BE3378B41644235F348455FD4004A102BAF4AB1E3DDE11
tmp_aes_iv = 43FA1673796D54629C3BECDC6C69C67115AB10D7261D57C3C94258F133D0B6D0</code></pre>
<pre><code>encrypted_answer = 0E7502FC77761332EBBFAC5A3D6F6B79995AAA71DD7DDF6EF74B23FE722AD996828F85284AA76BBF6D586051BC2E7E586ADE76A980E26608AF09E36C8395BE7FE1E115D215DD16522C7DE884E79D4701BC4252FB1ECC7553239D40B83E376576E3DB9B26D2D026A49133F28301EC760AED51DF082DBB4F3D57F530E5099BE9517FE17EF1B7E837B6F96DE4E07A24C2E5976D9183CB9C0A0D5626B273A0C9F3CACBD22F3E37E974844D35A6D0A399AE1875661D084DE902009B36581E9A269A80550EA82AD1DACDC17C9D45DD64A432054C677BD7D8A22BF55B5E422640E84A41DE8F32896FCB28EC958B6A726868FA50951D8A79AEC5AEB8798C5CD2F2FD2314BD42B6FEC589C04087F90C97941FEA8AF66A7CD210B9A5462C1C7340399D5B146DBB57FC244DD0EF86716811722DF13B1BE31B1E73DD0F7A947434DF9D1F62C3D1321E4865291BA4CF9B742795E6E1BA2E30AA46409F20E9FE727A921D0CC9C58BA5468190390D438FCF2098BD8F2D11550C207DC08563C904080E8CB74FE993619B0A7C30FD58C2C5880190FE91FA352D1DEF76CB3C9EFDBD7C57EFC7B1E70627D620CC85DFF601A0106E9D9EEAA63FB46DBA8E065F4ED03AF792E968F0BFE6BF846FDD84096AD4E04F3A0E2994B14CB8539F881D173220100EA390F9D04F47B5B59782FACBE1B854DA2053E313FA7AB1C818046FE55A31337286F2F1017A9C9B808B78C721AAB4B3DAAAB60CE770D191E98F6E3BFB690A37D06511C2A4060E4AE2256897A029E5FB57992084BA0CE21596CA78E98FE4F3C48A4D8CF4F3D767DA6BA0DC0BF83035A821D03E0B9E2691
tmp_aes_key = F97885237250E1E2923A564401F69AA32F283C7A9C3448965DAB36A9481EE649
tmp_aes_iv = 954D4B646A8170F6C46CD9F709B2E4203595359E5AA26C84DA8918FB56018FA1</code></pre>
<!-- end server_DH_inner_data_input -->
<p>Yielding:</p>
<!-- start server_DH_inner_data_output -->
<pre><code>answer_with_hash = FCBA013B9AB7707DDBE474642264DF8C59D8184ABA0D89B5A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F803000000FE000100C71CAEB9C6B1C9048E6C522F70F13F73980D40238E3E21C14934D037563D930F48198A0AA7C14058229493D22530F4DBFA336F6E0AC925139543AED44CCE7C3720FD51F69458705AC68CD4FE6B6B13ABDC9746512969328454F18FAF8C595F642477FE96BB2A941D5BCD1D4AC8CC49880708FA9B378E3C4F3A9060BEE67CF9A4A4A695811051907E162753B56B0F6B410DBA74D8A84B2A14B3144E0EF1284754FD17ED950D5965B4B9DD46582DB1178D169C6BC465B0D6FF9CA3928FEF5B9AE4E418FC15E83EBEA0F87FA9FF5EED70050DED2849F47BF959D956850CE929851F0D8115F635B105EE2E4E15D04B2454BF6F4FADF034B10403119CD8E3B92FCC5BFE000100787D5C24EF82C26B88AF34F63D7A6E68151281F9260D9670912BA1E1AE33E2841B5BFDA596A1D5EB7554E8D96716488CDF59FF4699597177E45C48AC1FFE29E63BD236FFC56223D0A5FCC3CAC21C93AA0EF1CA814D16729473A971DFBB6DC947A2DFF7E2DA1B55940CFED7A7080B3A5DE6D8C302F399617AD8BF12049852C2DCDC81B065461EC6106A2EF863283E1C79E8500BAE42B0B07773829BCAFF84FC70EED906615803FBD4940FDC0274939CD9D1797FC84B7685BB7CAF4F45FE50161079A448EF61C9104FDDBAAF0C191A4FA3A1EEB5C9C21AC28161CC439B3666E7FEB2D8D441601974665887C289DB016D81886EB9491001AF054383A02AF682FC2DB73072658886A4B98ACDD2B4
answer = BA0D89B5A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F803000000FE000100C71CAEB9C6B1C9048E6C522F70F13F73980D40238E3E21C14934D037563D930F48198A0AA7C14058229493D22530F4DBFA336F6E0AC925139543AED44CCE7C3720FD51F69458705AC68CD4FE6B6B13ABDC9746512969328454F18FAF8C595F642477FE96BB2A941D5BCD1D4AC8CC49880708FA9B378E3C4F3A9060BEE67CF9A4A4A695811051907E162753B56B0F6B410DBA74D8A84B2A14B3144E0EF1284754FD17ED950D5965B4B9DD46582DB1178D169C6BC465B0D6FF9CA3928FEF5B9AE4E418FC15E83EBEA0F87FA9FF5EED70050DED2849F47BF959D956850CE929851F0D8115F635B105EE2E4E15D04B2454BF6F4FADF034B10403119CD8E3B92FCC5BFE000100787D5C24EF82C26B88AF34F63D7A6E68151281F9260D9670912BA1E1AE33E2841B5BFDA596A1D5EB7554E8D96716488CDF59FF4699597177E45C48AC1FFE29E63BD236FFC56223D0A5FCC3CAC21C93AA0EF1CA814D16729473A971DFBB6DC947A2DFF7E2DA1B55940CFED7A7080B3A5DE6D8C302F399617AD8BF12049852C2DCDC81B065461EC6106A2EF863283E1C79E8500BAE42B0B07773829BCAFF84FC70EED906615803FBD4940FDC0274939CD9D1797FC84B7685BB7CAF4F45FE50161079A448EF61C9104FDDBAAF0C191A4FA3A1EEB5C9C21AC28161CC439B3666E7FEB2D8D441601974665887C289DB016D81886EB9491001AF054383A02AF682FC2DB73072658886A4B98ACDD2B4</code></pre>
<pre><code>answer_with_hash = A5EBFA70800CECFE974D1B3F5368C9C143740722BA0D89B512D252A652492F98B3E7AC76FEFA89A46CE75A078D3BDAEC6CD2D63AD8679DDA03000000FE000100C71CAEB9C6B1C9048E6C522F70F13F73980D40238E3E21C14934D037563D930F48198A0AA7C14058229493D22530F4DBFA336F6E0AC925139543AED44CCE7C3720FD51F69458705AC68CD4FE6B6B13ABDC9746512969328454F18FAF8C595F642477FE96BB2A941D5BCD1D4AC8CC49880708FA9B378E3C4F3A9060BEE67CF9A4A4A695811051907E162753B56B0F6B410DBA74D8A84B2A14B3144E0EF1284754FD17ED950D5965B4B9DD46582DB1178D169C6BC465B0D6FF9CA3928FEF5B9AE4E418FC15E83EBEA0F87FA9FF5EED70050DED2849F47BF959D956850CE929851F0D8115F635B105EE2E4E15D04B2454BF6F4FADF034B10403119CD8E3B92FCC5BFE000100347BE521229C862F6DE3FB2DA9ECE4F5D77B8BBD389E8AF45F2377C6E1D3F6ACE73A2EDD1F24F638DD52BB46ED8C470EE3338EECF830DD88E1F64D33F2B64009B9D3F2DBB3092F0B47B4812B14B3790DB994DD7E672D2878BAE02AAB806831384252993D4E9461AD4D81AFF85267ADBE55CD68FF074E59C0F47E801C091F0C407C35176F17C3A3C5606C47EA9EAE2065F1FAA6BE24CD6F0855EFE9FD6F2DEE69F826ACACE3E21A62F6D9812433247959E9E65265FC9BB398CA860C7244832D08EF37ABC298BE190C8051808235859652EE1E29512F17FD6881074049ECC5FD9B05F24F9808244B5440D6394E7FE4ADA0CA9659A0A94020B0BBA2E1F582BCD3333ABB7465A33090C42DAFA01F
answer = BA0D89B512D252A652492F98B3E7AC76FEFA89A46CE75A078D3BDAEC6CD2D63AD8679DDA03000000FE000100C71CAEB9C6B1C9048E6C522F70F13F73980D40238E3E21C14934D037563D930F48198A0AA7C14058229493D22530F4DBFA336F6E0AC925139543AED44CCE7C3720FD51F69458705AC68CD4FE6B6B13ABDC9746512969328454F18FAF8C595F642477FE96BB2A941D5BCD1D4AC8CC49880708FA9B378E3C4F3A9060BEE67CF9A4A4A695811051907E162753B56B0F6B410DBA74D8A84B2A14B3144E0EF1284754FD17ED950D5965B4B9DD46582DB1178D169C6BC465B0D6FF9CA3928FEF5B9AE4E418FC15E83EBEA0F87FA9FF5EED70050DED2849F47BF959D956850CE929851F0D8115F635B105EE2E4E15D04B2454BF6F4FADF034B10403119CD8E3B92FCC5BFE000100347BE521229C862F6DE3FB2DA9ECE4F5D77B8BBD389E8AF45F2377C6E1D3F6ACE73A2EDD1F24F638DD52BB46ED8C470EE3338EECF830DD88E1F64D33F2B64009B9D3F2DBB3092F0B47B4812B14B3790DB994DD7E672D2878BAE02AAB806831384252993D4E9461AD4D81AFF85267ADBE55CD68FF074E59C0F47E801C091F0C407C35176F17C3A3C5606C47EA9EAE2065F1FAA6BE24CD6F0855EFE9FD6F2DEE69F826ACACE3E21A62F6D9812433247959E9E65265FC9BB398CA860C7244832D08EF37ABC298BE190C8051808235859652EE1E29512F17FD6881074049ECC5FD9B05F24F9808244B5440D6394E7FE4ADA0CA9659A0A94020B0BBA2E1F582BCD3333ABB7465A33090C42DAFA01F</code></pre>
<!-- end server_DH_inner_data_output -->
<!-- start server_DH_inner_data -->
<p>Generated payload (excluding transport headers/trailers):</p>
<pre><code>0000 | BA 0D 89 B5 A0 C3 6E 98 B7 E1 6B 63 D0 EF D6 D1
0010 | F3 3D 86 13 A2 00 C9 D3 74 62 9E 4C D5 8D 79 8C
0020 | FF AC 07 F8 03 00 00 00 FE 00 01 00 C7 1C AE B9
<pre><code>0000 | BA 0D 89 B5 12 D2 52 A6 52 49 2F 98 B3 E7 AC 76
0010 | FE FA 89 A4 6C E7 5A 07 8D 3B DA EC 6C D2 D6 3A
0020 | D8 67 9D DA 03 00 00 00 FE 00 01 00 C7 1C AE B9
0030 | C6 B1 C9 04 8E 6C 52 2F 70 F1 3F 73 98 0D 40 23
0040 | 8E 3E 21 C1 49 34 D0 37 56 3D 93 0F 48 19 8A 0A
0050 | A7 C1 40 58 22 94 93 D2 25 30 F4 DB FA 33 6F 6E
@ -532,23 +532,23 @@ answer = BA0D89B5A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F
0100 | F4 7B F9 59 D9 56 85 0C E9 29 85 1F 0D 81 15 F6
0110 | 35 B1 05 EE 2E 4E 15 D0 4B 24 54 BF 6F 4F AD F0
0120 | 34 B1 04 03 11 9C D8 E3 B9 2F CC 5B FE 00 01 00
0130 | 78 7D 5C 24 EF 82 C2 6B 88 AF 34 F6 3D 7A 6E 68
0140 | 15 12 81 F9 26 0D 96 70 91 2B A1 E1 AE 33 E2 84
0150 | 1B 5B FD A5 96 A1 D5 EB 75 54 E8 D9 67 16 48 8C
0160 | DF 59 FF 46 99 59 71 77 E4 5C 48 AC 1F FE 29 E6
0170 | 3B D2 36 FF C5 62 23 D0 A5 FC C3 CA C2 1C 93 AA
0180 | 0E F1 CA 81 4D 16 72 94 73 A9 71 DF BB 6D C9 47
0190 | A2 DF F7 E2 DA 1B 55 94 0C FE D7 A7 08 0B 3A 5D
01A0 | E6 D8 C3 02 F3 99 61 7A D8 BF 12 04 98 52 C2 DC
01B0 | DC 81 B0 65 46 1E C6 10 6A 2E F8 63 28 3E 1C 79
01C0 | E8 50 0B AE 42 B0 B0 77 73 82 9B CA FF 84 FC 70
01D0 | EE D9 06 61 58 03 FB D4 94 0F DC 02 74 93 9C D9
01E0 | D1 79 7F C8 4B 76 85 BB 7C AF 4F 45 FE 50 16 10
01F0 | 79 A4 48 EF 61 C9 10 4F DD BA AF 0C 19 1A 4F A3
0200 | A1 EE B5 C9 C2 1A C2 81 61 CC 43 9B 36 66 E7 FE
0210 | B2 D8 D4 41 60 19 74 66 58 87 C2 89 DB 01 6D 81
0220 | 88 6E B9 49 10 01 AF 05 43 83 A0 2A F6 82 FC 2D
0230 | B7 30 72 65</code></pre>
0130 | 34 7B E5 21 22 9C 86 2F 6D E3 FB 2D A9 EC E4 F5
0140 | D7 7B 8B BD 38 9E 8A F4 5F 23 77 C6 E1 D3 F6 AC
0150 | E7 3A 2E DD 1F 24 F6 38 DD 52 BB 46 ED 8C 47 0E
0160 | E3 33 8E EC F8 30 DD 88 E1 F6 4D 33 F2 B6 40 09
0170 | B9 D3 F2 DB B3 09 2F 0B 47 B4 81 2B 14 B3 79 0D
0180 | B9 94 DD 7E 67 2D 28 78 BA E0 2A AB 80 68 31 38
0190 | 42 52 99 3D 4E 94 61 AD 4D 81 AF F8 52 67 AD BE
01A0 | 55 CD 68 FF 07 4E 59 C0 F4 7E 80 1C 09 1F 0C 40
01B0 | 7C 35 17 6F 17 C3 A3 C5 60 6C 47 EA 9E AE 20 65
01C0 | F1 FA A6 BE 24 CD 6F 08 55 EF E9 FD 6F 2D EE 69
01D0 | F8 26 AC AC E3 E2 1A 62 F6 D9 81 24 33 24 79 59
01E0 | E9 E6 52 65 FC 9B B3 98 CA 86 0C 72 44 83 2D 08
01F0 | EF 37 AB C2 98 BE 19 0C 80 51 80 82 35 85 96 52
0200 | EE 1E 29 51 2F 17 FD 68 81 07 40 49 EC C5 FD 9B
0210 | 05 F2 4F 98 08 24 4B 54 40 D6 39 4E 7F E4 AD A0
0220 | CA 96 59 A0 A9 40 20 B0 BB A2 E1 F5 82 BC D3 33
0230 | 3A BB 74 65</code></pre>
<p>Payload (de)serialization:</p>
<pre><code>server_DH_inner_data#b5890dba nonce:int128 server_nonce:int128 g:int dh_prime:string g_a:string server_time:int = Server_DH_inner_data;</code></pre>
<table class="table">
@ -570,13 +570,13 @@ answer = BA0D89B5A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F
<tr>
<td>nonce</td>
<td>4, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Value generated by client in Step 1</td>
</tr>
<tr>
<td>server_nonce</td>
<td>20, 16</td>
<td><code>A200C9D374629E4CD58D798CFFAC07F8</code></td>
<td><code>6CE75A078D3BDAEC6CD2D63AD8679DDA</code></td>
<td>Value received from server in Step 2</td>
</tr>
<tr>
@ -594,13 +594,13 @@ answer = BA0D89B5A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F
<tr>
<td>g_a</td>
<td>300, 260</td>
<td><code>FE000100787D5C24EF82C26B88AF34F6</code> <code>3D7A6E68151281F9260D9670912BA1E1</code> <code>AE33E2841B5BFDA596A1D5EB7554E8D9</code> <code>6716488CDF59FF4699597177E45C48AC</code> <code>1FFE29E63BD236FFC56223D0A5FCC3CA</code> <code>C21C93AA0EF1CA814D16729473A971DF</code> <code>BB6DC947A2DFF7E2DA1B55940CFED7A7</code> <code>080B3A5DE6D8C302F399617AD8BF1204</code> <code>9852C2DCDC81B065461EC6106A2EF863</code> <code>283E1C79E8500BAE42B0B07773829BCA</code> <code>FF84FC70EED906615803FBD4940FDC02</code> <code>74939CD9D1797FC84B7685BB7CAF4F45</code> <code>FE50161079A448EF61C9104FDDBAAF0C</code> <code>191A4FA3A1EEB5C9C21AC28161CC439B</code> <code>3666E7FEB2D8D441601974665887C289</code> <code>DB016D81886EB9491001AF054383A02A</code><br> <code>F682FC2D</code></td>
<td><code>FE000100347BE521229C862F6DE3FB2D</code> <code>A9ECE4F5D77B8BBD389E8AF45F2377C6</code> <code>E1D3F6ACE73A2EDD1F24F638DD52BB46</code> <code>ED8C470EE3338EECF830DD88E1F64D33</code> <code>F2B64009B9D3F2DBB3092F0B47B4812B</code> <code>14B3790DB994DD7E672D2878BAE02AAB</code> <code>806831384252993D4E9461AD4D81AFF8</code> <code>5267ADBE55CD68FF074E59C0F47E801C</code> <code>091F0C407C35176F17C3A3C5606C47EA</code> <code>9EAE2065F1FAA6BE24CD6F0855EFE9FD</code> <code>6F2DEE69F826ACACE3E21A62F6D98124</code> <code>33247959E9E65265FC9BB398CA860C72</code> <code>44832D08EF37ABC298BE190C80518082</code> <code>35859652EE1E29512F17FD6881074049</code> <code>ECC5FD9B05F24F9808244B5440D6394E</code> <code>7FE4ADA0CA9659A0A94020B0BBA2E1F5</code><br> <code>82BCD333</code></td>
<td><code>g_a</code> diffie-hellman parameter</td>
</tr>
<tr>
<td>server_time</td>
<td>560, 4</td>
<td><code>B7307265</code> (1701982391 in decimal)</td>
<td><code>3ABB7465</code> (1702148922 in decimal)</td>
<td>Server time</td>
</tr>
</tbody>
@ -609,34 +609,34 @@ answer = BA0D89B5A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F
<h5><a class="anchor" href="#7-client-computes-random-2048-bit-number-b-using-a-sufficient-amount-of-entropy-and-sends-the-server-a-message" id="7-client-computes-random-2048-bit-number-b-using-a-sufficient-amount-of-entropy-and-sends-the-server-a-message" name="7-client-computes-random-2048-bit-number-b-using-a-sufficient-amount-of-entropy-and-sends-the-server-a-message"><i class="anchor-icon"></i></a>7) Client computes random 2048-bit number <em>b</em> (using a sufficient amount of entropy) and sends the server a message</h5>
<p>First, generate a secure random 2048-bit number b:</p>
<!-- start b -->
<pre><code>b = B5B96CBF8810CA8CC278FAC3B33EAE695E3DC385141F6A2589E4F1397EB31B945891509FB6A8BDEF35B05E81E9A53147FB4539A6B9CBDEB25E96FFABE57330FFE302DF225BE77B75B6B49A826F73D4A54E1965A272B18BE78FBA8B51D169273E896828AEC28188F849692A87AE41A17E3EB372788C12F3C94EC76A7C1304B5649EFA949BF19969AFC1717AAC02068CD898FC179B326EC7993C90B8853471397E72F3B95ADED7A59962B7EA3D4C45F8D6598E2FCE7A62CE77C3A3967479964C522622BE6AF16A9D1FFE794A4F5241909AE1374195C6C43E2983511824210D055D870EC0641618808685B7D41C6D09C9D3B2CD1EC83A02DF49C7EEA78F459C6AA8</code></pre>
<pre><code>b = 47F55ABF75125D664CB42AC0484DD33B40314EACCD487BFAE50271930D1F83A9455DF1FC0F4013530DB5BC205371E79238EBFCB46755CC43AA762595FA8C4A1108A9B5EB992B13DA7D816BAB9F8098721A76EA38238EB52809BE487EFBA926E5C821461AC4DB4325880DE8A234EB6BD97743E6D099F941197D85EE92336B90AB6DE61732F1F59E42DC125F4A1C97938DC648564ABF0A36B3F487A165BF5B088158B61CD8EDDEE600943637E6C0F5D037F49D2D68440CF3E1276FDBF03D7C1939E737BAAB001C4F56CA6108DFFEC95EB1B842B065D461D13F617AD2A6D0FEB45EF37B947E7504133A423890E52A090F50138D381B797A149FAE7BAF771CB45DC1</code></pre>
<!-- end b -->
<p>Then compute <code>g_b = pow(g, b) mod dh_prime</code></p>
<!-- start g_b -->
<pre><code>g_b = 34EBAF3B575322E9B23E98F62E7FEB0C141D12A31DFCC37C2F10C096320161860252CC12767D4487F5BB1DFFB39E3956C33F3C02FA13853A32EDD9F35237A3A45D80D56AEAAD943775FC5E262D632A838C3B8A1FAB9A90F29CC6E697E729B6E740DCEE3839EBA8B2372389ABFE706FB6D407839921FE2E457DE4BC932F37E32F89F63B0B4A0D4092935E1F92CE311047E523CE0A7C8ECB011F1F7D9C7EFD9E9978460845F8F76451E178857278B1D95E67018AB1FAC1544D58F0F6CBC9B83051D16220220455C734F362DE3DDBFDC865F161722E9771EC66A6EE4F1BAB3F65378C8423E178A2AB7FCC8DC3DC93793E04CEEC9C54C31F2E710C9AA7B1195137C5</code></pre>
<pre><code>g_b = 6D2DEC4316EE4A6C99B4637DEA60FBEC3FF3681142DDDF0766A9903FDF521BC1A5A1E96CB38596FC893FE5417A722F4F119542D3AB21DCB06783FE3E4C1E60C2FE225E8B631083A82E3C66AC3959564DFA4BC422DD870106A698726EBD30E152619EE13691355BA52408158C70F890B4CEEA6831CC7D9C357049A38B104BB1EAC19F21EB4F66F5FC63695C85F0DB7F3CB1E8FB0064EBB1EA8092832F1DA77476897FD269F3E9A8B41212ED78CA6EB0456E2DF7014F6D5C7671877E8997EABDECD0DC3F94E986B0EF32A1EA5F5F5563460E8E0D18571FEA329B3B36312B22D24590FFE27BF00F950853F0A837F1276ECC7A0524DEFC1B603BD3C274AA7691D0AD</code></pre>
<!-- end g_b -->
<h6>7.1) generation of encrypted_data</h6>
<!-- start client_DH_inner_data -->
<p>Generated payload (excluding transport headers/trailers):</p>
<pre><code>0000 | 54 B6 43 66 A0 C3 6E 98 B7 E1 6B 63 D0 EF D6 D1
0010 | F3 3D 86 13 A2 00 C9 D3 74 62 9E 4C D5 8D 79 8C
0020 | FF AC 07 F8 00 00 00 00 00 00 00 00 FE 00 01 00
0030 | 34 EB AF 3B 57 53 22 E9 B2 3E 98 F6 2E 7F EB 0C
0040 | 14 1D 12 A3 1D FC C3 7C 2F 10 C0 96 32 01 61 86
0050 | 02 52 CC 12 76 7D 44 87 F5 BB 1D FF B3 9E 39 56
0060 | C3 3F 3C 02 FA 13 85 3A 32 ED D9 F3 52 37 A3 A4
0070 | 5D 80 D5 6A EA AD 94 37 75 FC 5E 26 2D 63 2A 83
0080 | 8C 3B 8A 1F AB 9A 90 F2 9C C6 E6 97 E7 29 B6 E7
0090 | 40 DC EE 38 39 EB A8 B2 37 23 89 AB FE 70 6F B6
00A0 | D4 07 83 99 21 FE 2E 45 7D E4 BC 93 2F 37 E3 2F
00B0 | 89 F6 3B 0B 4A 0D 40 92 93 5E 1F 92 CE 31 10 47
00C0 | E5 23 CE 0A 7C 8E CB 01 1F 1F 7D 9C 7E FD 9E 99
00D0 | 78 46 08 45 F8 F7 64 51 E1 78 85 72 78 B1 D9 5E
00E0 | 67 01 8A B1 FA C1 54 4D 58 F0 F6 CB C9 B8 30 51
00F0 | D1 62 20 22 04 55 C7 34 F3 62 DE 3D DB FD C8 65
0100 | F1 61 72 2E 97 71 EC 66 A6 EE 4F 1B AB 3F 65 37
0110 | 8C 84 23 E1 78 A2 AB 7F CC 8D C3 DC 93 79 3E 04
0120 | CE EC 9C 54 C3 1F 2E 71 0C 9A A7 B1 19 51 37 C5</code></pre>
<pre><code>0000 | 54 B6 43 66 12 D2 52 A6 52 49 2F 98 B3 E7 AC 76
0010 | FE FA 89 A4 6C E7 5A 07 8D 3B DA EC 6C D2 D6 3A
0020 | D8 67 9D DA 00 00 00 00 00 00 00 00 FE 00 01 00
0030 | 6D 2D EC 43 16 EE 4A 6C 99 B4 63 7D EA 60 FB EC
0040 | 3F F3 68 11 42 DD DF 07 66 A9 90 3F DF 52 1B C1
0050 | A5 A1 E9 6C B3 85 96 FC 89 3F E5 41 7A 72 2F 4F
0060 | 11 95 42 D3 AB 21 DC B0 67 83 FE 3E 4C 1E 60 C2
0070 | FE 22 5E 8B 63 10 83 A8 2E 3C 66 AC 39 59 56 4D
0080 | FA 4B C4 22 DD 87 01 06 A6 98 72 6E BD 30 E1 52
0090 | 61 9E E1 36 91 35 5B A5 24 08 15 8C 70 F8 90 B4
00A0 | CE EA 68 31 CC 7D 9C 35 70 49 A3 8B 10 4B B1 EA
00B0 | C1 9F 21 EB 4F 66 F5 FC 63 69 5C 85 F0 DB 7F 3C
00C0 | B1 E8 FB 00 64 EB B1 EA 80 92 83 2F 1D A7 74 76
00D0 | 89 7F D2 69 F3 E9 A8 B4 12 12 ED 78 CA 6E B0 45
00E0 | 6E 2D F7 01 4F 6D 5C 76 71 87 7E 89 97 EA BD EC
00F0 | D0 DC 3F 94 E9 86 B0 EF 32 A1 EA 5F 5F 55 63 46
0100 | 0E 8E 0D 18 57 1F EA 32 9B 3B 36 31 2B 22 D2 45
0110 | 90 FF E2 7B F0 0F 95 08 53 F0 A8 37 F1 27 6E CC
0120 | 7A 05 24 DE FC 1B 60 3B D3 C2 74 AA 76 91 D0 AD</code></pre>
<p>Payload (de)serialization:</p>
<pre><code>client_DH_inner_data#6643b654 nonce:int128 server_nonce:int128 retry_id:long g_b:string = Client_DH_Inner_Data;</code></pre>
<table class="table">
@ -658,19 +658,19 @@ answer = BA0D89B5A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F
<tr>
<td>nonce</td>
<td>4, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Value generated by client in Step 1</td>
</tr>
<tr>
<td>server_nonce</td>
<td>20, 16</td>
<td><code>A200C9D374629E4CD58D798CFFAC07F8</code></td>
<td><code>6CE75A078D3BDAEC6CD2D63AD8679DDA</code></td>
<td>Value received from server in Step 2</td>
</tr>
<tr>
<td>g_b</td>
<td>36, 260</td>
<td><code>FE00010034EBAF3B575322E9B23E98F6</code> <code>2E7FEB0C141D12A31DFCC37C2F10C096</code> <code>320161860252CC12767D4487F5BB1DFF</code> <code>B39E3956C33F3C02FA13853A32EDD9F3</code> <code>5237A3A45D80D56AEAAD943775FC5E26</code> <code>2D632A838C3B8A1FAB9A90F29CC6E697</code> <code>E729B6E740DCEE3839EBA8B2372389AB</code> <code>FE706FB6D407839921FE2E457DE4BC93</code> <code>2F37E32F89F63B0B4A0D4092935E1F92</code> <code>CE311047E523CE0A7C8ECB011F1F7D9C</code> <code>7EFD9E9978460845F8F76451E1788572</code> <code>78B1D95E67018AB1FAC1544D58F0F6CB</code> <code>C9B83051D16220220455C734F362DE3D</code> <code>DBFDC865F161722E9771EC66A6EE4F1B</code> <code>AB3F65378C8423E178A2AB7FCC8DC3DC</code> <code>93793E04CEEC9C54C31F2E710C9AA7B1</code><br> <code>195137C5</code></td>
<td><code>FE0001006D2DEC4316EE4A6C99B4637D</code> <code>EA60FBEC3FF3681142DDDF0766A9903F</code> <code>DF521BC1A5A1E96CB38596FC893FE541</code> <code>7A722F4F119542D3AB21DCB06783FE3E</code> <code>4C1E60C2FE225E8B631083A82E3C66AC</code> <code>3959564DFA4BC422DD870106A698726E</code> <code>BD30E152619EE13691355BA52408158C</code> <code>70F890B4CEEA6831CC7D9C357049A38B</code> <code>104BB1EAC19F21EB4F66F5FC63695C85</code> <code>F0DB7F3CB1E8FB0064EBB1EA8092832F</code> <code>1DA77476897FD269F3E9A8B41212ED78</code> <code>CA6EB0456E2DF7014F6D5C7671877E89</code> <code>97EABDECD0DC3F94E986B0EF32A1EA5F</code> <code>5F5563460E8E0D18571FEA329B3B3631</code> <code>2B22D24590FFE27BF00F950853F0A837</code> <code>F1276ECC7A0524DEFC1B603BD3C274AA</code><br> <code>7691D0AD</code></td>
<td>Single-byte prefix denoting length, a 256-byte (2048-bit) string, and zero bytes of padding</td>
</tr>
<tr>
@ -684,47 +684,47 @@ answer = BA0D89B5A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F
<!-- end client_DH_inner_data -->
<p>The serialization of <em>Client_DH_Inner_Data</em> produces a string <strong>data</strong>. This is used to generate <strong>encrypted_data</strong> as specified in <a href="#7-client-computes-random-2048-bit-number-b-using-a-sufficient-amount-of-entropy-and-sends-the-server-a-message">step 6</a>, using the following inputs:</p>
<!-- start client_DH_inner_data_input -->
<pre><code>data = 54B64366A0C36E98B7E16B63D0EFD6D1F33D8613A200C9D374629E4CD58D798CFFAC07F80000000000000000FE00010034EBAF3B575322E9B23E98F62E7FEB0C141D12A31DFCC37C2F10C096320161860252CC12767D4487F5BB1DFFB39E3956C33F3C02FA13853A32EDD9F35237A3A45D80D56AEAAD943775FC5E262D632A838C3B8A1FAB9A90F29CC6E697E729B6E740DCEE3839EBA8B2372389ABFE706FB6D407839921FE2E457DE4BC932F37E32F89F63B0B4A0D4092935E1F92CE311047E523CE0A7C8ECB011F1F7D9C7EFD9E9978460845F8F76451E178857278B1D95E67018AB1FAC1544D58F0F6CBC9B83051D16220220455C734F362DE3DDBFDC865F161722E9771EC66A6EE4F1BAB3F65378C8423E178A2AB7FCC8DC3DC93793E04CEEC9C54C31F2E710C9AA7B1195137C5
padding = A5FCB431195245CEB68A6AC9
tmp_aes_key = C43503B78CE1A7EBA3BE3378B41644235F348455FD4004A102BAF4AB1E3DDE11
tmp_aes_iv = 43FA1673796D54629C3BECDC6C69C67115AB10D7261D57C3C94258F133D0B6D0</code></pre>
<pre><code>data = 54B6436612D252A652492F98B3E7AC76FEFA89A46CE75A078D3BDAEC6CD2D63AD8679DDA0000000000000000FE0001006D2DEC4316EE4A6C99B4637DEA60FBEC3FF3681142DDDF0766A9903FDF521BC1A5A1E96CB38596FC893FE5417A722F4F119542D3AB21DCB06783FE3E4C1E60C2FE225E8B631083A82E3C66AC3959564DFA4BC422DD870106A698726EBD30E152619EE13691355BA52408158C70F890B4CEEA6831CC7D9C357049A38B104BB1EAC19F21EB4F66F5FC63695C85F0DB7F3CB1E8FB0064EBB1EA8092832F1DA77476897FD269F3E9A8B41212ED78CA6EB0456E2DF7014F6D5C7671877E8997EABDECD0DC3F94E986B0EF32A1EA5F5F5563460E8E0D18571FEA329B3B36312B22D24590FFE27BF00F950853F0A837F1276ECC7A0524DEFC1B603BD3C274AA7691D0AD
padding = 7207D745977DE93E3241406F
tmp_aes_key = F97885237250E1E2923A564401F69AA32F283C7A9C3448965DAB36A9481EE649
tmp_aes_iv = 954D4B646A8170F6C46CD9F709B2E4203595359E5AA26C84DA8918FB56018FA1</code></pre>
<!-- end client_DH_inner_data_input -->
<p>Process:</p>
<pre><code>data_with_hash := SHA1(data) + data + padding (0-15 random bytes such that total length is divisible by 16)
encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);</code></pre>
<p>Output:</p>
<!-- start client_DH_inner_data_output -->
<pre><code>encrypted_data = FD8F7BAAC2C118D4A3C056D052DD15D5D6C5FCF9DB2DB2964E13E778D97E461C9EE9047A439FA0391F34569FEE912E9EDFF00C96509732C8559F98F0619C6A4F86A84570F2520D0FF4D76D1694C08EE42E11680CDB4DD08AEF19C48708C95D57DAB4AEA22B6843224AC6F5134C3EEFAE5F52A749AEA5B00D1A9D1A94BEE455E9BFD320DCDDA66905F3300FEB1592D1FFF3434AC2DD002A687ACBE61FDAEA95395CB92493BFF4CDC41A7857FEA2D0EEAFF1E71FEFBE10BCB36A9E1B11EBBA10F5818138EB53F05A31A27680B3320E92278A6F22712503FDDAB962D5FB6756A5189BF50524640225B92E70BCF649D6A2797DE4E2E375B99830CB5F32A93A9C82593A974B62C440D2EA357FD0636C471E61B719B9902A32087AC042ACC68FAC8D424E98B9352DB233209E3A5141DAFDAFAFC2DB6A605730E0D17880E8A96214EA9E21F73ED176816EED97EFE8451ED08521</code></pre>
<pre><code>encrypted_data = A503E6CD8B949E333CA530863336E66D42F26723883828EC831280772BCDF29C9770EFC917E6971C83830FA60F32C76696877EBE68620AD75CD5338777835E4CED6E3529CE4391C3FBD97E5E81B47FF060EED9CDFB91BE9DB9E82DE5E32187299DACB5FB667F409E4C2FC9118509CA68CB484B0F9597DE3707B31744DE2FAD949957B3FAA8A9D34CCD4399103704739E2B8620C4FE32737063D46D40833E79BF62A8062EEB5D518C38C02AA4CE85D9EF00B7B975144BEE80C1223A272E6B0EF4373AD6C6F86C30AC0FAA106DFEDDB8D15CA1752B960D39AAD9DB8BC19F1D89AF4DB0FDCE2E2CD407841446ECEF382984E3445096864F39DD9D3CCF1026D45888FE3E5E5864352087BCDC335587ED91E44263EB784C2B31B841A55803AC6A5572517BE118906FDFCFFA815C4B2F911351758117C07DEE4744109866657D281DDD1F6CDA0EDF72CDB43A0333320B12227C</code></pre>
<!-- end client_DH_inner_data_output -->
<p>The length of the final string is 336 bytes.</p>
<h6>7.2) set_client_DH_params query</h6>
<!-- start set_client_DH_params -->
<p>Sent payload (excluding transport headers/trailers):</p>
<pre><code>0000 | 00 00 00 00 00 00 00 00 14 6E 0B 00 B7 30 72 65
0010 | 78 01 00 00 1F 5F 04 F5 A0 C3 6E 98 B7 E1 6B 63
0020 | D0 EF D6 D1 F3 3D 86 13 A2 00 C9 D3 74 62 9E 4C
0030 | D5 8D 79 8C FF AC 07 F8 FE 50 01 00 FD 8F 7B AA
0040 | C2 C1 18 D4 A3 C0 56 D0 52 DD 15 D5 D6 C5 FC F9
0050 | DB 2D B2 96 4E 13 E7 78 D9 7E 46 1C 9E E9 04 7A
0060 | 43 9F A0 39 1F 34 56 9F EE 91 2E 9E DF F0 0C 96
0070 | 50 97 32 C8 55 9F 98 F0 61 9C 6A 4F 86 A8 45 70
0080 | F2 52 0D 0F F4 D7 6D 16 94 C0 8E E4 2E 11 68 0C
0090 | DB 4D D0 8A EF 19 C4 87 08 C9 5D 57 DA B4 AE A2
00A0 | 2B 68 43 22 4A C6 F5 13 4C 3E EF AE 5F 52 A7 49
00B0 | AE A5 B0 0D 1A 9D 1A 94 BE E4 55 E9 BF D3 20 DC
00C0 | DD A6 69 05 F3 30 0F EB 15 92 D1 FF F3 43 4A C2
00D0 | DD 00 2A 68 7A CB E6 1F DA EA 95 39 5C B9 24 93
00E0 | BF F4 CD C4 1A 78 57 FE A2 D0 EE AF F1 E7 1F EF
00F0 | BE 10 BC B3 6A 9E 1B 11 EB BA 10 F5 81 81 38 EB
0100 | 53 F0 5A 31 A2 76 80 B3 32 0E 92 27 8A 6F 22 71
0110 | 25 03 FD DA B9 62 D5 FB 67 56 A5 18 9B F5 05 24
0120 | 64 02 25 B9 2E 70 BC F6 49 D6 A2 79 7D E4 E2 E3
0130 | 75 B9 98 30 CB 5F 32 A9 3A 9C 82 59 3A 97 4B 62
0140 | C4 40 D2 EA 35 7F D0 63 6C 47 1E 61 B7 19 B9 90
0150 | 2A 32 08 7A C0 42 AC C6 8F AC 8D 42 4E 98 B9 35
0160 | 2D B2 33 20 9E 3A 51 41 DA FD AF AF C2 DB 6A 60
0170 | 57 30 E0 D1 78 80 E8 A9 62 14 EA 9E 21 F7 3E D1
0180 | 76 81 6E ED 97 EF E8 45 1E D0 85 21</code></pre>
<pre><code>0000 | 00 00 00 00 00 00 00 00 CC 03 0F 00 3A BB 74 65
0010 | 78 01 00 00 1F 5F 04 F5 12 D2 52 A6 52 49 2F 98
0020 | B3 E7 AC 76 FE FA 89 A4 6C E7 5A 07 8D 3B DA EC
0030 | 6C D2 D6 3A D8 67 9D DA FE 50 01 00 A5 03 E6 CD
0040 | 8B 94 9E 33 3C A5 30 86 33 36 E6 6D 42 F2 67 23
0050 | 88 38 28 EC 83 12 80 77 2B CD F2 9C 97 70 EF C9
0060 | 17 E6 97 1C 83 83 0F A6 0F 32 C7 66 96 87 7E BE
0070 | 68 62 0A D7 5C D5 33 87 77 83 5E 4C ED 6E 35 29
0080 | CE 43 91 C3 FB D9 7E 5E 81 B4 7F F0 60 EE D9 CD
0090 | FB 91 BE 9D B9 E8 2D E5 E3 21 87 29 9D AC B5 FB
00A0 | 66 7F 40 9E 4C 2F C9 11 85 09 CA 68 CB 48 4B 0F
00B0 | 95 97 DE 37 07 B3 17 44 DE 2F AD 94 99 57 B3 FA
00C0 | A8 A9 D3 4C CD 43 99 10 37 04 73 9E 2B 86 20 C4
00D0 | FE 32 73 70 63 D4 6D 40 83 3E 79 BF 62 A8 06 2E
00E0 | EB 5D 51 8C 38 C0 2A A4 CE 85 D9 EF 00 B7 B9 75
00F0 | 14 4B EE 80 C1 22 3A 27 2E 6B 0E F4 37 3A D6 C6
0100 | F8 6C 30 AC 0F AA 10 6D FE DD B8 D1 5C A1 75 2B
0110 | 96 0D 39 AA D9 DB 8B C1 9F 1D 89 AF 4D B0 FD CE
0120 | 2E 2C D4 07 84 14 46 EC EF 38 29 84 E3 44 50 96
0130 | 86 4F 39 DD 9D 3C CF 10 26 D4 58 88 FE 3E 5E 58
0140 | 64 35 20 87 BC DC 33 55 87 ED 91 E4 42 63 EB 78
0150 | 4C 2B 31 B8 41 A5 58 03 AC 6A 55 72 51 7B E1 18
0160 | 90 6F DF CF FA 81 5C 4B 2F 91 13 51 75 81 17 C0
0170 | 7D EE 47 44 10 98 66 65 7D 28 1D DD 1F 6C DA 0E
0180 | DF 72 CD B4 3A 03 33 32 0B 12 22 7C</code></pre>
<p>Payload (de)serialization:</p>
<pre><code>set_client_DH_params#f5045f1f nonce:int128 server_nonce:int128 encrypted_data:string = Set_client_DH_params_answer;</code></pre>
<table class="table">
@ -746,7 +746,7 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);<
<tr>
<td>message_id</td>
<td>8, 8</td>
<td><code>146E0B00B7307265</code></td>
<td><code>CC030F003ABB7465</code></td>
<td>Message ID generated as specified <a href="/mtproto/description#message-identifier-msg-id">here »</a> (unixtime() &lt;&lt; 32) + (N*4)</td>
</tr>
<tr>
@ -764,19 +764,19 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);<
<tr>
<td>nonce</td>
<td>24, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Value generated by client in Step 1</td>
</tr>
<tr>
<td>server_nonce</td>
<td>40, 16</td>
<td><code>A200C9D374629E4CD58D798CFFAC07F8</code></td>
<td><code>6CE75A078D3BDAEC6CD2D63AD8679DDA</code></td>
<td>Value received from server in Step 2</td>
</tr>
<tr>
<td>encrypted_data</td>
<td>56, 340</td>
<td><code>FE500100FD8F7BAAC2C118D4A3C056D0</code> <code>52DD15D5D6C5FCF9DB2DB2964E13E778</code> <code>D97E461C9EE9047A439FA0391F34569F</code> <code>EE912E9EDFF00C96509732C8559F98F0</code> <code>619C6A4F86A84570F2520D0FF4D76D16</code> <code>94C08EE42E11680CDB4DD08AEF19C487</code> <code>08C95D57DAB4AEA22B6843224AC6F513</code> <code>4C3EEFAE5F52A749AEA5B00D1A9D1A94</code> <code>BEE455E9BFD320DCDDA66905F3300FEB</code> <code>1592D1FFF3434AC2DD002A687ACBE61F</code> <code>DAEA95395CB92493BFF4CDC41A7857FE</code> <code>A2D0EEAFF1E71FEFBE10BCB36A9E1B11</code> <code>EBBA10F5818138EB53F05A31A27680B3</code> <code>320E92278A6F22712503FDDAB962D5FB</code> <code>6756A5189BF50524640225B92E70BCF6</code> <code>49D6A2797DE4E2E375B99830CB5F32A9</code> <code>3A9C82593A974B62C440D2EA357FD063</code> <code>6C471E61B719B9902A32087AC042ACC6</code> <code>8FAC8D424E98B9352DB233209E3A5141</code> <code>DAFDAFAFC2DB6A605730E0D17880E8A9</code> <code>6214EA9E21F73ED176816EED97EFE845</code><br> <code>1ED08521</code></td>
<td><code>FE500100A503E6CD8B949E333CA53086</code> <code>3336E66D42F26723883828EC83128077</code> <code>2BCDF29C9770EFC917E6971C83830FA6</code> <code>0F32C76696877EBE68620AD75CD53387</code> <code>77835E4CED6E3529CE4391C3FBD97E5E</code> <code>81B47FF060EED9CDFB91BE9DB9E82DE5</code> <code>E32187299DACB5FB667F409E4C2FC911</code> <code>8509CA68CB484B0F9597DE3707B31744</code> <code>DE2FAD949957B3FAA8A9D34CCD439910</code> <code>3704739E2B8620C4FE32737063D46D40</code> <code>833E79BF62A8062EEB5D518C38C02AA4</code> <code>CE85D9EF00B7B975144BEE80C1223A27</code> <code>2E6B0EF4373AD6C6F86C30AC0FAA106D</code> <code>FEDDB8D15CA1752B960D39AAD9DB8BC1</code> <code>9F1D89AF4DB0FDCE2E2CD407841446EC</code> <code>EF382984E3445096864F39DD9D3CCF10</code> <code>26D45888FE3E5E5864352087BCDC3355</code> <code>87ED91E44263EB784C2B31B841A55803</code> <code>AC6A5572517BE118906FDFCFFA815C4B</code> <code>2F911351758117C07DEE474410986665</code> <code>7D281DDD1F6CDA0EDF72CDB43A033332</code><br> <code>0B12227C</code></td>
<td>Encrypted client_DH_inner_data generated previously, serialized as a TL byte string</td>
</tr>
</tbody>
@ -785,17 +785,17 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);<
<h5><a class="anchor" href="#8-auth-key-generation" id="8-auth-key-generation" name="8-auth-key-generation"><i class="anchor-icon"></i></a>8) Auth key generation</h5>
<p>The client computes the auth_key using formula <code>g_a^b mod dh_prime</code>:</p>
<!-- start auth_key -->
<pre><code>auth_key = 8498598427CEA30CC2F796C90015E1BA0A188E68121D4FF77F785F247CE7F75023C4F9EDA6DEA3A54000D244F12E32E8A0F9D6F28C2A428CE2B7BB94C064DA2C49B237F086FF898E2CCE6FD5DA226377017C4C59DA109783FB304C0D4D5CA19A53D555CA8821BC0CD9624D7C4D1EB713EF37518BE7847B18E91B9E3C16A6BC7569780A74725A9DA1EB8BEED5EB1707A9BA6DA9778AB7D201EAB13F3D896389A6C14930D306E6874D162FAB2EB44B40673145ECAF256F8244C84FF72906931A702B086312D7F3E516E9DCDA1DE35A5672F0D8365F8AA6C7200FA67393CCE47B9B4A48DF1C0F9FC834E5A0EAEC1C71DFB64000165F75A14D5E60E45DAD68B7269F</code></pre>
<pre><code>auth_key = 244410BC9D177FCDB8EFFB35E66FFD061C5A1FC1B1B42490DDF5F621C348D9275513C5AD9E4869AA35BE3547282FAA822C1A55D63AF593EA23E09AED79F190DECDD0940CB86C0BA8A983CDC2D97F538D4109DD18955E99B881A95670710532F898C3406113CA35F658099DEA83EC0052272F7C1D0BEED401E3D6A6341499009B961DD2EA74F1875579A90E0F152A87A6853FE320EB27E76DAF367795086597F7160F7C392DEBE55E7AA8B3FB181999659E3B925283211FEEF0DE6FAC7866D43E22F2D5068E5D081C42D291316F750AB1304D13CCFBBB5094529B9E056A49F6C42B5689BBF5475B24C9EF200AF82E4ADF62FC3FA996DB99A4B80549B0C853FCCC</code></pre>
<!-- end auth_key -->
<h5><a class="anchor" href="#9-final-server-reply" id="9-final-server-reply" name="9-final-server-reply"><i class="anchor-icon"></i></a>9) Final server reply</h5>
<p>The server verifies and confirms that auth_key_hash is unique: since it's unique, it replies with the following:</p>
<!-- start dh_gen_ok -->
<p>Received payload (excluding transport headers/trailers):</p>
<pre><code>0000 | 00 00 00 00 00 00 00 00 01 E4 64 B0 B7 30 72 65
0010 | 48 00 00 00 34 F7 CB 3B A0 C3 6E 98 B7 E1 6B 63
0020 | D0 EF D6 D1 F3 3D 86 13 A2 00 C9 D3 74 62 9E 4C
0030 | D5 8D 79 8C FF AC 07 F8 29 6A E8 21 B8 42 78 09
0040 | 79 60 F1 28 07 16 8D BB</code></pre>
<pre><code>0000 | 00 00 00 00 00 00 00 00 01 60 E0 33 3B BB 74 65
0010 | 9C 00 00 00 34 F7 CB 3B 12 D2 52 A6 52 49 2F 98
0020 | B3 E7 AC 76 FE FA 89 A4 6C E7 5A 07 8D 3B DA EC
0030 | 6C D2 D6 3A D8 67 9D DA 8B FA C8 03 5D A7 77 2B
0040 | 7F 58 18 E2 3A 86 65 79</code></pre>
<p>Payload (de)serialization:</p>
<pre><code>dh_gen_ok#3bcbf734 nonce:int128 server_nonce:int128 new_nonce_hash1:int128 = Set_client_DH_params_answer;</code></pre>
<table class="table">
@ -817,13 +817,13 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);<
<tr>
<td>message_id</td>
<td>8, 8</td>
<td><code>01E464B0B7307265</code></td>
<td><code>0160E0333BBB7465</code></td>
<td>Message ID generated as specified <a href="/mtproto/description#message-identifier-msg-id">here »</a> (unixtime() &lt;&lt; 32) + (N*4)</td>
</tr>
<tr>
<td>message_length</td>
<td>16, 4</td>
<td><code>48000000</code> (72 in decimal)</td>
<td><code>9C000000</code> (156 in decimal)</td>
<td>Message body length</td>
</tr>
<tr>
@ -835,19 +835,19 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);<
<tr>
<td>nonce</td>
<td>24, 16</td>
<td><code>A0C36E98B7E16B63D0EFD6D1F33D8613</code></td>
<td><code>12D252A652492F98B3E7AC76FEFA89A4</code></td>
<td>Value generated by client in Step 1</td>
</tr>
<tr>
<td>server_nonce</td>
<td>40, 16</td>
<td><code>A200C9D374629E4CD58D798CFFAC07F8</code></td>
<td><code>6CE75A078D3BDAEC6CD2D63AD8679DDA</code></td>
<td>Value received from server in Step 2</td>
</tr>
<tr>
<td>new_nonce_hash1</td>
<td>56, 16</td>
<td><code>296AE821B84278097960F12807168DBB</code></td>
<td><code>8BFAC8035DA7772B7F5818E23A866579</code></td>
<td>The 128 lower-order bits of SHA1 of the byte string derived from the <code>new_nonce</code> string by adding a single byte with the value of 1, 2, or 3, and followed by another 8 bytes with <code>auth_key_aux_hash</code>. Different values are required to prevent an intruder from changing server response dh_gen_ok into dh_gen_retry.</td>
</tr>
</tbody>

View file

@ -849,7 +849,7 @@
</tr>
<tr>
<td><a href="/method/account.updateColor">account.updateColor</a></td>
<td> </td>
<td>Update the <a href="/api/colors">accent color and background custom emoji »</a> of the current account.</td>
</tr>
</tbody>
</table></div>

View file

@ -107,7 +107,7 @@
</tr>
<tr>
<td><a href="/method/account.getDefaultBackgroundEmojis">account.getDefaultBackgroundEmojis</a></td>
<td> </td>
<td>Get a set of suggested <a href="/api/custom-emoji">custom emoji stickers</a> that can be used in an <a href="/api/colors">accent color pattern</a>.</td>
</tr>
</tbody>
</table>

View file

@ -602,7 +602,7 @@
</tr>
<tr>
<td><a href="/method/channels.updateColor">channels.updateColor</a></td>
<td> </td>
<td>Update the <a href="/api/colors">accent color and background custom emoji »</a> of a channel.</td>
</tr>
<tr>
<td><a href="/method/channels.toggleViewForumAsMessages">channels.toggleViewForumAsMessages</a></td>