From 4b6361edb9f23b16bc12d761e93b0232576fcdbb Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Wed, 24 Jul 2024 17:55:01 +0000 Subject: [PATCH] Update content of files --- .../mtproto/samples-auth_key.html | 412 +++++++++--------- .../type/PrivacyKey.html | 2 +- 2 files changed, 207 insertions(+), 207 deletions(-) diff --git a/data/web/corefork.telegram.org/mtproto/samples-auth_key.html b/data/web/corefork.telegram.org/mtproto/samples-auth_key.html index 920602fdd8..dfeeb01da9 100644 --- a/data/web/corefork.telegram.org/mtproto/samples-auth_key.html +++ b/data/web/corefork.telegram.org/mtproto/samples-auth_key.html @@ -53,9 +53,9 @@
1) Client sends query to server

Sent payload (excluding transport headers/trailers):

-
0000 | 00 00 00 00 00 00 00 00 08 CF 03 00 8D 3C A1 66
-0010 | 14 00 00 00 F1 8E 7E BE F6 08 5A 66 81 25 75 E2
-0020 | 81 12 E1 29 9D 0F 62 6E
+
0000 | 00 00 00 00 00 00 00 00 F8 87 0A 00 B1 3F A1 66
+0010 | 14 00 00 00 F1 8E 7E BE 50 04 22 80 E4 B6 7C 30
+0020 | 77 D4 A0 C1 2D 4D 1E C1

Payload (de)serialization:

req_pq_multi#be7e8ef1 nonce:int128 = ResPQ;
@@ -77,7 +77,7 @@ - + @@ -95,7 +95,7 @@ - + @@ -104,11 +104,11 @@
2) Server sends response of the form

Received payload (excluding transport headers/trailers):

-
0000 | 00 00 00 00 00 00 00 00 01 A8 63 1A 8D 3C A1 66
-0010 | 9C 00 00 00 63 24 16 05 F6 08 5A 66 81 25 75 E2
-0020 | 81 12 E1 29 9D 0F 62 6E 0E 48 CD 96 A1 86 60 61
-0030 | 97 46 58 A4 30 BD 77 33 08 1B 0A AA EA F9 D1 22
-0040 | 31 00 00 00 15 C4 B5 1C 03 00 00 00 A5 B7 F7 09
+
0000 | 00 00 00 00 00 00 00 00 01 E8 2E 9C B1 3F A1 66
+0010 | C0 00 00 00 63 24 16 05 50 04 22 80 E4 B6 7C 30
+0020 | 77 D4 A0 C1 2D 4D 1E C1 F2 E4 63 9D 99 B8 10 5C
+0030 | A2 0D 76 A0 5F D1 1F 84 08 11 82 5D 68 B2 4C 41
+0040 | EF 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

Payload (de)serialization:

@@ -132,13 +132,13 @@
- + - + @@ -150,19 +150,19 @@ - + - + - + @@ -208,22 +208,22 @@

Proof of work

3) Client decomposes pq into prime factors such that p < q.
-
pq = 1948557714981462577
-

Decompose into 2 prime cofactors p < q: 1948557714981462577 = 1002516773 * 1943665949

-
p = 1002516773
-q = 1943665949
+
pq = 1261673549866484207
+

Decompose into 2 prime cofactors p < q: 1261673549866484207 = 1016741911 * 1240898537

+
p = 1016741911
+q = 1240898537

Presenting proof of work; Server authentication

4) encrypted_data payload generation

First of all, generate an encrypted_data payload as follows:

Generated payload (excluding transport headers/trailers):

-
0000 | 95 5F F5 A9 08 1B 0A AA EA F9 D1 22 31 00 00 00
-0010 | 04 3B C1 31 25 00 00 00 04 73 D9 FD 1D 00 00 00
-0020 | F6 08 5A 66 81 25 75 E2 81 12 E1 29 9D 0F 62 6E
-0030 | 0E 48 CD 96 A1 86 60 61 97 46 58 A4 30 BD 77 33
-0040 | 81 EC 6A 3B 1F 98 EB 9B 15 EF E5 F4 6D AE 0A 5E
-0050 | 82 55 3C DE 98 C6 8B E6 45 CA 91 19 8C F2 C1 0A
+
0000 | 95 5F F5 A9 08 11 82 5D 68 B2 4C 41 EF 00 00 00
+0010 | 04 3C 9A 40 17 00 00 00 04 49 F6 9B E9 00 00 00
+0020 | 50 04 22 80 E4 B6 7C 30 77 D4 A0 C1 2D 4D 1E C1
+0030 | F2 E4 63 9D 99 B8 10 5C A2 0D 76 A0 5F D1 1F 84
+0040 | 3C 0C 10 14 DB E5 F8 D7 43 34 E9 60 36 75 C3 FA
+0050 | C4 FA A7 96 C2 FC A6 45 F5 C4 C3 9F 90 50 49 7C
 0060 | 02 00 00 00

Payload (de)serialization:

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;
@@ -246,37 +246,37 @@ q = 1943665949
- + - + - + - + - + - + @@ -291,39 +291,39 @@ q = 1943665949

The serialization of P_Q_inner_data produces data, which is used to generate encrypted_data as specified in step 4.1.
These are the inputs to the algorithm specified in step 4.1:

-
data = 955FF5A9081B0AAAEAF9D12231000000043BC131250000000473D9FD1D000000F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773381EC6A3B1F98EB9B15EFE5F46DAE0A5E82553CDE98C68BE645CA91198CF2C10A02000000
-random_padding_bytes = 9974885E29BF30E5A7A603D93DD9B75472468573892E3F78AF14233B04CDE84B1246870EC2FEEF7D78ADE2660AD534FE3D95957C2011A03BAB201C309E9A67E0A123A4770D4BF5E8756566390431834AB836DB3EDB7E6D81140D21BD
+
data = 955FF5A90811825D68B24C41EF000000043C9A40170000000449F69BE900000050042280E4B67C3077D4A0C12D4D1EC1F2E4639D99B8105CA20D76A05FD11F843C0C1014DBE5F8D74334E9603675C3FAC4FAA796C2FCA645F5C4C39F9050497C02000000
+random_padding_bytes = 164CC8038512BCF8178FDB95E42550E63A4D1215196110827BFF368AE5AF1969C0C250E0649806687C37A0882E2C08610F3EBD5DF39DC3221BA8332A8CA6DFDF1BCB5D7F57F15BD89A5F32148FED59A8439C5E68CEFA44C1D66D8F25

And this is the output:

-
encrypted_data = 51DD24B756C4BDC6DFBF81F1F6A1B2F38562AC8DC7F6C32C624AE8FA7856C8D1A5756B2D10BFB8B1E2C702F69907CECA6B161C1575E4CE4E85A9BA48C4B63B678B62A1D56027D39C92C37D6656C771F761BC4ED1073B43EC07064B9D0173143711E34189C24AAD72128FF9D4E688E807CBC555A76B830E30313D209991A860D1392436F471A761D8566EE2A357A2EF9CAD8AA3A741EEAA29431B263F5CC00C4C5AB00F45AB4BA1938C1F198D4A69225BE94554CB7F84C428535F79206C876DF2FC84EA7AB21D26DEF3C26BAFC01EFB17CA2C39D29050821D0FF05AAC653794F0B3D916E978A4FD077C63F268F6ADFDFF2980D42E3D5C5F86954A123AC2D3067B
+
encrypted_data = B519E958BFD522D00D490335CAB2FEED9DE6F74BA8DB9887FCF54AEDFD3C5B4B383CE5E77EE0F033A22683DEA57D0BE279D680020499B10EDEE578B0DBB9C47C4B73F5EE3C60D36A16464371BA4D4AF2C86BE4CDBB6C940A0F2FF07FAEE5DC0AF7B478C34013DF745301221FFBA0A0D473D9CC8B2AD9A084366D31023E02D888F76C4772E118A0CE37FA7E0AB0704ED2F3DB67A691BA99AD41CC74D89AB6371DEBD3E1B98FAB0A951B90AD117B28081654DB8357F25C96EBEA9074561EE16D3B1AF516F8751C33D7839684D14B1CBA3004A98F3AB0D48DEA49ACF7D8E84A2849CB211BC1786371900FCC5AE0BD0177D7808B67FAFEF3B28E535CDE542E1C353A

The length of the final string is 256 bytes.

5) Send req_DH_params query with generated encrypted_data

Sent payload (excluding transport headers/trailers):

