{"id":337342,"date":"2022-08-21T21:00:17","date_gmt":"2022-08-21T21:00:17","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=337342"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=337342","title":{"rendered":"<span>\u0412\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430 \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0435 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA<\/span>"},"content":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/adf\/238\/026\/adf238026e47980d9ad59cd1736bc223.png\" width=\"1280\" height=\"720\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/adf\/238\/026\/adf238026e47980d9ad59cd1736bc223.png\"\/><figcaption><\/figcaption><\/figure>\n<p>\u0412\u0441\u0435\u043c \u043d\u0430\u043c \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e, \u0447\u0442\u043e \u0440\u0430\u0441\u043a\u0440\u044b\u0432\u0430\u0435\u043c\u043e\u0441\u0442\u044c \u0441\u0435\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 \u0432 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u0438\u0432\u0435\u0441\u0442\u0438 \u043a \u043f\u043e\u043b\u043d\u043e\u043c\u0443 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044e \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430. \u0412 \u043d\u0430\u0448\u0438\u0445 \u0431\u043e\u043b\u0435\u0435 \u0440\u0430\u043d\u043d\u0438\u0445 \u0441\u0442\u0430\u0442\u044c\u044f\u0445 \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u043b\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/671932\/\" rel=\"noopener noreferrer nofollow\">\u0441\u043b\u0430\u0431\u043e\u0441\u0442\u0438 \u0438 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438<\/a> \u0432 \u0442\u0440\u0430\u043d\u0437\u0430\u043a\u0446\u0438\u044f\u0445 \u0431\u043b\u043e\u043a\u0447\u0435\u0439\u043d\u0430, \u043d\u043e \u0442\u0430\u043a \u0436\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0435 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0442\u0430\u043a \u0436\u0435 \u043f\u0440\u0438\u0432\u043e\u0434\u044f\u0442 \u043a \u043f\u043e\u043b\u043d\u043e\u043c\u0443 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044e \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430.<\/p>\n<h3>\u041f\u043e\u0447\u0435\u043c\u0443 \u0436\u0435 \u044d\u0442\u0438 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA \u043d\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u043c\u0438?<\/h3>\n<blockquote>\n<p>\u041e\u0442\u0432\u0435\u0442 \u043d\u0430 \u044d\u0442\u043e\u0442 \u0432\u043e\u043f\u0440\u043e\u0441 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u0437 \u043e\u0431\u0441\u0443\u0436\u0434\u0430\u0435\u043c\u043e\u0439 \u0442\u0435\u043c\u044b: <a href=\"https:\/\/bitcoin.stackexchange.com\/questions\/38513\/the-shortest-ecdsa-signature\" rel=\"noopener noreferrer nofollow\"><strong>&#171;\u0421\u0430\u043c\u0430\u044f \u043a\u043e\u0440\u043e\u0442\u043a\u0430\u044f \u043f\u043e\u0434\u043f\u0438\u0441\u044c ECDSA&#187; [The shortest ECDSA signature]<\/strong><\/a><\/p>\n<\/blockquote>\n<p>\u0412 \u043f\u0440\u043e\u0448\u043b\u043e\u0439 \u043d\u0430\u0448\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0435: <a href=\"https:\/\/habr.com\/ru\/post\/682220\/\" rel=\"noopener noreferrer nofollow\"><em>&#171;\u0423\u043c\u0435\u043d\u044c\u0448\u0435\u043d\u0438\u0435 \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 \u0447\u0435\u0440\u0435\u0437 \u0441\u043a\u0430\u043b\u044f\u0440\u043d\u043e\u0435 \u0443\u043c\u043d\u043e\u0436\u0435\u043d\u0438\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 ECPy + Google Colab&#187;<\/em><\/a><em> <\/em>\u043c\u044b \u0441\u043e\u0437\u0434\u0430\u043b\u0438 <em>Python<\/em>-\u0441\u043a\u0440\u0438\u043f\u0442: <a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/blob\/main\/08ReducePrivateKey\/maxwell.py\" rel=\"noopener noreferrer nofollow\">maxwell.py<\/a> \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b \u0434\u043b\u044f \u043d\u0430\u0441 \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u0439 \u043f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0439 \u043a\u043b\u044e\u0447<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/69a\/7a0\/b32\/69a7a0b324ac3b1f3e0dc27f0f4130bf.png\" width=\"858\" height=\"334\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/69a\/7a0\/b32\/69a7a0b324ac3b1f3e0dc27f0f4130bf.png\"\/><figcaption><\/figcaption><\/figure>\n<pre><code class=\"python\">(0x3b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63 , 0xc0c686408d517dfd67c2367651380d00d126e4229631fd03f8ff35eef1a61e3c)<\/code><\/pre>\n<blockquote>\n<p>\u041a\u0430\u043a \u043c\u044b \u0437\u043d\u0430\u0435\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b <code>\"R\"<\/code> \u044d\u0442\u043e \u0438 \u0435\u0441\u0442\u044c \u043f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0439 \u043a\u043b\u044e\u0447 \u043e\u0442 \u0441\u0435\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 <code>(Nonce)<\/code><\/p>\n<\/blockquote>\n<p>\u0412\u0437\u0433\u043b\u044f\u043d\u0438\u0442\u0435 \u043d\u0430 Blockchain \u0442\u0440\u0430\u043d\u0437\u0430\u043a\u0446\u0438\u044e: <a href=\"https:\/\/btc.exan.tech\/tx\/11e6b169701a9047f3ddbb9bc4d4ab1a148c430ba4a5929764e97e76031f4ee3\" rel=\"noopener noreferrer nofollow\"><strong>11e6b169701a9047f3ddbb9bc4d4ab1a148c430ba4a5929764e97e76031f4ee3<\/strong><\/a><\/p>\n<h3>RawTX:<\/h3>\n<pre><code class=\"bash\">0100000001afddd5c9f05bd937b24a761606581c0cddd6696e05a25871279f75b7f6cf891f250000005f3c303902153b78ce563f89a0ed9414f5aa28ad0d96d6795f9c6302200a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8012103151033d660dc0ef657f379065cab49932ce4fb626d92e50d4194e026328af853ffffffff010000000000000000016a00000000 <\/code><\/pre>\n<blockquote>\n<p>\u0420\u0430\u0437\u043c\u0435\u0440 \u044d\u0442\u043e\u0439 \u0442\u0440\u0430\u043d\u0437\u0430\u043a\u0446\u0438\u0438 \u0432\u0441\u0435\u0433\u043e \u043b\u0438\u0448\u044c: <code>156 \u0431\u0430\u0439\u0442<\/code><\/p>\n<\/blockquote>\n<h3>\u041a\u0430\u043a \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u0435\u043a \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0435 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA?<\/h3>\n<p>\u0412 \u043a\u0440\u0438\u043f\u0442\u043e\u0430\u043d\u0430\u043b\u0438\u0437\u0435 \u0431\u043b\u043e\u043a\u0447\u0435\u0439\u043d\u0430 \u043a\u0440\u0438\u043f\u0442\u043e\u0432\u0430\u043b\u044e\u0442\u044b Bitcoin \u043c\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 <em>Bas<\/em>h-\u0441\u043a\u0440\u0438\u043f\u0442: <code>btcrecover.sh<\/code><\/p>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/299\/fa2\/616\/299fa2616cbdb8e6df9304862f441ba2.gif\" alt=\"\u041f\u0440\u043e\u0446\u0435\u0441\u0441 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430\" title=\"\u041f\u0440\u043e\u0446\u0435\u0441\u0441 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430\" width=\"1788\" height=\"1004\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/299\/fa2\/616\/299fa2616cbdb8e6df9304862f441ba2.gif\"\/><figcaption>\u041f\u0440\u043e\u0446\u0435\u0441\u0441 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430<\/figcaption><\/figure>\n<h3>Bash-\u0441\u043a\u0440\u0438\u043f\u0442: btcrecover.sh<\/h3>\n<pre><code class=\"bash\">pip2 install -r requirements.txt chmod +x btcrecover.sh    .\/btcrecover.sh 12yysAMhagEm67QCX85p3WQnTUrqcvYVuk    .\/btcrecover.sh 15HvLBX9auG2bJdLCTxSvjvWvdgsW7BvAT <\/code><\/pre>\n<h3>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b:<\/h3>\n<p><code>| privkey : addr |<\/code><\/p>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c\u00a0<a href=\"https:\/\/cryptodeep.ru\/bitaddress.html\" rel=\"noopener noreferrer nofollow\">bitaddress<\/a>\u00a0\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c:  <\/p>\n<pre><code>ac8d0abda1d32aaabff56cb72bc39a998a98779632d7fee83ff452a86a849bc1:12yysAMhagEm67QCX85p3WQnTUrqcvYVuk b6c1238de89e9defea3ea0712e08726e338928ac657c3409ebb93d9a0873797f:15HvLBX9auG2bJdLCTxSvjvWvdgsW7BvAT<\/code><\/pre>\n<h2>\u041f\u0435\u0440\u0435\u0439\u0434\u0435\u043c \u043a \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u0438 \u0438 \u0431\u043e\u043b\u0435\u0435 \u0434\u0435\u0442\u0430\u043b\u044c\u043d\u043e \u0440\u0430\u0437\u0431\u0435\u0440\u0435\u043c \u0432\u0441\u0435 \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u043f\u043e \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044e \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430<\/h2>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c\u00a0<a href=\"https:\/\/github.com\/demining\/TerminalGoogleColab\" rel=\"noopener noreferrer nofollow\"><strong>[TerminalGoogleColab]<\/strong><\/a>.  <\/p>\n<p>\u0412\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0435\u043c <a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/tree\/main\/09BitcoinWalletRecovery\" rel=\"noopener noreferrer nofollow\"><strong>\u00ab09BitcoinWalletRecovery\u00bb<\/strong><\/a>.<\/p>\n<pre><code class=\"bash\">git clone https:\/\/github.com\/demining\/CryptoDeepTools.git  cd CryptoDeepTools\/09BitcoinWalletRecovery\/  ls<\/code><\/pre>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/4e3\/7b8\/f6c\/4e37b8f6cefc8f8d0553f541a5eb8b98.png\" width=\"1271\" height=\"572\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/4e3\/7b8\/f6c\/4e37b8f6cefc8f8d0553f541a5eb8b98.png\"\/><figcaption><\/figcaption><\/figure>\n<h3>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u0432\u0441\u0435 \u043d\u0443\u0436\u043d\u044b\u0435 \u043c\u043e\u0434\u0443\u043b\u0438:<\/h3>\n<pre><code>bitcoin ecdsa utils base58<\/code><\/pre>\n<hr\/>\n<pre><code class=\"bash\">pip2 install -r requirements.txt<\/code><\/pre>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/d5f\/25e\/5b1\/d5f25e5b1b966ff43a48aaf0955ecfcd.png\" width=\"1352\" height=\"651\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/d5f\/25e\/5b1\/d5f25e5b1b966ff43a48aaf0955ecfcd.png\"\/><figcaption><\/figcaption><\/figure>\n<blockquote>\n<p>\u0421 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0441\u043a\u0440\u0438\u043f\u0442\u0430 <a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/blob\/main\/09BitcoinWalletRecovery\/breakECDSA.py\" rel=\"noopener noreferrer nofollow\">breakECDSA.py<\/a> \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0438\u0437 <code>RawTX<\/code> \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b [R, S, Z]<\/p>\n<\/blockquote>\n<pre><code class=\"python\">python2 breakECDSA.py 0100000001afddd5c9f05bd937b24a761606581c0cddd6696e05a25871279f75b7f6cf891f250000005f3c303902153b78ce563f89a0ed9414f5aa28ad0d96d6795f9c6302200a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8012103151033d660dc0ef657f379065cab49932ce4fb626d92e50d4194e026328af853ffffffff010000000000000000016a00000000 > signatures.txt <\/code><\/pre>\n<h3>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d \u0432 \u0444\u0430\u0439\u043b: signatures.txt<\/h3>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c \u0444\u0430\u0439\u043b: <code>PublicKeys.txt<\/code><\/p>\n<pre><code class=\"bash\">cat signatures.txt<\/code><\/pre>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/cd3\/2b9\/9e3\/cd32b99e37cc600ddd3c35965e2a0288.png\" width=\"1344\" height=\"453\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/cd3\/2b9\/9e3\/cd32b99e37cc600ddd3c35965e2a0288.png\"\/><figcaption><\/figcaption><\/figure>\n<pre><code class=\"python\">R = 0x00000000000000000000003b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63 S = 0x0a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8 Z = 0x521a65420faa5386d91b8afcfab68defa02283240b25aeee958b20b36ddcb6de<\/code><\/pre>\n<p>\u041a\u0430\u043a \u043d\u0430\u043c \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e \u0438\u0437 \u043f\u0440\u043e\u0448\u043b\u043e\u0439 \u043d\u0430\u0448\u0435\u0439 <a href=\"https:\/\/habr.com\/ru\/post\/682220\/\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u0438<\/a>, \u043d\u0430\u043c \u0438\u0437\u0432\u0435\u0441\u0442\u0435\u043d <em><u>\u0441\u0435\u043a\u0440\u0435\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447<\/u><\/em> \u043a \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 <em>\u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b<\/em> <code>R<\/code><\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/9df\/b17\/63d\/9dfb1763d978473245abb6cab03e0e48.png\" width=\"1082\" height=\"358\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/9df\/b17\/63d\/9dfb1763d978473245abb6cab03e0e48.png\"\/><figcaption><\/figcaption><\/figure>\n<blockquote>\n<p>\u0412 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 <em><u>\u0441\u0435\u043a\u0440\u0435\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447<\/u><\/em> <code>(Nonce)<\/code>:<\/p>\n<\/blockquote>\n<pre><code class=\"python\">0x7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0 --> 0x3b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63, 0x3f3979bf72ae8202983dc989aec7f2ff2ed91bdd69ce02fc0700ca100e59ddf3 <\/code><\/pre>\n<h3>Signatures:<\/h3>\n<pre><code class=\"python\">K = 0x7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0 R = 0x00000000000000000000003b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63 S = 0x0a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8 Z = 0x521a65420faa5386d91b8afcfab68defa02283240b25aeee958b20b36ddcb6de<\/code><\/pre>\n<blockquote>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043a\u043e\u0433\u0434\u0430 \u043d\u0430\u043c \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <code>[K, R, S, Z<\/code>] \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c <u>\u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447<\/u> \u043f\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u0438 <u>\u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u0435<\/u>\u043a.<\/p>\n<\/blockquote>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"formula\" source=\"Privkey = ((((S * K) - Z) * modinv(R,N)) % N)\" alt=\"Privkey = ((((S * K) - Z) * modinv(R,N)) % N)\" src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/2db\/a14\/ab5\/2dba14ab5cb76228181c68a9403038a7.svg\" width=\"368\" height=\"22\"\/><\/p>\n<p>\u0414\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f <em>Python<\/em>-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u043c: <a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/blob\/main\/09BitcoinWalletRecovery\/calculate.py\" rel=\"noopener noreferrer nofollow\">calculate.py<\/a><\/p>\n<pre><code class=\"python\">def h(n):     return hex(n).replace(\"0x\",\"\")  def extended_gcd(aa, bb):     lastremainder, remainder = abs(aa), abs(bb)     x, lastx, y, lasty = 0, 1, 1, 0     while remainder:         lastremainder, (quotient, remainder) = remainder, divmod(lastremainder, remainder)         x, lastx = lastx - quotient*x, x         y, lasty = lasty - quotient*y, y     return lastremainder, lastx * (-1 if aa &lt; 0 else 1), lasty * (-1 if bb &lt; 0 else 1)  def modinv(a, m):     g, x, y = extended_gcd(a, m)     if g != 1:         raise ValueError     return x % m      N = 0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141   K = 0x7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0 R = 0x00000000000000000000003b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63 S = 0x0a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8 Z = 0x521a65420faa5386d91b8afcfab68defa02283240b25aeee958b20b36ddcb6de   print (h((((S * K) - Z) * modinv(R,N)) % N))<\/code><\/pre>\n<h3>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043c Python-\u0441\u043a\u0440\u0438\u043f\u0442: calculate.py<\/h3>\n<pre><code class=\"bash\">python3 calculate.py<\/code><\/pre>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/502\/645\/324\/502645324ec5666803f791ea3cc3a109.png\" alt=\"PrivKey = b6c1238de89e9defea3ea0712e08726e338928ac657c3409ebb93d9a0873797f\" title=\"PrivKey = b6c1238de89e9defea3ea0712e08726e338928ac657c3409ebb93d9a0873797f\" width=\"1186\" height=\"293\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/502\/645\/324\/502645324ec5666803f791ea3cc3a109.png\"\/><figcaption>PrivKey = b6c1238de89e9defea3ea0712e08726e338928ac657c3409ebb93d9a0873797f<\/figcaption><\/figure>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c\u00a0<a href=\"https:\/\/cryptodeep.ru\/bitaddress.html\" rel=\"noopener noreferrer nofollow\">bitaddress<\/a>\u00a0\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c:  <\/p>\n<pre><code class=\"bash\">ADDR: 15HvLBX9auG2bJdLCTxSvjvWvdgsW7BvAT WIF:  L3LxjEnwKQMFYNYmCGzM1TqnwxRDi8UyRzQpVfmDvk96fYN44oFG HEX:  b6c1238de89e9defea3ea0712e08726e338928ac657c3409ebb93d9a0873797f<\/code><\/pre>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/82b\/5e1\/157\/82b5e115789ac3949bbe28bb975a2826.png\" width=\"842\" height=\"832\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/82b\/5e1\/157\/82b5e115789ac3949bbe28bb975a2826.png\"\/><figcaption><\/figcaption><\/figure>\n<p><strong>\u041f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447 \u043d\u0430\u0439\u0434\u0435\u043d!<\/strong><\/p>\n<p><strong>\u0411\u0438\u0442\u043a\u043e\u0438\u043d \u043a\u043e\u0448\u0435\u043b\u0435\u043a \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d!<\/strong><\/p>\n<figure class=\"bordered full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/50f\/e20\/dbc\/50fe20dbc6d9d6f4a4dbf43c6eaba268.png\" width=\"1626\" height=\"691\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/50f\/e20\/dbc\/50fe20dbc6d9d6f4a4dbf43c6eaba268.png\"\/><figcaption><\/figcaption><\/figure>\n<blockquote>\n<p><code>\u041a\u043e\u0440\u043e\u0442\u043a\u0438\u0435 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA<\/code> &#8212; <em>\u044d\u0442\u043e \u043f\u043e\u0442\u0435\u043d\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0443\u0433\u0440\u043e\u0437\u0430 \u043f\u043e\u0442\u0435\u0440\u0438 \u043c\u043e\u043d\u0435\u0442<\/em> <code>BTC<\/code>, <em>\u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043c\u044b \u043d\u0430\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0432\u0441\u0435\u043c \u0432\u0441\u0435\u0433\u0434\u0430 \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0442\u044c \u041f\u041e \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u043d\u044b\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430.<\/em><\/p>\n<\/blockquote>\n<p>\u0414\u0430\u043d\u043d\u044b\u0439 \u0432\u0438\u0434\u0435\u043e\u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b \u0441\u043e\u0437\u0434\u0430\u043d \u0434\u043b\u044f \u043f\u043e\u0440\u0442\u0430\u043b\u0430\u00a0<a href=\"https:\/\/cryptodeep.ru\/\" rel=\"noopener noreferrer nofollow\"><strong>CRYPTO DEEP TECH<\/strong><\/a>\u00a0\u0434\u043b\u044f \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0435\u043d\u0438\u044f \u0444\u0438\u043d\u0430\u043d\u0441\u043e\u0432\u043e\u0439 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0445 \u0438 \u043a\u0440\u0438\u043f\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0438 \u043d\u0430 \u044d\u043b\u043b\u0438\u043f\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u043a\u0440\u0438\u0432\u044b\u0445\u00a0<code>secp256k1<\/code>\u00a0\u043f\u0440\u043e\u0442\u0438\u0432 \u0441\u043b\u0430\u0431\u044b\u0445 \u043f\u043e\u0434\u043f\u0438\u0441\u0435\u0439\u00a0<code>ECDSA<\/code>\u00a0\u0432 \u043a\u0440\u0438\u043f\u0442\u043e\u0432\u0430\u043b\u044e\u0442\u0435\u00a0<code>BITCOIN<\/code>  <\/p>\n<p><a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/tree\/main\/09BitcoinWalletRecovery\" rel=\"noopener noreferrer nofollow\"><strong>\u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434<\/strong><\/a><\/p>\n<p><a href=\"https:\/\/t.me\/cryptodeeptech\" rel=\"noopener noreferrer nofollow\"><strong>Telegram<\/strong><\/a><strong>:\u00a0<\/strong><a href=\"https:\/\/t.me\/cryptodeeptech\" rel=\"noopener noreferrer nofollow\"><strong><u>https:\/\/t.me\/cryptodeeptech<\/u><\/strong><\/a><\/p>\n<p><a href=\"https:\/\/youtu.be\/xBgjWE5tA7Y\" rel=\"noopener noreferrer nofollow\"><strong>\u0412\u0438\u0434\u0435\u043e\u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b:<\/strong><\/a><strong>\u00a0<\/strong><a href=\"https:\/\/youtu.be\/xBgjWE5tA7Y\" rel=\"noopener noreferrer nofollow\"><strong>https:\/\/youtu.be\/xBgjWE5tA7Y<\/strong><\/a><\/p>\n<p><a href=\"https:\/\/cryptodeep.ru\/shortest-ecdsa-signature\" rel=\"noopener noreferrer nofollow\"><strong>\u0418\u0441\u0442\u043e\u0447\u043d\u0438\u043a: https:\/\/cryptodeep.ru\/shortest-ecdsa-signature<\/strong><\/a><\/p>\n<hr\/>\n<div class=\"tm-iframe_temp\" data-src=\"https:\/\/embedd.srv.habr.com\/iframe\/62fbef36ab11133472440640\" data-style=\"\" id=\"62fbef36ab11133472440640\" width=\"\"><\/div>\n<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"v-portal\" style=\"display:none;\"><\/div>\n<\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/683802\/\"> https:\/\/habr.com\/ru\/post\/683802\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<p>\u0412\u0441\u0435\u043c \u043d\u0430\u043c \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e, \u0447\u0442\u043e \u0440\u0430\u0441\u043a\u0440\u044b\u0432\u0430\u0435\u043c\u043e\u0441\u0442\u044c \u0441\u0435\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 \u0432 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u0438\u0432\u0435\u0441\u0442\u0438 \u043a \u043f\u043e\u043b\u043d\u043e\u043c\u0443 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044e \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430. \u0412 \u043d\u0430\u0448\u0438\u0445 \u0431\u043e\u043b\u0435\u0435 \u0440\u0430\u043d\u043d\u0438\u0445 \u0441\u0442\u0430\u0442\u044c\u044f\u0445 \u043c\u044b \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u043b\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/671932\/\" rel=\"noopener noreferrer nofollow\">\u0441\u043b\u0430\u0431\u043e\u0441\u0442\u0438 \u0438 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0438<\/a> \u0432 \u0442\u0440\u0430\u043d\u0437\u0430\u043a\u0446\u0438\u044f\u0445 \u0431\u043b\u043e\u043a\u0447\u0435\u0439\u043d\u0430, \u043d\u043e \u0442\u0430\u043a \u0436\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0435 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0442\u0430\u043a \u0436\u0435 \u043f\u0440\u0438\u0432\u043e\u0434\u044f\u0442 \u043a \u043f\u043e\u043b\u043d\u043e\u043c\u0443 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044e \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430.<\/p>\n<h3>\u041f\u043e\u0447\u0435\u043c\u0443 \u0436\u0435 \u044d\u0442\u0438 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA \u043d\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u043c\u0438?<\/h3>\n<blockquote>\n<p>\u041e\u0442\u0432\u0435\u0442 \u043d\u0430 \u044d\u0442\u043e\u0442 \u0432\u043e\u043f\u0440\u043e\u0441 \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u0437 \u043e\u0431\u0441\u0443\u0436\u0434\u0430\u0435\u043c\u043e\u0439 \u0442\u0435\u043c\u044b: <a href=\"https:\/\/bitcoin.stackexchange.com\/questions\/38513\/the-shortest-ecdsa-signature\" rel=\"noopener noreferrer nofollow\"><strong>&#171;\u0421\u0430\u043c\u0430\u044f \u043a\u043e\u0440\u043e\u0442\u043a\u0430\u044f \u043f\u043e\u0434\u043f\u0438\u0441\u044c ECDSA&#187; [The shortest ECDSA signature]<\/strong><\/a><\/p>\n<\/blockquote>\n<p>\u0412 \u043f\u0440\u043e\u0448\u043b\u043e\u0439 \u043d\u0430\u0448\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0435: <a href=\"https:\/\/habr.com\/ru\/post\/682220\/\" rel=\"noopener noreferrer nofollow\"><em>&#171;\u0423\u043c\u0435\u043d\u044c\u0448\u0435\u043d\u0438\u0435 \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 \u0447\u0435\u0440\u0435\u0437 \u0441\u043a\u0430\u043b\u044f\u0440\u043d\u043e\u0435 \u0443\u043c\u043d\u043e\u0436\u0435\u043d\u0438\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 ECPy + Google Colab&#187;<\/em><\/a><em> <\/em>\u043c\u044b \u0441\u043e\u0437\u0434\u0430\u043b\u0438 <em>Python<\/em>-\u0441\u043a\u0440\u0438\u043f\u0442: <a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/blob\/main\/08ReducePrivateKey\/maxwell.py\" rel=\"noopener noreferrer nofollow\">maxwell.py<\/a> \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043b \u0434\u043b\u044f \u043d\u0430\u0441 \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u0439 \u043f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0439 \u043a\u043b\u044e\u0447<\/p>\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<pre><code class=\"python\">(0x3b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63 , 0xc0c686408d517dfd67c2367651380d00d126e4229631fd03f8ff35eef1a61e3c)<\/code><\/pre>\n<blockquote>\n<p>\u041a\u0430\u043a \u043c\u044b \u0437\u043d\u0430\u0435\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b <code>\"R\"<\/code> \u044d\u0442\u043e \u0438 \u0435\u0441\u0442\u044c \u043f\u0443\u0431\u043b\u0438\u0447\u043d\u044b\u0439 \u043a\u043b\u044e\u0447 \u043e\u0442 \u0441\u0435\u043a\u0440\u0435\u0442\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 <code>(Nonce)<\/code><\/p>\n<\/blockquote>\n<p>\u0412\u0437\u0433\u043b\u044f\u043d\u0438\u0442\u0435 \u043d\u0430 Blockchain \u0442\u0440\u0430\u043d\u0437\u0430\u043a\u0446\u0438\u044e: <a href=\"https:\/\/btc.exan.tech\/tx\/11e6b169701a9047f3ddbb9bc4d4ab1a148c430ba4a5929764e97e76031f4ee3\" rel=\"noopener noreferrer nofollow\"><strong>11e6b169701a9047f3ddbb9bc4d4ab1a148c430ba4a5929764e97e76031f4ee3<\/strong><\/a><\/p>\n<h3>RawTX:<\/h3>\n<pre><code class=\"bash\">0100000001afddd5c9f05bd937b24a761606581c0cddd6696e05a25871279f75b7f6cf891f250000005f3c303902153b78ce563f89a0ed9414f5aa28ad0d96d6795f9c6302200a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8012103151033d660dc0ef657f379065cab49932ce4fb626d92e50d4194e026328af853ffffffff010000000000000000016a00000000 <\/code><\/pre>\n<blockquote>\n<p>\u0420\u0430\u0437\u043c\u0435\u0440 \u044d\u0442\u043e\u0439 \u0442\u0440\u0430\u043d\u0437\u0430\u043a\u0446\u0438\u0438 \u0432\u0441\u0435\u0433\u043e \u043b\u0438\u0448\u044c: <code>156 \u0431\u0430\u0439\u0442<\/code><\/p>\n<\/blockquote>\n<h3>\u041a\u0430\u043a \u043c\u043e\u0436\u043d\u043e \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u0435\u043a \u0447\u0435\u0440\u0435\u0437 \u043a\u043e\u0440\u043e\u0442\u043a\u0438\u0435 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA?<\/h3>\n<p>\u0412 \u043a\u0440\u0438\u043f\u0442\u043e\u0430\u043d\u0430\u043b\u0438\u0437\u0435 \u0431\u043b\u043e\u043a\u0447\u0435\u0439\u043d\u0430 \u043a\u0440\u0438\u043f\u0442\u043e\u0432\u0430\u043b\u044e\u0442\u044b Bitcoin \u043c\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0439 <em>Bas<\/em>h-\u0441\u043a\u0440\u0438\u043f\u0442: <code>btcrecover.sh<\/code><\/p>\n<figure class=\"bordered full-width\"><figcaption>\u041f\u0440\u043e\u0446\u0435\u0441\u0441 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430<\/figcaption><\/figure>\n<h3>Bash-\u0441\u043a\u0440\u0438\u043f\u0442: btcrecover.sh<\/h3>\n<pre><code class=\"bash\">pip2 install -r requirements.txt chmod +x btcrecover.sh    .\/btcrecover.sh 12yysAMhagEm67QCX85p3WQnTUrqcvYVuk    .\/btcrecover.sh 15HvLBX9auG2bJdLCTxSvjvWvdgsW7BvAT <\/code><\/pre>\n<h3>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u044b:<\/h3>\n<p><code>| privkey : addr |<\/code><\/p>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c\u00a0<a href=\"https:\/\/cryptodeep.ru\/bitaddress.html\" rel=\"noopener noreferrer nofollow\">bitaddress<\/a>\u00a0\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c:  <\/p>\n<pre><code>ac8d0abda1d32aaabff56cb72bc39a998a98779632d7fee83ff452a86a849bc1:12yysAMhagEm67QCX85p3WQnTUrqcvYVuk b6c1238de89e9defea3ea0712e08726e338928ac657c3409ebb93d9a0873797f:15HvLBX9auG2bJdLCTxSvjvWvdgsW7BvAT<\/code><\/pre>\n<h2>\u041f\u0435\u0440\u0435\u0439\u0434\u0435\u043c \u043a \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u0438 \u0438 \u0431\u043e\u043b\u0435\u0435 \u0434\u0435\u0442\u0430\u043b\u044c\u043d\u043e \u0440\u0430\u0437\u0431\u0435\u0440\u0435\u043c \u0432\u0441\u0435 \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u043f\u043e \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044e \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u044c\u043a\u0430<\/h2>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c\u00a0<a href=\"https:\/\/github.com\/demining\/TerminalGoogleColab\" rel=\"noopener noreferrer nofollow\"><strong>[TerminalGoogleColab]<\/strong><\/a>.  <\/p>\n<p>\u0412\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0435\u043c <a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/tree\/main\/09BitcoinWalletRecovery\" rel=\"noopener noreferrer nofollow\"><strong>\u00ab09BitcoinWalletRecovery\u00bb<\/strong><\/a>.<\/p>\n<pre><code class=\"bash\">git clone https:\/\/github.com\/demining\/CryptoDeepTools.git  cd CryptoDeepTools\/09BitcoinWalletRecovery\/  ls<\/code><\/pre>\n<figure class=\"bordered full-width\"><figcaption><\/figcaption><\/figure>\n<h3>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u0432\u0441\u0435 \u043d\u0443\u0436\u043d\u044b\u0435 \u043c\u043e\u0434\u0443\u043b\u0438:<\/h3>\n<pre><code>bitcoin ecdsa utils base58<\/code><\/pre>\n<hr\/>\n<pre><code class=\"bash\">pip2 install -r requirements.txt<\/code><\/pre>\n<figure class=\"bordered full-width\"><figcaption><\/figcaption><\/figure>\n<blockquote>\n<p>\u0421 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0441\u043a\u0440\u0438\u043f\u0442\u0430 <a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/blob\/main\/09BitcoinWalletRecovery\/breakECDSA.py\" rel=\"noopener noreferrer nofollow\">breakECDSA.py<\/a> \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0438\u0437 <code>RawTX<\/code> \u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b [R, S, Z]<\/p>\n<\/blockquote>\n<pre><code class=\"python\">python2 breakECDSA.py 0100000001afddd5c9f05bd937b24a761606581c0cddd6696e05a25871279f75b7f6cf891f250000005f3c303902153b78ce563f89a0ed9414f5aa28ad0d96d6795f9c6302200a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8012103151033d660dc0ef657f379065cab49932ce4fb626d92e50d4194e026328af853ffffffff010000000000000000016a00000000 > signatures.txt <\/code><\/pre>\n<h3>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0431\u0443\u0434\u0435\u0442 \u0441\u043e\u0445\u0440\u0430\u043d\u0435\u043d \u0432 \u0444\u0430\u0439\u043b: signatures.txt<\/h3>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c \u0444\u0430\u0439\u043b: <code>PublicKeys.txt<\/code><\/p>\n<pre><code class=\"bash\">cat signatures.txt<\/code><\/pre>\n<figure class=\"bordered full-width\"><figcaption><\/figcaption><\/figure>\n<pre><code class=\"python\">R = 0x00000000000000000000003b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63 S = 0x0a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8 Z = 0x521a65420faa5386d91b8afcfab68defa02283240b25aeee958b20b36ddcb6de<\/code><\/pre>\n<p>\u041a\u0430\u043a \u043d\u0430\u043c \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e \u0438\u0437 \u043f\u0440\u043e\u0448\u043b\u043e\u0439 \u043d\u0430\u0448\u0435\u0439 <a href=\"https:\/\/habr.com\/ru\/post\/682220\/\" rel=\"noopener noreferrer nofollow\">\u0441\u0442\u0430\u0442\u044c\u0438<\/a>, \u043d\u0430\u043c \u0438\u0437\u0432\u0435\u0441\u0442\u0435\u043d <em><u>\u0441\u0435\u043a\u0440\u0435\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447<\/u><\/em> \u043a \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u0438 <em>\u0441\u0438\u0433\u043d\u0430\u0442\u0443\u0440\u044b<\/em> <code>R<\/code><\/p>\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<blockquote>\n<p>\u0412 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 <em><u>\u0441\u0435\u043a\u0440\u0435\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447<\/u><\/em> <code>(Nonce)<\/code>:<\/p>\n<\/blockquote>\n<pre><code class=\"python\">0x7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0 --> 0x3b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63, 0x3f3979bf72ae8202983dc989aec7f2ff2ed91bdd69ce02fc0700ca100e59ddf3 <\/code><\/pre>\n<h3>Signatures:<\/h3>\n<pre><code class=\"python\">K = 0x7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0 R = 0x00000000000000000000003b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63 S = 0x0a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8 Z = 0x521a65420faa5386d91b8afcfab68defa02283240b25aeee958b20b36ddcb6de<\/code><\/pre>\n<blockquote>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043a\u043e\u0433\u0434\u0430 \u043d\u0430\u043c \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 <code>[K, R, S, Z<\/code>] \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c <u>\u043f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447<\/u> \u043f\u043e \u0444\u043e\u0440\u043c\u0443\u043b\u0435 \u0438 <u>\u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0411\u0438\u0442\u043a\u043e\u0438\u043d \u041a\u043e\u0448\u0435\u043b\u0435<\/u>\u043a.<\/p>\n<\/blockquote>\n<p>\u0414\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u0440\u0438\u0432\u0430\u0442\u043d\u043e\u0433\u043e \u043a\u043b\u044e\u0447\u0430 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f <em>Python<\/em>-\u0441\u043a\u0440\u0438\u043f\u0442\u043e\u043c: <a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/blob\/main\/09BitcoinWalletRecovery\/calculate.py\" rel=\"noopener noreferrer nofollow\">calculate.py<\/a><\/p>\n<pre><code class=\"python\">def h(n):     return hex(n).replace(\"0x\",\"\")  def extended_gcd(aa, bb):     lastremainder, remainder = abs(aa), abs(bb)     x, lastx, y, lasty = 0, 1, 1, 0     while remainder:         lastremainder, (quotient, remainder) = remainder, divmod(lastremainder, remainder)         x, lastx = lastx - quotient*x, x         y, lasty = lasty - quotient*y, y     return lastremainder, lastx * (-1 if aa &lt; 0 else 1), lasty * (-1 if bb &lt; 0 else 1)  def modinv(a, m):     g, x, y = extended_gcd(a, m)     if g != 1:         raise ValueError     return x % m      N = 0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141   K = 0x7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a0 R = 0x00000000000000000000003b78ce563f89a0ed9414f5aa28ad0d96d6795f9c63 S = 0x0a963d693c008f0f8016cfc7861c7f5d8c4e11e11725f8be747bb77d8755f1b8 Z = 0x521a65420faa5386d91b8afcfab68defa02283240b25aeee958b20b36ddcb6de   print (h((((S * K) - Z) * modinv(R,N)) % N))<\/code><\/pre>\n<h3>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043c Python-\u0441\u043a\u0440\u0438\u043f\u0442: calculate.py<\/h3>\n<pre><code class=\"bash\">python3 calculate.py<\/code><\/pre>\n<figure class=\"bordered full-width\"><figcaption>PrivKey = b6c1238de89e9defea3ea0712e08726e338928ac657c3409ebb93d9a0873797f<\/figcaption><\/figure>\n<p>\u041e\u0442\u043a\u0440\u043e\u0435\u043c\u00a0<a href=\"https:\/\/cryptodeep.ru\/bitaddress.html\" rel=\"noopener noreferrer nofollow\">bitaddress<\/a>\u00a0\u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u043c:  <\/p>\n<pre><code class=\"bash\">ADDR: 15HvLBX9auG2bJdLCTxSvjvWvdgsW7BvAT WIF:  L3LxjEnwKQMFYNYmCGzM1TqnwxRDi8UyRzQpVfmDvk96fYN44oFG HEX:  b6c1238de89e9defea3ea0712e08726e338928ac657c3409ebb93d9a0873797f<\/code><\/pre>\n<figure class=\"bordered full-width\"><figcaption><\/figcaption><\/figure>\n<p><strong>\u041f\u0440\u0438\u0432\u0430\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447 \u043d\u0430\u0439\u0434\u0435\u043d!<\/strong><\/p>\n<p><strong>\u0411\u0438\u0442\u043a\u043e\u0438\u043d \u043a\u043e\u0448\u0435\u043b\u0435\u043a \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d!<\/strong><\/p>\n<figure class=\"bordered full-width\"><figcaption><\/figcaption><\/figure>\n<blockquote>\n<p><code>\u041a\u043e\u0440\u043e\u0442\u043a\u0438\u0435 \u043f\u043e\u0434\u043f\u0438\u0441\u0438 ECDSA<\/code> &#8212; <em>\u044d\u0442\u043e \u043f\u043e\u0442\u0435\u043d\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0443\u0433\u0440\u043e\u0437\u0430 \u043f\u043e\u0442\u0435\u0440\u0438 \u043c\u043e\u043d\u0435\u0442<\/em> <code>BTC<\/code>, <em>\u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043c\u044b \u043d\u0430\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0432\u0441\u0435\u043c \u0432\u0441\u0435\u0433\u0434\u0430 \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0442\u044c \u041f\u041e \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0435\u043d\u043d\u044b\u0435 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430.<\/em><\/p>\n<\/blockquote>\n<p>\u0414\u0430\u043d\u043d\u044b\u0439 \u0432\u0438\u0434\u0435\u043e\u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b \u0441\u043e\u0437\u0434\u0430\u043d \u0434\u043b\u044f \u043f\u043e\u0440\u0442\u0430\u043b\u0430\u00a0<a href=\"https:\/\/cryptodeep.ru\/\" rel=\"noopener noreferrer nofollow\"><strong>CRYPTO DEEP TECH<\/strong><\/a>\u00a0\u0434\u043b\u044f \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0435\u043d\u0438\u044f \u0444\u0438\u043d\u0430\u043d\u0441\u043e\u0432\u043e\u0439 \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0445 \u0438 \u043a\u0440\u0438\u043f\u0442\u043e\u0433\u0440\u0430\u0444\u0438\u0438 \u043d\u0430 \u044d\u043b\u043b\u0438\u043f\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u043a\u0440\u0438\u0432\u044b\u0445\u00a0<code>secp256k1<\/code>\u00a0\u043f\u0440\u043e\u0442\u0438\u0432 \u0441\u043b\u0430\u0431\u044b\u0445 \u043f\u043e\u0434\u043f\u0438\u0441\u0435\u0439\u00a0<code>ECDSA<\/code>\u00a0\u0432 \u043a\u0440\u0438\u043f\u0442\u043e\u0432\u0430\u043b\u044e\u0442\u0435\u00a0<code>BITCOIN<\/code>  <\/p>\n<p><a href=\"https:\/\/github.com\/demining\/CryptoDeepTools\/tree\/main\/09BitcoinWalletRecovery\" rel=\"noopener noreferrer nofollow\"><strong>\u0418\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434<\/strong><\/a><\/p>\n<p><a href=\"https:\/\/t.me\/cryptodeeptech\" rel=\"noopener noreferrer nofollow\"><strong>Telegram<\/strong><\/a><strong>:\u00a0<\/strong><a href=\"https:\/\/t.me\/cryptodeeptech\" rel=\"noopener noreferrer nofollow\"><strong><u>https:\/\/t.me\/cryptodeeptech<\/u><\/strong><\/a><\/p>\n<p><a href=\"https:\/\/youtu.be\/xBgjWE5tA7Y\" rel=\"noopener noreferrer nofollow\"><strong>\u0412\u0438\u0434\u0435\u043e\u043c\u0430\u0442\u0435\u0440\u0438\u0430\u043b:<\/strong><\/a><strong>\u00a0<\/strong><a href=\"https:\/\/youtu.be\/xBgjWE5tA7Y\" rel=\"noopener noreferrer nofollow\"><strong>https:\/\/youtu.be\/xBgjWE5tA7Y<\/strong><\/a><\/p>\n<p><a href=\"https:\/\/cryptodeep.ru\/shortest-ecdsa-signature\" rel=\"noopener noreferrer nofollow\"><strong>\u0418\u0441\u0442\u043e\u0447\u043d\u0438\u043a: https:\/\/cryptodeep.ru\/shortest-ecdsa-signature<\/strong><\/a><\/p>\n<hr\/>\n<div class=\"tm-iframe_temp\" data-src=\"https:\/\/embedd.srv.habr.com\/iframe\/62fbef36ab11133472440640\" data-style=\"\" id=\"62fbef36ab11133472440640\" width=\"\"><\/div>\n<\/p>\n<\/div>\n<\/div>\n<\/div>\n<div class=\"v-portal\" style=\"display:none;\"><\/div>\n<\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/683802\/\"> https:\/\/habr.com\/ru\/post\/683802\/<\/a><br \/><\/br><\/br><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-337342","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/337342","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=337342"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/337342\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=337342"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=337342"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=337342"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}