-
0000 | 00 00 00 00 00 00 00 00 9C 10 07 00 8D 3C A1 66
-0010 | 40 01 00 00 BE E4 12 D7 F6 08 5A 66 81 25 75 E2
-0020 | 81 12 E1 29 9D 0F 62 6E 0E 48 CD 96 A1 86 60 61
-0030 | 97 46 58 A4 30 BD 77 33 04 3B C1 31 25 00 00 00
-0040 | 04 73 D9 FD 1D 00 00 00 85 FD 64 DE 85 1D 9D D0
-0050 | FE 00 01 00 51 DD 24 B7 56 C4 BD C6 DF BF 81 F1
-0060 | F6 A1 B2 F3 85 62 AC 8D C7 F6 C3 2C 62 4A E8 FA
-0070 | 78 56 C8 D1 A5 75 6B 2D 10 BF B8 B1 E2 C7 02 F6
-0080 | 99 07 CE CA 6B 16 1C 15 75 E4 CE 4E 85 A9 BA 48
-0090 | C4 B6 3B 67 8B 62 A1 D5 60 27 D3 9C 92 C3 7D 66
-00A0 | 56 C7 71 F7 61 BC 4E D1 07 3B 43 EC 07 06 4B 9D
-00B0 | 01 73 14 37 11 E3 41 89 C2 4A AD 72 12 8F F9 D4
-00C0 | E6 88 E8 07 CB C5 55 A7 6B 83 0E 30 31 3D 20 99
-00D0 | 91 A8 60 D1 39 24 36 F4 71 A7 61 D8 56 6E E2 A3
-00E0 | 57 A2 EF 9C AD 8A A3 A7 41 EE AA 29 43 1B 26 3F
-00F0 | 5C C0 0C 4C 5A B0 0F 45 AB 4B A1 93 8C 1F 19 8D
-0100 | 4A 69 22 5B E9 45 54 CB 7F 84 C4 28 53 5F 79 20
-0110 | 6C 87 6D F2 FC 84 EA 7A B2 1D 26 DE F3 C2 6B AF
-0120 | C0 1E FB 17 CA 2C 39 D2 90 50 82 1D 0F F0 5A AC
-0130 | 65 37 94 F0 B3 D9 16 E9 78 A4 FD 07 7C 63 F2 68
-0140 | F6 AD FD FF 29 80 D4 2E 3D 5C 5F 86 95 4A 12 3A
-0150 | C2 D3 06 7B
+
0000 | 00 00 00 00 00 00 00 00 FC 87 0A 00 B1 3F A1 66
+0010 | 40 01 00 00 BE E4 12 D7 50 04 22 80 E4 B6 7C 30
+0020 | 77 D4 A0 C1 2D 4D 1E C1 F2 E4 63 9D 99 B8 10 5C
+0030 | A2 0D 76 A0 5F D1 1F 84 04 3C 9A 40 17 00 00 00
+0040 | 04 49 F6 9B E9 00 00 00 85 FD 64 DE 85 1D 9D D0
+0050 | FE 00 01 00 B5 19 E9 58 BF D5 22 D0 0D 49 03 35
+0060 | CA B2 FE ED 9D E6 F7 4B A8 DB 98 87 FC F5 4A ED
+0070 | FD 3C 5B 4B 38 3C E5 E7 7E E0 F0 33 A2 26 83 DE
+0080 | A5 7D 0B E2 79 D6 80 02 04 99 B1 0E DE E5 78 B0
+0090 | DB B9 C4 7C 4B 73 F5 EE 3C 60 D3 6A 16 46 43 71
+00A0 | BA 4D 4A F2 C8 6B E4 CD BB 6C 94 0A 0F 2F F0 7F
+00B0 | AE E5 DC 0A F7 B4 78 C3 40 13 DF 74 53 01 22 1F
+00C0 | FB A0 A0 D4 73 D9 CC 8B 2A D9 A0 84 36 6D 31 02
+00D0 | 3E 02 D8 88 F7 6C 47 72 E1 18 A0 CE 37 FA 7E 0A
+00E0 | B0 70 4E D2 F3 DB 67 A6 91 BA 99 AD 41 CC 74 D8
+00F0 | 9A B6 37 1D EB D3 E1 B9 8F AB 0A 95 1B 90 AD 11
+0100 | 7B 28 08 16 54 DB 83 57 F2 5C 96 EB EA 90 74 56
+0110 | 1E E1 6D 3B 1A F5 16 F8 75 1C 33 D7 83 96 84 D1
+0120 | 4B 1C BA 30 04 A9 8F 3A B0 D4 8D EA 49 AC F7 D8
+0130 | E8 4A 28 49 CB 21 1B C1 78 63 71 90 0F CC 5A E0
+0140 | BD 01 77 D7 80 8B 67 FA FE F3 B2 8E 53 5C DE 54
+0150 | 2E 1C 35 3A

Payload (de)serialization:

req_DH_params#d712e4be nonce:int128 server_nonce:int128 p:string q:string public_key_fingerprint:long encrypted_data:string = Server_DH_Params;
message_id 8, 808CF03008D3CA166F8870A00B13FA166 Message ID generated as specified here » (unixtime() << 32) + (N*4)
nonce 24, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Random number
message_id 8, 801A8631A8D3CA16601E82E9CB13FA166 Message ID generated as specified here » (unixtime() << 32) + (N*4)
message_length 16, 49C000000 (156 in decimal)C0000000 (192 in decimal) Message body length
nonce 24, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Value generated by client in Step 1
server_nonce 40, 160E48CD96A1866061974658A430BD7733F2E4639D99B8105CA20D76A05FD11F84 Server-generated random number
pq 56, 12081B0AAAEAF9D12231000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1948557714981462577
0811825D68B24C41EF000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1261673549866484207
Single-byte prefix denoting length, an 8-byte string, and three bytes of padding
pq 4, 12081B0AAAEAF9D12231000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1948557714981462577
0811825D68B24C41EF000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1261673549866484207
Single-byte prefix denoting length, 8-byte string, and three bytes of padding
p 16, 8043BC13125000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1002516773
043C9A4017000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1016741911
First prime cofactor: single-byte prefix denoting length, 4-byte string, and three bytes of padding
q 24, 80473D9FD1D000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1943665949
0449F69BE9000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1240898537
Second prime cofactor: single-byte prefix denoting length, 4-byte string, and three bytes of padding
nonce 32, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Value generated by client in Step 1
server_nonce 48, 160E48CD96A1866061974658A430BD7733F2E4639D99B8105CA20D76A05FD11F84 Value received from server in Step 2
new_nonce 64, 3281EC6A3B1F98EB9B15EFE5F46DAE0A5E 82553CDE98C68BE645CA91198CF2C10A3C0C1014DBE5F8D74334E9603675C3FA C4FAA796C2FCA645F5C4C39F9050497C Client-generated random number
@@ -345,7 +345,7 @@ random_padding_bytes = 9974885E29BF30E5A7A603D93DD9B75472468573892E3F78AF14233B0 - + @@ -363,25 +363,25 @@ random_padding_bytes = 9974885E29BF30E5A7A603D93DD9B75472468573892E3F78AF14233B0 - + - + - + - + @@ -393,7 +393,7 @@ random_padding_bytes = 9974885E29BF30E5A7A603D93DD9B75472468573892E3F78AF14233B0 - + @@ -402,47 +402,47 @@ random_padding_bytes = 9974885E29BF30E5A7A603D93DD9B75472468573892E3F78AF14233B0
6) Server responds with:

Received payload (excluding transport headers/trailers):

-
0000 | 00 00 00 00 00 00 00 00 01 C4 CD D4 8D 3C A1 66
-0010 | BC 02 00 00 5C 07 E8 D0 F6 08 5A 66 81 25 75 E2
-0020 | 81 12 E1 29 9D 0F 62 6E 0E 48 CD 96 A1 86 60 61
-0030 | 97 46 58 A4 30 BD 77 33 FE 50 02 00 5A CB 29 7F
-0040 | 7F AB E4 AE A1 B0 28 32 EB D4 11 B0 E5 42 3E EC
-0050 | 0E E4 40 B9 43 1E 23 F7 76 34 7E 2E 33 32 0F 46
-0060 | 0F 0B 0F B4 29 67 8B 42 3A 82 AF 8C 4D 8F AC 05
-0070 | 0C 30 0C 50 15 42 79 D6 84 1D DC 1B 5F 91 AE 00
-0080 | 40 C3 80 A1 12 69 C4 68 4A 66 F0 46 75 EA 25 7B
-0090 | F6 34 60 BF 27 26 EE E7 3B 68 8F B3 0B D0 C5 7E
-00A0 | F7 AA F3 8B D6 46 12 9C 6B DE 80 B3 D0 3B CD C6
-00B0 | 7B 94 7A E4 D3 D0 75 22 C1 1A D2 BE A8 E9 54 9F
-00C0 | D5 F4 14 0F C9 6D B6 62 50 DA B8 36 83 9C 89 F3
-00D0 | 38 3E 1C CA BC 27 61 54 87 93 09 FD 6E 50 8B EA
-00E0 | D4 7C 21 0E A7 49 AD D4 9E 82 E2 3B 08 51 36 F3
-00F0 | 1A 7A 14 4D 6B F1 C7 FC E2 6E 47 9D CB 0A 5A 3F
-0100 | DD 79 61 DC CF 34 E0 72 2E 89 81 03 F7 27 73 4D
-0110 | E3 B1 8D 76 44 99 65 80 1F 0F 91 2B D6 0F 1C AE
-0120 | 66 4C FC 8B 52 D8 65 F9 33 07 53 5A 5D A9 9A 36
-0130 | DF 2A F6 48 8F EB D3 E8 68 FA 2E 84 2C 54 35 D7
-0140 | 1C 4F BE B1 0E 07 F4 40 B1 39 7B 46 E3 EB F7 71
-0150 | 95 68 97 76 40 B2 94 47 43 89 C8 AD 1F 2C 54 B5
-0160 | 55 98 20 F1 3F E0 3D AE 8D D1 9A 09 E3 C0 EA 97
-0170 | 7B 98 D2 2F 6F E9 C9 9C 22 EB 98 F6 A6 87 BA 0C
-0180 | 16 66 48 3F AD 6A 71 22 87 32 28 05 20 0A 93 B8
-0190 | 70 ED 19 DE 0C D5 7F A4 B8 78 68 A3 B0 A7 41 A5
-01A0 | A9 28 52 DF 2E 60 4F E8 91 9C DC 2D F0 A3 80 02
-01B0 | CA FA 7A 50 1F 1B D6 83 70 B9 BF DB A8 E9 8B FC
-01C0 | B2 17 4B 35 29 43 D4 A8 2E 3E 9F C3 AF 3A F7 B0
-01D0 | 59 72 10 35 D7 21 13 96 7A 2E D6 4D EE 0E 78 A0
-01E0 | 0A AD 09 72 58 65 03 32 A9 65 FC 48 9A 3F ED 2D
-01F0 | B3 AA 9A F4 8D D3 2A C3 69 B5 7C A0 DB 0D 5B 54
-0200 | 8F A0 C2 F6 96 5D 2C 5B 46 22 DC 97 72 86 B6 E0
-0210 | 30 5F D9 F0 7C BC 59 83 82 BF 3C AB 0D 70 F2 CD
-0220 | 59 AA 5F CB 37 0C FF CF FF A8 A8 CA E2 35 9F E9
-0230 | BE 35 86 2A F2 45 FD 30 D6 44 1A 6B 89 91 DD 1B
-0240 | 8B F8 1C 14 9C 31 7F D6 55 B3 C6 7B EC EF 93 82
-0250 | 65 55 ED 07 E8 7A 96 18 47 A1 42 05 9C 42 E3 26
-0260 | 85 27 9D 15 A0 71 DF BA D5 C5 9B C2 46 28 76 9C
-0270 | 16 91 D7 7A EC 24 DA FA 76 B2 FE B5 1C 40 EE 1A
-0280 | B3 1A 7E 0A 39 24 1A 6B 23 08 9C CB
+
0000 | 00 00 00 00 00 00 00 00 01 58 8F 4D B2 3F A1 66
+0010 | A0 02 00 00 5C 07 E8 D0 50 04 22 80 E4 B6 7C 30
+0020 | 77 D4 A0 C1 2D 4D 1E C1 F2 E4 63 9D 99 B8 10 5C
+0030 | A2 0D 76 A0 5F D1 1F 84 FE 50 02 00 10 5A A2 CB
+0040 | D8 5D D3 3A 5D 1E F8 60 2F 11 A1 5F 25 40 61 F8
+0050 | 9C E5 38 CB A2 74 A1 85 FE 0A 08 76 93 CC 62 B8
+0060 | 00 CF A1 64 5F 9F 28 96 4F E7 97 66 B1 CF F0 48
+0070 | BF 9E 38 ED 32 39 D0 D4 0D 09 54 FE C4 67 99 E4
+0080 | 51 E2 65 AD 2D 8F 5C 09 1D 26 22 99 77 F8 3A D7
+0090 | FA 9F D8 62 45 D2 F5 78 6A D0 C0 FB 79 AA 32 5A
+00A0 | 95 91 7C 88 5B 87 DB 1F 27 3F 88 EE 9B 7D B1 8F
+00B0 | 69 26 3B C7 10 C2 9C 3C 69 29 4C 85 BC 5A 3F 67
+00C0 | 2F A9 66 AA 43 C9 0A A4 5E F5 96 13 9D 9D 61 C9
+00D0 | 65 C5 57 BB 25 D3 EA 2E D7 3B AC A4 59 EF FE EF
+00E0 | A8 AB 28 14 F5 6E 84 1B 31 E4 0D BD B9 77 58 FD
+00F0 | DD 66 98 A6 86 C9 19 C2 07 C5 D6 7B 6E 35 0F 79
+0100 | 28 02 4D 61 4C 63 BB 8B A9 9F 74 C4 D9 67 43 03
+0110 | FB 37 EC D0 CE 54 02 49 97 84 ED C0 4B 21 5E F6
+0120 | 7B 1B 55 15 C2 E6 71 D2 60 C4 83 03 C9 DB 49 8C
+0130 | 64 44 AA E1 81 11 1C 84 9C 3E 90 8D 4F 56 18 FC
+0140 | B5 09 26 FC 3F BD 4A 67 56 EF EF 9A 1E 9C 98 08
+0150 | 65 2A E0 14 66 FF F6 E3 E9 DB 55 5F FA C9 11 06
+0160 | F1 71 E0 5D 35 8A 76 27 74 AC A5 13 F5 78 03 6F
+0170 | D8 07 8D CC CB 43 90 18 F6 D8 CE 7C 79 38 EA C5
+0180 | A4 5E FC E2 40 9A 44 FD 04 25 47 D3 FD 16 E8 46
+0190 | 66 19 09 A3 77 B1 CD 42 54 BF E5 1B 19 39 A4 FF
+01A0 | 52 97 C5 A9 FF 7B 8F 4E D6 11 2D AD 5D 4C 3D 88
+01B0 | E2 E1 28 D5 82 48 02 DC 75 51 4B 36 59 87 0B D5
+01C0 | 6B 1C D4 70 F8 46 CE EA 6D 2A 23 AC 69 67 41 F1
+01D0 | 61 42 A1 3F 49 0D 47 AE 29 06 EF AA 07 35 F9 91
+01E0 | D6 9F B8 8D 7A D4 CF A5 40 A1 AA FA 5C 7F 6E CB
+01F0 | CE FB BD 9C DA BF C0 D7 89 E3 CC A6 DE 30 42 EC
+0200 | DF 52 42 33 21 8C 41 9A 8A 3C 18 7F 25 51 A4 80
+0210 | D2 7D B9 C8 76 F6 72 EF 39 D2 BC 8F 8B 95 B7 0A
+0220 | 84 F7 5D 24 C5 4D 62 55 A2 F8 75 1A 38 FC C6 4E
+0230 | EA 08 96 DE 76 CE C5 8D 89 9E FA 8B 20 AF 3C FC
+0240 | 57 9C 36 14 D5 A9 5E 2C 6E B9 A2 04 86 11 1A 80
+0250 | B2 47 12 D3 CC 50 D3 E1 67 A5 C7 08 9A 63 EE 6F
+0260 | AF 1C 60 DF 63 57 F8 81 C4 E2 AF DC 58 C6 91 C7
+0270 | 08 3D 76 39 DC CE 5E 1D FF F0 B4 1E F5 77 BC B8
+0280 | 4C C1 80 3D 71 24 D3 98 CD 5B 6F 97

Payload (de)serialization:

server_DH_params_ok#d0e8075c nonce:int128 server_nonce:int128 encrypted_answer:string = Server_DH_Params;
message_id 8, 89C1007008D3CA166FC870A00B13FA166 Message ID generated as specified here » (unixtime() << 32) + (N*4)
nonce 24, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Value generated by client in Step 1
server_nonce 40, 160E48CD96A1866061974658A430BD7733F2E4639D99B8105CA20D76A05FD11F84 Value received from server in Step 2
p 56, 8043BC13125000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1002516773
043C9A4017000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1016741911
First prime cofactor: single-byte prefix denoting length, 4-byte string, and three bytes of padding
q 64, 80473D9FD1D000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1943665949
0449F69BE9000000
TL byte deserialization
=> bigendian conversion to decimal
=> 1240898537
Second prime cofactor: single-byte prefix denoting length, 4-byte string, and three bytes of padding
encrypted_data 80, 260FE00010051DD24B756C4BDC6DFBF81F1 F6A1B2F38562AC8DC7F6C32C624AE8FA 7856C8D1A5756B2D10BFB8B1E2C702F6 9907CECA6B161C1575E4CE4E85A9BA48 C4B63B678B62A1D56027D39C92C37D66 56C771F761BC4ED1073B43EC07064B9D 0173143711E34189C24AAD72128FF9D4 E688E807CBC555A76B830E30313D2099 91A860D1392436F471A761D8566EE2A3 57A2EF9CAD8AA3A741EEAA29431B263F 5CC00C4C5AB00F45AB4BA1938C1F198D 4A69225BE94554CB7F84C428535F7920 6C876DF2FC84EA7AB21D26DEF3C26BAF C01EFB17CA2C39D29050821D0FF05AAC 653794F0B3D916E978A4FD077C63F268 F6ADFDFF2980D42E3D5C5F86954A123A
C2D3067B
FE000100B519E958BFD522D00D490335 CAB2FEED9DE6F74BA8DB9887FCF54AED FD3C5B4B383CE5E77EE0F033A22683DE A57D0BE279D680020499B10EDEE578B0 DBB9C47C4B73F5EE3C60D36A16464371 BA4D4AF2C86BE4CDBB6C940A0F2FF07F AEE5DC0AF7B478C34013DF745301221F FBA0A0D473D9CC8B2AD9A084366D3102 3E02D888F76C4772E118A0CE37FA7E0A B0704ED2F3DB67A691BA99AD41CC74D8 9AB6371DEBD3E1B98FAB0A951B90AD11 7B28081654DB8357F25C96EBEA907456 1EE16D3B1AF516F8751C33D7839684D1 4B1CBA3004A98F3AB0D48DEA49ACF7D8 E84A2849CB211BC1786371900FCC5AE0 BD0177D7808B67FAFEF3B28E535CDE54
2E1C353A
Value generated above
@@ -464,13 +464,13 @@ random_padding_bytes = 9974885E29BF30E5A7A603D93DD9B75472468573892E3F78AF14233B0 - + - + @@ -482,19 +482,19 @@ random_padding_bytes = 9974885E29BF30E5A7A603D93DD9B75472468573892E3F78AF14233B0 - + - + - + @@ -502,20 +502,20 @@ random_padding_bytes = 9974885E29BF30E5A7A603D93DD9B75472468573892E3F78AF14233B0

Decrypt encrypted_answer using the reverse of the process specified in step 6:

-
encrypted_answer = 5ACB297F7FABE4AEA1B02832EBD411B0E5423EEC0EE440B9431E23F776347E2E33320F460F0B0FB429678B423A82AF8C4D8FAC050C300C50154279D6841DDC1B5F91AE0040C380A11269C4684A66F04675EA257BF63460BF2726EEE73B688FB30BD0C57EF7AAF38BD646129C6BDE80B3D03BCDC67B947AE4D3D07522C11AD2BEA8E9549FD5F4140FC96DB66250DAB836839C89F3383E1CCABC276154879309FD6E508BEAD47C210EA749ADD49E82E23B085136F31A7A144D6BF1C7FCE26E479DCB0A5A3FDD7961DCCF34E0722E898103F727734DE3B18D76449965801F0F912BD60F1CAE664CFC8B52D865F93307535A5DA99A36DF2AF6488FEBD3E868FA2E842C5435D71C4FBEB10E07F440B1397B46E3EBF7719568977640B294474389C8AD1F2C54B5559820F13FE03DAE8DD19A09E3C0EA977B98D22F6FE9C99C22EB98F6A687BA0C1666483FAD6A712287322805200A93B870ED19DE0CD57FA4B87868A3B0A741A5A92852DF2E604FE8919CDC2DF0A38002CAFA7A501F1BD68370B9BFDBA8E98BFCB2174B352943D4A82E3E9FC3AF3AF7B059721035D72113967A2ED64DEE0E78A00AAD097258650332A965FC489A3FED2DB3AA9AF48DD32AC369B57CA0DB0D5B548FA0C2F6965D2C5B4622DC977286B6E0305FD9F07CBC598382BF3CAB0D70F2CD59AA5FCB370CFFCFFFA8A8CAE2359FE9BE35862AF245FD30D6441A6B8991DD1B8BF81C149C317FD655B3C67BECEF93826555ED07E87A961847A142059C42E32685279D15A071DFBAD5C59BC24628769C1691D77AEC24DAFA76B2FEB51C40EE1AB31A7E0A39241A6B23089CCB
-tmp_aes_key = 174BB7DE1552D7E4A81205A0A423C492A6935F82DF6DC6334CAE2C306CD60137
-tmp_aes_iv = 44C5026626D067174BA9CDFDCF7D7091E4F40F256F7FE12A8C857F3581EC6A3B
+
encrypted_answer = 105AA2CBD85DD33A5D1EF8602F11A15F254061F89CE538CBA274A185FE0A087693CC62B800CFA1645F9F28964FE79766B1CFF048BF9E38ED3239D0D40D0954FEC46799E451E265AD2D8F5C091D26229977F83AD7FA9FD86245D2F5786AD0C0FB79AA325A95917C885B87DB1F273F88EE9B7DB18F69263BC710C29C3C69294C85BC5A3F672FA966AA43C90AA45EF596139D9D61C965C557BB25D3EA2ED73BACA459EFFEEFA8AB2814F56E841B31E40DBDB97758FDDD6698A686C919C207C5D67B6E350F7928024D614C63BB8BA99F74C4D9674303FB37ECD0CE5402499784EDC04B215EF67B1B5515C2E671D260C48303C9DB498C6444AAE181111C849C3E908D4F5618FCB50926FC3FBD4A6756EFEF9A1E9C9808652AE01466FFF6E3E9DB555FFAC91106F171E05D358A762774ACA513F578036FD8078DCCCB439018F6D8CE7C7938EAC5A45EFCE2409A44FD042547D3FD16E846661909A377B1CD4254BFE51B1939A4FF5297C5A9FF7B8F4ED6112DAD5D4C3D88E2E128D5824802DC75514B3659870BD56B1CD470F846CEEA6D2A23AC696741F16142A13F490D47AE2906EFAA0735F991D69FB88D7AD4CFA540A1AAFA5C7F6ECBCEFBBD9CDABFC0D789E3CCA6DE3042ECDF524233218C419A8A3C187F2551A480D27DB9C876F672EF39D2BC8F8B95B70A84F75D24C54D6255A2F8751A38FCC64EEA0896DE76CEC58D899EFA8B20AF3CFC579C3614D5A95E2C6EB9A20486111A80B24712D3CC50D3E167A5C7089A63EE6FAF1C60DF6357F881C4E2AFDC58C691C7083D7639DCCE5E1DFFF0B41EF577BCB84CC1803D7124D398CD5B6F97
+tmp_aes_key = 0862009CDA343B604C16E1FB67162F4A6E0328779435AE8B32B844D8B8AE1B27
+tmp_aes_iv = D322BF7B0FE3405722AE697F94816E143A5EB539D3129610D71EA71C3C0C1014

Yielding:

-
answer_with_hash = 7335E0952695FE66EF25E4DDE351725C35C310D6BA0D89B5F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773303000000FE000100C71CAEB9C6B1C9048E6C522F70F13F73980D40238E3E21C14934D037563D930F48198A0AA7C14058229493D22530F4DBFA336F6E0AC925139543AED44CCE7C3720FD51F69458705AC68CD4FE6B6B13ABDC9746512969328454F18FAF8C595F642477FE96BB2A941D5BCD1D4AC8CC49880708FA9B378E3C4F3A9060BEE67CF9A4A4A695811051907E162753B56B0F6B410DBA74D8A84B2A14B3144E0EF1284754FD17ED950D5965B4B9DD46582DB1178D169C6BC465B0D6FF9CA3928FEF5B9AE4E418FC15E83EBEA0F87FA9FF5EED70050DED2849F47BF959D956850CE929851F0D8115F635B105EE2E4E15D04B2454BF6F4FADF034B10403119CD8E3B92FCC5BFE00010032F36F957997386EAF11A538C81CFBAA3BEF08528257C8D1E2BD9BE5359D00A6D20C56E74DE8E9E245451B2CB4A16CD58BA711F076848CB61779AFE8760D2F60BC99886887ABE04E8EB616E23EA0015467E98E35D6EC3D2A01E6523EC0CB5D75E9F6EBAC67C9131EE89BD91828F7C1A727D0AB19888E826E4A08B121D3AC3D8450FC53FE9C35C389081279297D5912B7878E071F7BD14D7916BFFFD8C402C106CD8784C12EFC79ECF20F65ABAEF8E72C8878BF8BC21418CB406775CEA752671EAF6DAB7ABCB0692A93180A93906A911FFF6AD161433630897F18CC5A7D4CBEAF20793336756FDE2098F001CFE820A6D0FB863E873DAA54E95269F50CFF9922638D3CA1660493879370953445
-answer = BA0D89B5F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773303000000FE000100C71CAEB9C6B1C9048E6C522F70F13F73980D40238E3E21C14934D037563D930F48198A0AA7C14058229493D22530F4DBFA336F6E0AC925139543AED44CCE7C3720FD51F69458705AC68CD4FE6B6B13ABDC9746512969328454F18FAF8C595F642477FE96BB2A941D5BCD1D4AC8CC49880708FA9B378E3C4F3A9060BEE67CF9A4A4A695811051907E162753B56B0F6B410DBA74D8A84B2A14B3144E0EF1284754FD17ED950D5965B4B9DD46582DB1178D169C6BC465B0D6FF9CA3928FEF5B9AE4E418FC15E83EBEA0F87FA9FF5EED70050DED2849F47BF959D956850CE929851F0D8115F635B105EE2E4E15D04B2454BF6F4FADF034B10403119CD8E3B92FCC5BFE00010032F36F957997386EAF11A538C81CFBAA3BEF08528257C8D1E2BD9BE5359D00A6D20C56E74DE8E9E245451B2CB4A16CD58BA711F076848CB61779AFE8760D2F60BC99886887ABE04E8EB616E23EA0015467E98E35D6EC3D2A01E6523EC0CB5D75E9F6EBAC67C9131EE89BD91828F7C1A727D0AB19888E826E4A08B121D3AC3D8450FC53FE9C35C389081279297D5912B7878E071F7BD14D7916BFFFD8C402C106CD8784C12EFC79ECF20F65ABAEF8E72C8878BF8BC21418CB406775CEA752671EAF6DAB7ABCB0692A93180A93906A911FFF6AD161433630897F18CC5A7D4CBEAF20793336756FDE2098F001CFE820A6D0FB863E873DAA54E95269F50CFF9922638D3CA1660493879370953445
+
answer_with_hash = 15989B2F251AB8C10E1E412DAFCA6D7A6E352BCABA0D89B550042280E4B67C3077D4A0C12D4D1EC1F2E4639D99B8105CA20D76A05FD11F8403000000FE000100C71CAEB9C6B1C9048E6C522F70F13F73980D40238E3E21C14934D037563D930F48198A0AA7C14058229493D22530F4DBFA336F6E0AC925139543AED44CCE7C3720FD51F69458705AC68CD4FE6B6B13ABDC9746512969328454F18FAF8C595F642477FE96BB2A941D5BCD1D4AC8CC49880708FA9B378E3C4F3A9060BEE67CF9A4A4A695811051907E162753B56B0F6B410DBA74D8A84B2A14B3144E0EF1284754FD17ED950D5965B4B9DD46582DB1178D169C6BC465B0D6FF9CA3928FEF5B9AE4E418FC15E83EBEA0F87FA9FF5EED70050DED2849F47BF959D956850CE929851F0D8115F635B105EE2E4E15D04B2454BF6F4FADF034B10403119CD8E3B92FCC5BFE000100AF72F3963FDBA1665B55447FD1D6E0085A7B44999E834CE16D600DA97DD44E70D4AFE2C8BDD51B7B1CD921D566A9D89CAE5CA7BF4C88DA694EAEC3ECA1A938FE626D3A1D2ED84D9404ABC37ED8629A638F8591F441A21F4BE3388FDE34B271C9692F2EBD1F3BAB1A6CE391A0401D3F0417FFF96609178D4CF3D3CE1564264DD6266719A559BB5E40A6B69955BBBE32F0CFB7BDAA0B3A52CD1A6A72B87C9EE66495C1ACCCA3BDA8299229D0045D59F9795BD3B38FC7A54EE590200E95EE7C739EA80ADEE55649226009BC14D36797613DC4220B126631A41371739FD63F3FAE3E5219B9164E45EA8BFEBF57B239655B1745D73065C05E7A3DD69F0331AFF4B59EB23FA1663946F5D0F640DDA7
+answer = BA0D89B550042280E4B67C3077D4A0C12D4D1EC1F2E4639D99B8105CA20D76A05FD11F8403000000FE000100C71CAEB9C6B1C9048E6C522F70F13F73980D40238E3E21C14934D037563D930F48198A0AA7C14058229493D22530F4DBFA336F6E0AC925139543AED44CCE7C3720FD51F69458705AC68CD4FE6B6B13ABDC9746512969328454F18FAF8C595F642477FE96BB2A941D5BCD1D4AC8CC49880708FA9B378E3C4F3A9060BEE67CF9A4A4A695811051907E162753B56B0F6B410DBA74D8A84B2A14B3144E0EF1284754FD17ED950D5965B4B9DD46582DB1178D169C6BC465B0D6FF9CA3928FEF5B9AE4E418FC15E83EBEA0F87FA9FF5EED70050DED2849F47BF959D956850CE929851F0D8115F635B105EE2E4E15D04B2454BF6F4FADF034B10403119CD8E3B92FCC5BFE000100AF72F3963FDBA1665B55447FD1D6E0085A7B44999E834CE16D600DA97DD44E70D4AFE2C8BDD51B7B1CD921D566A9D89CAE5CA7BF4C88DA694EAEC3ECA1A938FE626D3A1D2ED84D9404ABC37ED8629A638F8591F441A21F4BE3388FDE34B271C9692F2EBD1F3BAB1A6CE391A0401D3F0417FFF96609178D4CF3D3CE1564264DD6266719A559BB5E40A6B69955BBBE32F0CFB7BDAA0B3A52CD1A6A72B87C9EE66495C1ACCCA3BDA8299229D0045D59F9795BD3B38FC7A54EE590200E95EE7C739EA80ADEE55649226009BC14D36797613DC4220B126631A41371739FD63F3FAE3E5219B9164E45EA8BFEBF57B239655B1745D73065C05E7A3DD69F0331AFF4B59EB23FA1663946F5D0F640DDA7

Generated payload (excluding transport headers/trailers):

-
0000 | BA 0D 89 B5 F6 08 5A 66 81 25 75 E2 81 12 E1 29
-0010 | 9D 0F 62 6E 0E 48 CD 96 A1 86 60 61 97 46 58 A4
-0020 | 30 BD 77 33 03 00 00 00 FE 00 01 00 C7 1C AE B9
+
0000 | BA 0D 89 B5 50 04 22 80 E4 B6 7C 30 77 D4 A0 C1
+0010 | 2D 4D 1E C1 F2 E4 63 9D 99 B8 10 5C A2 0D 76 A0
+0020 | 5F D1 1F 84 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 = BA0D89B5F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773
 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 | 32 F3 6F 95 79 97 38 6E AF 11 A5 38 C8 1C FB AA
-0140 | 3B EF 08 52 82 57 C8 D1 E2 BD 9B E5 35 9D 00 A6
-0150 | D2 0C 56 E7 4D E8 E9 E2 45 45 1B 2C B4 A1 6C D5
-0160 | 8B A7 11 F0 76 84 8C B6 17 79 AF E8 76 0D 2F 60
-0170 | BC 99 88 68 87 AB E0 4E 8E B6 16 E2 3E A0 01 54
-0180 | 67 E9 8E 35 D6 EC 3D 2A 01 E6 52 3E C0 CB 5D 75
-0190 | E9 F6 EB AC 67 C9 13 1E E8 9B D9 18 28 F7 C1 A7
-01A0 | 27 D0 AB 19 88 8E 82 6E 4A 08 B1 21 D3 AC 3D 84
-01B0 | 50 FC 53 FE 9C 35 C3 89 08 12 79 29 7D 59 12 B7
-01C0 | 87 8E 07 1F 7B D1 4D 79 16 BF FF D8 C4 02 C1 06
-01D0 | CD 87 84 C1 2E FC 79 EC F2 0F 65 AB AE F8 E7 2C
-01E0 | 88 78 BF 8B C2 14 18 CB 40 67 75 CE A7 52 67 1E
-01F0 | AF 6D AB 7A BC B0 69 2A 93 18 0A 93 90 6A 91 1F
-0200 | FF 6A D1 61 43 36 30 89 7F 18 CC 5A 7D 4C BE AF
-0210 | 20 79 33 36 75 6F DE 20 98 F0 01 CF E8 20 A6 D0
-0220 | FB 86 3E 87 3D AA 54 E9 52 69 F5 0C FF 99 22 63
-0230 | 8D 3C A1 66
+0130 | AF 72 F3 96 3F DB A1 66 5B 55 44 7F D1 D6 E0 08 +0140 | 5A 7B 44 99 9E 83 4C E1 6D 60 0D A9 7D D4 4E 70 +0150 | D4 AF E2 C8 BD D5 1B 7B 1C D9 21 D5 66 A9 D8 9C +0160 | AE 5C A7 BF 4C 88 DA 69 4E AE C3 EC A1 A9 38 FE +0170 | 62 6D 3A 1D 2E D8 4D 94 04 AB C3 7E D8 62 9A 63 +0180 | 8F 85 91 F4 41 A2 1F 4B E3 38 8F DE 34 B2 71 C9 +0190 | 69 2F 2E BD 1F 3B AB 1A 6C E3 91 A0 40 1D 3F 04 +01A0 | 17 FF F9 66 09 17 8D 4C F3 D3 CE 15 64 26 4D D6 +01B0 | 26 67 19 A5 59 BB 5E 40 A6 B6 99 55 BB BE 32 F0 +01C0 | CF B7 BD AA 0B 3A 52 CD 1A 6A 72 B8 7C 9E E6 64 +01D0 | 95 C1 AC CC A3 BD A8 29 92 29 D0 04 5D 59 F9 79 +01E0 | 5B D3 B3 8F C7 A5 4E E5 90 20 0E 95 EE 7C 73 9E +01F0 | A8 0A DE E5 56 49 22 60 09 BC 14 D3 67 97 61 3D +0200 | C4 22 0B 12 66 31 A4 13 71 73 9F D6 3F 3F AE 3E +0210 | 52 19 B9 16 4E 45 EA 8B FE BF 57 B2 39 65 5B 17 +0220 | 45 D7 30 65 C0 5E 7A 3D D6 9F 03 31 AF F4 B5 9E +0230 | B2 3F A1 66

Payload (de)serialization:

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;
message_id 8, 801C4CDD48D3CA16601588F4DB23FA166 Message ID generated as specified here » (unixtime() << 32) + (N*4)
message_length 16, 4BC020000 (700 in decimal)A0020000 (672 in decimal) Message body length
nonce 24, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Value generated by client in Step 1
server_nonce 40, 160E48CD96A1866061974658A430BD7733F2E4639D99B8105CA20D76A05FD11F84 Value received from server in Step 2
encrypted_answer 56, 596FE5002005ACB297F7FABE4AEA1B02832 EBD411B0E5423EEC0EE440B9431E23F7 76347E2E33320F460F0B0FB429678B42 3A82AF8C4D8FAC050C300C50154279D6 841DDC1B5F91AE0040C380A11269C468 4A66F04675EA257BF63460BF2726EEE7 3B688FB30BD0C57EF7AAF38BD646129C 6BDE80B3D03BCDC67B947AE4D3D07522 C11AD2BEA8E9549FD5F4140FC96DB662 50DAB836839C89F3383E1CCABC276154 879309FD6E508BEAD47C210EA749ADD4 9E82E23B085136F31A7A144D6BF1C7FC E26E479DCB0A5A3FDD7961DCCF34E072 2E898103F727734DE3B18D7644996580 1F0F912BD60F1CAE664CFC8B52D865F9 3307535A5DA99A36DF2AF6488FEBD3E8 68FA2E842C5435D71C4FBEB10E07F440 B1397B46E3EBF7719568977640B29447 4389C8AD1F2C54B5559820F13FE03DAE 8DD19A09E3C0EA977B98D22F6FE9C99C 22EB98F6A687BA0C1666483FAD6A7122 87322805200A93B870ED19DE0CD57FA4 B87868A3B0A741A5A92852DF2E604FE8 919CDC2DF0A38002CAFA7A501F1BD683 70B9BFDBA8E98BFCB2174B352943D4A8 2E3E9FC3AF3AF7B059721035D7211396 7A2ED64DEE0E78A00AAD097258650332 A965FC489A3FED2DB3AA9AF48DD32AC3 69B57CA0DB0D5B548FA0C2F6965D2C5B 4622DC977286B6E0305FD9F07CBC5983 82BF3CAB0D70F2CD59AA5FCB370CFFCF FFA8A8CAE2359FE9BE35862AF245FD30 D6441A6B8991DD1B8BF81C149C317FD6 55B3C67BECEF93826555ED07E87A9618 47A142059C42E32685279D15A071DFBA D5C59BC24628769C1691D77AEC24DAFA 76B2FEB51C40EE1AB31A7E0A39241A6B
23089CCB
FE500200105AA2CBD85DD33A5D1EF860 2F11A15F254061F89CE538CBA274A185 FE0A087693CC62B800CFA1645F9F2896 4FE79766B1CFF048BF9E38ED3239D0D4 0D0954FEC46799E451E265AD2D8F5C09 1D26229977F83AD7FA9FD86245D2F578 6AD0C0FB79AA325A95917C885B87DB1F 273F88EE9B7DB18F69263BC710C29C3C 69294C85BC5A3F672FA966AA43C90AA4 5EF596139D9D61C965C557BB25D3EA2E D73BACA459EFFEEFA8AB2814F56E841B 31E40DBDB97758FDDD6698A686C919C2 07C5D67B6E350F7928024D614C63BB8B A99F74C4D9674303FB37ECD0CE540249 9784EDC04B215EF67B1B5515C2E671D2 60C48303C9DB498C6444AAE181111C84 9C3E908D4F5618FCB50926FC3FBD4A67 56EFEF9A1E9C9808652AE01466FFF6E3 E9DB555FFAC91106F171E05D358A7627 74ACA513F578036FD8078DCCCB439018 F6D8CE7C7938EAC5A45EFCE2409A44FD 042547D3FD16E846661909A377B1CD42 54BFE51B1939A4FF5297C5A9FF7B8F4E D6112DAD5D4C3D88E2E128D5824802DC 75514B3659870BD56B1CD470F846CEEA 6D2A23AC696741F16142A13F490D47AE 2906EFAA0735F991D69FB88D7AD4CFA5 40A1AAFA5C7F6ECBCEFBBD9CDABFC0D7 89E3CCA6DE3042ECDF524233218C419A 8A3C187F2551A480D27DB9C876F672EF 39D2BC8F8B95B70A84F75D24C54D6255 A2F8751A38FCC64EEA0896DE76CEC58D 899EFA8B20AF3CFC579C3614D5A95E2C 6EB9A20486111A80B24712D3CC50D3E1 67A5C7089A63EE6FAF1C60DF6357F881 C4E2AFDC58C691C7083D7639DCCE5E1D FFF0B41EF577BCB84CC1803D7124D398
CD5B6F97
See below
@@ -570,13 +570,13 @@ answer = BA0D89B5F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773 - + - + @@ -594,13 +594,13 @@ answer = BA0D89B5F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773 - + - + @@ -609,34 +609,34 @@ answer = BA0D89B5F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773
7) Client computes random 2048-bit number b (using a sufficient amount of entropy) and sends the server a message

First, generate a secure random 2048-bit number b:

-
b = 47C6293E96DCA931575A926C2BA7DB887F7463B4E5A5C54AAE9D693B1359D618B40F264DF4AC47F2CC6EFBC6DA31EDA8779E4B9654898ADF0632BBB707709C5395B6930F4076EFB7FBF09F47AA0E89D784C81161F1AC13FE051E996631586C3C50688C90B00A549F129DF9F42472E4F596A9F3547B9C4B94C0D7BA9CDBA8A006E1F4965BAB3841CA6B77CF7BC1107B8DADCA5BBBA8B913B57F1B2C87298E2B3F4C3D83F76514447739A58311C18356B57A3793CBD57812386D32961ECBF32DCD574A202106E18E41D24F75EDC80D66795FB4B4825D34CD16E5F02578613593751BB2BA05FE48FE6048F68CE9D28E91C6BA686B7F3E6F7E09B661FC54809DA290
+
b = 93831429A46135EDDDD7FA9F99A950A8F978D0A68E8D7B157E1E15BF5491C86C19F72A34ED3AD9D6E4135149055ACE071B83C077005A7E13DD657933D6F456BAD726BBF52A6245236DFB4C1C4E9B94286A2B8B7E597B890E3274939AD16CD51E9C42F574BCD2B1328CBE1B82E731ABCD8CDD751A74454F23461C0C7A5A939512B0BAC1D304D921ECDFCA0024D5232200E0BE5DB9EC5FCD7D0544BE0DC87C78585DA374636733153DFD9B795E59696EC94E5B5C3DDC26EA57FF31E0ADE45E274904EAC9749C8E4C5CEE0B8A4D568FE53798A7B12390B70FF3B5420FF8737B03D86AA79A318894BC57BA78AB65CC9EC4362290B3DE859A52A83485BE9F3CC59DE9

Then compute g_b = pow(g, b) mod dh_prime

-
g_b = BC6AF6A9EFC35949F0F6695B7148242A282D45E2F28BCE2184414F0E1210C9179ADCB715964979BDE3101270BBF8FDB8EF17DE5ADC25386293668D13580CB275A7F56A14140E9110EAD1D5C22F02159CFFBCF8C113E57A48E4F8C2368B282133043B92E9817C967BB4F562AABEBD0FEF8DB3E87D1653BD3835C2906A593EF384F209A564C0BFBCB7E036141C8F9F1A48F42FBFE2A5090BBD95E32E0C6990C7BE974BD9A9C1EB983917A602EA6ADBA03582899F8DA52F2E588B91AF45D1703AEADE35232DA9A0BAC3EE8DD7A8BE5FAECC1AC0A2C24C951A717A8E07A1793995644B60F96F769FD08655D6154F472D74B176834D656C48FC3F30C9A1820729CD5B
+
g_b = A19FC9C0AB9D0660D1FC2A6FA650B68422641BE7BD061CC7D1F909B12DF949E884D2FCD2F97E777C6583577F57F488AA8CEBF3F05C38194F9B9D17874D33E6ED37A5CBE1E53693C99A03137344CD3BE2BF92090DB52AB1FDA3825E879353A78BF6BC1C890301518C1E4E86A5B183A0B3A7C6F99AC6AC57DC42DCA8CE3FD1CE726F07D68AF73D5845CC0FD7746D11037D8BE9AF2F6B0726FDA1CEB97F309653E97CD36F321DCD7829ED9C9BCD1799C8A19F39F721358AC0581CE7BFA95BE2BD840FA03888ED2A04745B2910E5289800A42B3A6569CE9EAD24E7ED51E44D4D1ACE7F2C121B228E584E26D698D613ECC0CCAEE72E9ACA01BF3901D94027327FD1C1
7.1) generation of encrypted_data

Generated payload (excluding transport headers/trailers):

-
0000 | 54 B6 43 66 F6 08 5A 66 81 25 75 E2 81 12 E1 29
-0010 | 9D 0F 62 6E 0E 48 CD 96 A1 86 60 61 97 46 58 A4
-0020 | 30 BD 77 33 00 00 00 00 00 00 00 00 FE 00 01 00
-0030 | BC 6A F6 A9 EF C3 59 49 F0 F6 69 5B 71 48 24 2A
-0040 | 28 2D 45 E2 F2 8B CE 21 84 41 4F 0E 12 10 C9 17
-0050 | 9A DC B7 15 96 49 79 BD E3 10 12 70 BB F8 FD B8
-0060 | EF 17 DE 5A DC 25 38 62 93 66 8D 13 58 0C B2 75
-0070 | A7 F5 6A 14 14 0E 91 10 EA D1 D5 C2 2F 02 15 9C
-0080 | FF BC F8 C1 13 E5 7A 48 E4 F8 C2 36 8B 28 21 33
-0090 | 04 3B 92 E9 81 7C 96 7B B4 F5 62 AA BE BD 0F EF
-00A0 | 8D B3 E8 7D 16 53 BD 38 35 C2 90 6A 59 3E F3 84
-00B0 | F2 09 A5 64 C0 BF BC B7 E0 36 14 1C 8F 9F 1A 48
-00C0 | F4 2F BF E2 A5 09 0B BD 95 E3 2E 0C 69 90 C7 BE
-00D0 | 97 4B D9 A9 C1 EB 98 39 17 A6 02 EA 6A DB A0 35
-00E0 | 82 89 9F 8D A5 2F 2E 58 8B 91 AF 45 D1 70 3A EA
-00F0 | DE 35 23 2D A9 A0 BA C3 EE 8D D7 A8 BE 5F AE CC
-0100 | 1A C0 A2 C2 4C 95 1A 71 7A 8E 07 A1 79 39 95 64
-0110 | 4B 60 F9 6F 76 9F D0 86 55 D6 15 4F 47 2D 74 B1
-0120 | 76 83 4D 65 6C 48 FC 3F 30 C9 A1 82 07 29 CD 5B
+
0000 | 54 B6 43 66 50 04 22 80 E4 B6 7C 30 77 D4 A0 C1
+0010 | 2D 4D 1E C1 F2 E4 63 9D 99 B8 10 5C A2 0D 76 A0
+0020 | 5F D1 1F 84 00 00 00 00 00 00 00 00 FE 00 01 00
+0030 | A1 9F C9 C0 AB 9D 06 60 D1 FC 2A 6F A6 50 B6 84
+0040 | 22 64 1B E7 BD 06 1C C7 D1 F9 09 B1 2D F9 49 E8
+0050 | 84 D2 FC D2 F9 7E 77 7C 65 83 57 7F 57 F4 88 AA
+0060 | 8C EB F3 F0 5C 38 19 4F 9B 9D 17 87 4D 33 E6 ED
+0070 | 37 A5 CB E1 E5 36 93 C9 9A 03 13 73 44 CD 3B E2
+0080 | BF 92 09 0D B5 2A B1 FD A3 82 5E 87 93 53 A7 8B
+0090 | F6 BC 1C 89 03 01 51 8C 1E 4E 86 A5 B1 83 A0 B3
+00A0 | A7 C6 F9 9A C6 AC 57 DC 42 DC A8 CE 3F D1 CE 72
+00B0 | 6F 07 D6 8A F7 3D 58 45 CC 0F D7 74 6D 11 03 7D
+00C0 | 8B E9 AF 2F 6B 07 26 FD A1 CE B9 7F 30 96 53 E9
+00D0 | 7C D3 6F 32 1D CD 78 29 ED 9C 9B CD 17 99 C8 A1
+00E0 | 9F 39 F7 21 35 8A C0 58 1C E7 BF A9 5B E2 BD 84
+00F0 | 0F A0 38 88 ED 2A 04 74 5B 29 10 E5 28 98 00 A4
+0100 | 2B 3A 65 69 CE 9E AD 24 E7 ED 51 E4 4D 4D 1A CE
+0110 | 7F 2C 12 1B 22 8E 58 4E 26 D6 98 D6 13 EC C0 CC
+0120 | AE E7 2E 9A CA 01 BF 39 01 D9 40 27 32 7F D1 C1

Payload (de)serialization:

client_DH_inner_data#6643b654 nonce:int128 server_nonce:int128 retry_id:long g_b:string = Client_DH_Inner_Data;
nonce 4, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Value generated by client in Step 1
server_nonce 20, 160E48CD96A1866061974658A430BD7733F2E4639D99B8105CA20D76A05FD11F84 Value received from server in Step 2
g_a 300, 260FE00010032F36F957997386EAF11A538 C81CFBAA3BEF08528257C8D1E2BD9BE5 359D00A6D20C56E74DE8E9E245451B2C B4A16CD58BA711F076848CB61779AFE8 760D2F60BC99886887ABE04E8EB616E2 3EA0015467E98E35D6EC3D2A01E6523E C0CB5D75E9F6EBAC67C9131EE89BD918 28F7C1A727D0AB19888E826E4A08B121 D3AC3D8450FC53FE9C35C38908127929 7D5912B7878E071F7BD14D7916BFFFD8 C402C106CD8784C12EFC79ECF20F65AB AEF8E72C8878BF8BC21418CB406775CE A752671EAF6DAB7ABCB0692A93180A93 906A911FFF6AD161433630897F18CC5A 7D4CBEAF20793336756FDE2098F001CF E820A6D0FB863E873DAA54E95269F50C
FF992263
FE000100AF72F3963FDBA1665B55447F D1D6E0085A7B44999E834CE16D600DA9 7DD44E70D4AFE2C8BDD51B7B1CD921D5 66A9D89CAE5CA7BF4C88DA694EAEC3EC A1A938FE626D3A1D2ED84D9404ABC37E D8629A638F8591F441A21F4BE3388FDE 34B271C9692F2EBD1F3BAB1A6CE391A0 401D3F0417FFF96609178D4CF3D3CE15 64264DD6266719A559BB5E40A6B69955 BBBE32F0CFB7BDAA0B3A52CD1A6A72B8 7C9EE66495C1ACCCA3BDA8299229D004 5D59F9795BD3B38FC7A54EE590200E95 EE7C739EA80ADEE55649226009BC14D3 6797613DC4220B126631A41371739FD6 3F3FAE3E5219B9164E45EA8BFEBF57B2 39655B1745D73065C05E7A3DD69F0331
AFF4B59E
g_a diffie-hellman parameter
server_time 560, 48D3CA166 (1721842829 in decimal)B23FA166 (1721843634 in decimal) Server time
@@ -658,19 +658,19 @@ answer = BA0D89B5F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773 - + - + - + @@ -684,47 +684,47 @@ answer = BA0D89B5F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD773

The serialization of Client_DH_Inner_Data produces a string data. This is used to generate encrypted_data as specified in step 6, using the following inputs:

-
data = 54B64366F6085A66812575E28112E1299D0F626E0E48CD96A1866061974658A430BD77330000000000000000FE000100BC6AF6A9EFC35949F0F6695B7148242A282D45E2F28BCE2184414F0E1210C9179ADCB715964979BDE3101270BBF8FDB8EF17DE5ADC25386293668D13580CB275A7F56A14140E9110EAD1D5C22F02159CFFBCF8C113E57A48E4F8C2368B282133043B92E9817C967BB4F562AABEBD0FEF8DB3E87D1653BD3835C2906A593EF384F209A564C0BFBCB7E036141C8F9F1A48F42FBFE2A5090BBD95E32E0C6990C7BE974BD9A9C1EB983917A602EA6ADBA03582899F8DA52F2E588B91AF45D1703AEADE35232DA9A0BAC3EE8DD7A8BE5FAECC1AC0A2C24C951A717A8E07A1793995644B60F96F769FD08655D6154F472D74B176834D656C48FC3F30C9A1820729CD5B
-padding = DAE32D43BBB2AF152A9A7456
-tmp_aes_key = 174BB7DE1552D7E4A81205A0A423C492A6935F82DF6DC6334CAE2C306CD60137
-tmp_aes_iv = 44C5026626D067174BA9CDFDCF7D7091E4F40F256F7FE12A8C857F3581EC6A3B
+
data = 54B6436650042280E4B67C3077D4A0C12D4D1EC1F2E4639D99B8105CA20D76A05FD11F840000000000000000FE000100A19FC9C0AB9D0660D1FC2A6FA650B68422641BE7BD061CC7D1F909B12DF949E884D2FCD2F97E777C6583577F57F488AA8CEBF3F05C38194F9B9D17874D33E6ED37A5CBE1E53693C99A03137344CD3BE2BF92090DB52AB1FDA3825E879353A78BF6BC1C890301518C1E4E86A5B183A0B3A7C6F99AC6AC57DC42DCA8CE3FD1CE726F07D68AF73D5845CC0FD7746D11037D8BE9AF2F6B0726FDA1CEB97F309653E97CD36F321DCD7829ED9C9BCD1799C8A19F39F721358AC0581CE7BFA95BE2BD840FA03888ED2A04745B2910E5289800A42B3A6569CE9EAD24E7ED51E44D4D1ACE7F2C121B228E584E26D698D613ECC0CCAEE72E9ACA01BF3901D94027327FD1C1
+padding = B08362F89D08E0945C49D4B6
+tmp_aes_key = 0862009CDA343B604C16E1FB67162F4A6E0328779435AE8B32B844D8B8AE1B27
+tmp_aes_iv = D322BF7B0FE3405722AE697F94816E143A5EB539D3129610D71EA71C3C0C1014

Process:

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);

Output:

-
encrypted_data = DBC5D7D540BD682F97D3F0E7A4807759E7EF315D17972BBB694B9A7A857EDDF9B937312FAA6CA829F8FAE60FBBAD1ADFD03643DCB9591A1A3E73AE09DC2692DCD9E505D055EEACC482C8636058745323BCB1F2934D8D6DAFB8C1FABE02B55B6F65113F29B7B5FC1C66E7CC9426803AD2706820DF20B7E150C3E60A1521067106E8D79842186ABDCE37055658FF056FA02A332611C31A8BC501D8E10986E24DE9D27EE31E57B40E1B9841B1B52734CDDD2227B7DD144AC7C0EC8917160092AC385C122E2CD9D7CD728DF982B12B2619DA7871302BE67C877490FF798A7FAD49FCABFF72B56991C6BB4CC23B04AC3A3E3689DD76940152D717AAE842916FD174451809CCE5B30FEFE196DC0D2E839CE55653B206D7EE292C609F2A94CB171AB953751ABEA675BC5BD148358E68E780291C79840DBC609B09D2AF1684012DB2564839E3ED2CCE13E25E506C4BE5E1A25C29
+
encrypted_data = 65DD9E82DAF5DC0BAE54B8E1A723406231C580667F99E9518EC40A39E8802005E98ADAC58E1C35E5B7BE7032B707818307FD5518D88BEC9AC84C57CA24813180AE0DDF16BE8AD5F03FB71E3C7958F5FA65995BAFF21375B309E52870BBE1C4D530B60983C584D3E1F6D91342CB6B22BB843B97825C9FFD0482F19055202254B1A8E5DBC1B7A40CC673845423358537D363B70F56466B3BC197FBCC15A336688F64FFE8072D8FF7BA9F1CEDC9E7A3EE4680522A9DE52B154D9528C2CE14A68ED1353E4657A386F758FE85A341A37C4A7451B1B1539D47CD846CC401B190E81F9D593D377E8B5313DF39A55230D69C983475231133456F645C69963F2C9E0EFC214577A3DFA62A2BF28E81439030A094627F3CC56127B6661EEE5247AE5D2FCA3BE86B07A43B434F8A474DBB5A0B66CDEE80AE6406A7D0E791A9F37AE5F9459C07D429C601A1352485D6AC5369F6AD623A

The length of the final string is 336 bytes.

7.2) set_client_DH_params query

Sent payload (excluding transport headers/trailers):

-
0000 | 00 00 00 00 00 00 00 00 A0 10 07 00 8D 3C A1 66
-0010 | 78 01 00 00 1F 5F 04 F5 F6 08 5A 66 81 25 75 E2
-0020 | 81 12 E1 29 9D 0F 62 6E 0E 48 CD 96 A1 86 60 61
-0030 | 97 46 58 A4 30 BD 77 33 FE 50 01 00 DB C5 D7 D5
-0040 | 40 BD 68 2F 97 D3 F0 E7 A4 80 77 59 E7 EF 31 5D
-0050 | 17 97 2B BB 69 4B 9A 7A 85 7E DD F9 B9 37 31 2F
-0060 | AA 6C A8 29 F8 FA E6 0F BB AD 1A DF D0 36 43 DC
-0070 | B9 59 1A 1A 3E 73 AE 09 DC 26 92 DC D9 E5 05 D0
-0080 | 55 EE AC C4 82 C8 63 60 58 74 53 23 BC B1 F2 93
-0090 | 4D 8D 6D AF B8 C1 FA BE 02 B5 5B 6F 65 11 3F 29
-00A0 | B7 B5 FC 1C 66 E7 CC 94 26 80 3A D2 70 68 20 DF
-00B0 | 20 B7 E1 50 C3 E6 0A 15 21 06 71 06 E8 D7 98 42
-00C0 | 18 6A BD CE 37 05 56 58 FF 05 6F A0 2A 33 26 11
-00D0 | C3 1A 8B C5 01 D8 E1 09 86 E2 4D E9 D2 7E E3 1E
-00E0 | 57 B4 0E 1B 98 41 B1 B5 27 34 CD DD 22 27 B7 DD
-00F0 | 14 4A C7 C0 EC 89 17 16 00 92 AC 38 5C 12 2E 2C
-0100 | D9 D7 CD 72 8D F9 82 B1 2B 26 19 DA 78 71 30 2B
-0110 | E6 7C 87 74 90 FF 79 8A 7F AD 49 FC AB FF 72 B5
-0120 | 69 91 C6 BB 4C C2 3B 04 AC 3A 3E 36 89 DD 76 94
-0130 | 01 52 D7 17 AA E8 42 91 6F D1 74 45 18 09 CC E5
-0140 | B3 0F EF E1 96 DC 0D 2E 83 9C E5 56 53 B2 06 D7
-0150 | EE 29 2C 60 9F 2A 94 CB 17 1A B9 53 75 1A BE A6
-0160 | 75 BC 5B D1 48 35 8E 68 E7 80 29 1C 79 84 0D BC
-0170 | 60 9B 09 D2 AF 16 84 01 2D B2 56 48 39 E3 ED 2C
-0180 | CE 13 E2 5E 50 6C 4B E5 E1 A2 5C 29
+
0000 | 00 00 00 00 00 00 00 00 34 5A 00 00 B2 3F A1 66
+0010 | 78 01 00 00 1F 5F 04 F5 50 04 22 80 E4 B6 7C 30
+0020 | 77 D4 A0 C1 2D 4D 1E C1 F2 E4 63 9D 99 B8 10 5C
+0030 | A2 0D 76 A0 5F D1 1F 84 FE 50 01 00 65 DD 9E 82
+0040 | DA F5 DC 0B AE 54 B8 E1 A7 23 40 62 31 C5 80 66
+0050 | 7F 99 E9 51 8E C4 0A 39 E8 80 20 05 E9 8A DA C5
+0060 | 8E 1C 35 E5 B7 BE 70 32 B7 07 81 83 07 FD 55 18
+0070 | D8 8B EC 9A C8 4C 57 CA 24 81 31 80 AE 0D DF 16
+0080 | BE 8A D5 F0 3F B7 1E 3C 79 58 F5 FA 65 99 5B AF
+0090 | F2 13 75 B3 09 E5 28 70 BB E1 C4 D5 30 B6 09 83
+00A0 | C5 84 D3 E1 F6 D9 13 42 CB 6B 22 BB 84 3B 97 82
+00B0 | 5C 9F FD 04 82 F1 90 55 20 22 54 B1 A8 E5 DB C1
+00C0 | B7 A4 0C C6 73 84 54 23 35 85 37 D3 63 B7 0F 56
+00D0 | 46 6B 3B C1 97 FB CC 15 A3 36 68 8F 64 FF E8 07
+00E0 | 2D 8F F7 BA 9F 1C ED C9 E7 A3 EE 46 80 52 2A 9D
+00F0 | E5 2B 15 4D 95 28 C2 CE 14 A6 8E D1 35 3E 46 57
+0100 | A3 86 F7 58 FE 85 A3 41 A3 7C 4A 74 51 B1 B1 53
+0110 | 9D 47 CD 84 6C C4 01 B1 90 E8 1F 9D 59 3D 37 7E
+0120 | 8B 53 13 DF 39 A5 52 30 D6 9C 98 34 75 23 11 33
+0130 | 45 6F 64 5C 69 96 3F 2C 9E 0E FC 21 45 77 A3 DF
+0140 | A6 2A 2B F2 8E 81 43 90 30 A0 94 62 7F 3C C5 61
+0150 | 27 B6 66 1E EE 52 47 AE 5D 2F CA 3B E8 6B 07 A4
+0160 | 3B 43 4F 8A 47 4D BB 5A 0B 66 CD EE 80 AE 64 06
+0170 | A7 D0 E7 91 A9 F3 7A E5 F9 45 9C 07 D4 29 C6 01
+0180 | A1 35 24 85 D6 AC 53 69 F6 AD 62 3A

Payload (de)serialization:

set_client_DH_params#f5045f1f nonce:int128 server_nonce:int128 encrypted_data:string = Set_client_DH_params_answer;
nonce 4, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Value generated by client in Step 1
server_nonce 20, 160E48CD96A1866061974658A430BD7733F2E4639D99B8105CA20D76A05FD11F84 Value received from server in Step 2
g_b 36, 260FE000100BC6AF6A9EFC35949F0F6695B 7148242A282D45E2F28BCE2184414F0E 1210C9179ADCB715964979BDE3101270 BBF8FDB8EF17DE5ADC25386293668D13 580CB275A7F56A14140E9110EAD1D5C2 2F02159CFFBCF8C113E57A48E4F8C236 8B282133043B92E9817C967BB4F562AA BEBD0FEF8DB3E87D1653BD3835C2906A 593EF384F209A564C0BFBCB7E036141C 8F9F1A48F42FBFE2A5090BBD95E32E0C 6990C7BE974BD9A9C1EB983917A602EA 6ADBA03582899F8DA52F2E588B91AF45 D1703AEADE35232DA9A0BAC3EE8DD7A8 BE5FAECC1AC0A2C24C951A717A8E07A1 793995644B60F96F769FD08655D6154F 472D74B176834D656C48FC3F30C9A182
0729CD5B
FE000100A19FC9C0AB9D0660D1FC2A6F A650B68422641BE7BD061CC7D1F909B1 2DF949E884D2FCD2F97E777C6583577F 57F488AA8CEBF3F05C38194F9B9D1787 4D33E6ED37A5CBE1E53693C99A031373 44CD3BE2BF92090DB52AB1FDA3825E87 9353A78BF6BC1C890301518C1E4E86A5 B183A0B3A7C6F99AC6AC57DC42DCA8CE 3FD1CE726F07D68AF73D5845CC0FD774 6D11037D8BE9AF2F6B0726FDA1CEB97F 309653E97CD36F321DCD7829ED9C9BCD 1799C8A19F39F721358AC0581CE7BFA9 5BE2BD840FA03888ED2A04745B2910E5 289800A42B3A6569CE9EAD24E7ED51E4 4D4D1ACE7F2C121B228E584E26D698D6 13ECC0CCAEE72E9ACA01BF3901D94027
327FD1C1
Single-byte prefix denoting length, a 256-byte (2048-bit) string, and zero bytes of padding
@@ -746,7 +746,7 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);< - + @@ -764,19 +764,19 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);< - + - + - + @@ -785,17 +785,17 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);<
8) Auth key generation

The client computes the auth_key using formula g_a^b mod dh_prime:

-
auth_key = B21BC86B00EFACE4D700F53D8D9B9C30831CEF75BAED9A3CD1A2CEA3929D9359DF321456E5734F9E45B2136A82621DC20666DCF1261992CF69F94CF8A4C9897FBA6F3D31FDBD370327ECD661BAF577774F3908A12C1A5ABAABB6ED2A3B32B97AD0EB32F0AD57E9A33711B565864D92A9D8455B667FAEA42885C4E66BE527662892C5C9CC657156CEF4CC798E2EEF98BB0BF2E1671FC083C35F9E813848EE01967CEDF40877D5233F16E63EAB044F0099FCD251D5930DF83D6EAB15682B44069C399368FF21BD99377C4921C8BDB35E4640AD071AD28D6E0C891364122654D6116945B9C050119DAAA055D1AE61D52709713DD9B6D894548402F6A05578DCD5F7
+
auth_key = 7E5156146BF2D2DDE7418F5C735C5F082962E97EF2B9B04670CD5FB3D7A94251D285D0076530C55AE95E214271371E4DB14A1CD9139C0C06E3E094C089C536C4E09CF0FDA412F6E8EA118AF0500CC2F52E1999EB80286E3A0E96E975D02DEA483171812CE30E33DF2FB30B684F4338C80BBB8EC73373CCE122DF4EEC43487720D6606C4825D17FB08EB103056D65AB77177C2B182714082187325AC1ABEA620C2FEF4F8E33B43DDF9A826C0E58657DEFC195461CA906600C66102E2F61C773E92D00FA00C37FA9A424467006BEA612364A046F40B64681677C1E1C144B8D7C60255747A1E99284D98ACDAC8DD05470AEB777E371288A5E7285AB82CB39F736A5
9) Final server reply

The server verifies and confirms that auth_key_hash is unique: since it's unique, it replies with the following:

Received payload (excluding transport headers/trailers):

-
0000 | 00 00 00 00 00 00 00 00 01 48 34 6A 8E 3C A1 66
-0010 | 38 00 00 00 34 F7 CB 3B F6 08 5A 66 81 25 75 E2
-0020 | 81 12 E1 29 9D 0F 62 6E 0E 48 CD 96 A1 86 60 61
-0030 | 97 46 58 A4 30 BD 77 33 62 45 C2 E2 B1 61 A5 D3
-0040 | 38 1A 77 0D 75 66 6C 2E
+
0000 | 00 00 00 00 00 00 00 00 01 24 35 2E B3 3F A1 66
+0010 | 34 00 00 00 34 F7 CB 3B 50 04 22 80 E4 B6 7C 30
+0020 | 77 D4 A0 C1 2D 4D 1E C1 F2 E4 63 9D 99 B8 10 5C
+0030 | A2 0D 76 A0 5F D1 1F 84 02 19 CE AD 56 AF EB A2
+0040 | C0 3B 7C 92 B3 63 97 D0

Payload (de)serialization:

dh_gen_ok#3bcbf734 nonce:int128 server_nonce:int128 new_nonce_hash1:int128 = Set_client_DH_params_answer;
message_id 8, 8A01007008D3CA166345A0000B23FA166 Message ID generated as specified here » (unixtime() << 32) + (N*4)
nonce 24, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Value generated by client in Step 1
server_nonce 40, 160E48CD96A1866061974658A430BD7733F2E4639D99B8105CA20D76A05FD11F84 Value received from server in Step 2
encrypted_data 56, 340FE500100DBC5D7D540BD682F97D3F0E7 A4807759E7EF315D17972BBB694B9A7A 857EDDF9B937312FAA6CA829F8FAE60F BBAD1ADFD03643DCB9591A1A3E73AE09 DC2692DCD9E505D055EEACC482C86360 58745323BCB1F2934D8D6DAFB8C1FABE 02B55B6F65113F29B7B5FC1C66E7CC94 26803AD2706820DF20B7E150C3E60A15 21067106E8D79842186ABDCE37055658 FF056FA02A332611C31A8BC501D8E109 86E24DE9D27EE31E57B40E1B9841B1B5 2734CDDD2227B7DD144AC7C0EC891716 0092AC385C122E2CD9D7CD728DF982B1 2B2619DA7871302BE67C877490FF798A 7FAD49FCABFF72B56991C6BB4CC23B04 AC3A3E3689DD76940152D717AAE84291 6FD174451809CCE5B30FEFE196DC0D2E 839CE55653B206D7EE292C609F2A94CB 171AB953751ABEA675BC5BD148358E68 E780291C79840DBC609B09D2AF168401 2DB2564839E3ED2CCE13E25E506C4BE5
E1A25C29
FE50010065DD9E82DAF5DC0BAE54B8E1 A723406231C580667F99E9518EC40A39 E8802005E98ADAC58E1C35E5B7BE7032 B707818307FD5518D88BEC9AC84C57CA 24813180AE0DDF16BE8AD5F03FB71E3C 7958F5FA65995BAFF21375B309E52870 BBE1C4D530B60983C584D3E1F6D91342 CB6B22BB843B97825C9FFD0482F19055 202254B1A8E5DBC1B7A40CC673845423 358537D363B70F56466B3BC197FBCC15 A336688F64FFE8072D8FF7BA9F1CEDC9 E7A3EE4680522A9DE52B154D9528C2CE 14A68ED1353E4657A386F758FE85A341 A37C4A7451B1B1539D47CD846CC401B1 90E81F9D593D377E8B5313DF39A55230 D69C983475231133456F645C69963F2C 9E0EFC214577A3DFA62A2BF28E814390 30A094627F3CC56127B6661EEE5247AE 5D2FCA3BE86B07A43B434F8A474DBB5A 0B66CDEE80AE6406A7D0E791A9F37AE5 F9459C07D429C601A1352485D6AC5369
F6AD623A
Encrypted client_DH_inner_data generated previously, serialized as a TL byte string
@@ -817,13 +817,13 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);< - + - + @@ -835,19 +835,19 @@ encrypted_data := AES256_ige_encrypt (data_with_hash, tmp_aes_key, tmp_aes_iv);< - + - + - + diff --git a/data/web/corefork.telegram.org/type/PrivacyKey.html b/data/web/corefork.telegram.org/type/PrivacyKey.html index e7fb324497..2eb97f113e 100644 --- a/data/web/corefork.telegram.org/type/PrivacyKey.html +++ b/data/web/corefork.telegram.org/type/PrivacyKey.html @@ -78,7 +78,7 @@ - +
message_id 8, 80148346A8E3CA1660124352EB33FA166 Message ID generated as specified here » (unixtime() << 32) + (N*4)
message_length 16, 438000000 (56 in decimal)34000000 (52 in decimal) Message body length
nonce 24, 16F6085A66812575E28112E1299D0F626E50042280E4B67C3077D4A0C12D4D1EC1 Value generated by client in Step 1
server_nonce 40, 160E48CD96A1866061974658A430BD7733F2E4639D99B8105CA20D76A05FD11F84 Value received from server in Step 2
new_nonce_hash1 56, 166245C2E2B161A5D3381A770D75666C2E0219CEAD56AFEBA2C03B7C92B36397D0 The 128 lower-order bits of SHA1 of the byte string derived from the new_nonce string by adding a single byte with the value of 1, 2, or 3, and followed by another 8 bytes with auth_key_aux_hash. Different values are required to prevent an intruder from changing server response dh_gen_ok into dh_gen_retry.
privacyKeyStatusTimestampWhether we can see the last online timestamp of this user.

Note that if we decide to hide our exact last online timestamp to someone and we do not have a Premium subscription, we won't be able to see the exact last online timestamp of any user, including those that do share it with us.
Whether we can see the last online timestamp of this user.

Note that if we decide to hide our exact last online timestamp to someone (i.e., users A, B, C, or all users) and we do not have a Premium subscription, we won't be able to see the exact last online timestamp of those users (A, B, C, or all users), even if those users do share it with us.

If those users do share their exact online status with us, but we can't see it due to the reason mentioned above, the by_me flag of userStatusRecently, userStatusLastWeek, userStatusLastMonth.
privacyKeyChatInvite