Bitcoin content gmod

May 2, 2021 / Rating: 4.6 / Views: 794

Gallery of Images "Bitcoin content gmod" (39 pics):

Bitcoin reverse engineering

# Crypto PHP No GPU Cores Will Be Harmed in the Solving of This Challenge! Url: Create ABitcoin Address For Me/ Tags: web security ## Solution We are greeted with `I'm not giving you any flags! Looking at the source: ``` I'm not giving you any flags! ``` We download the `bak`: ```php 0) return substr(strtoupper(hash("sha256",hash("sha256",pack("H*",substr($address,0,strlen($address)-8)),true))),0,8) == substr($address,strlen($address)-8);} $address = "35h K24tc LEWcg NA4Jxpvbk Nko Ac DGq QPs P";if (isset ($_GET["Please Create ABitcoin Address For Me"])) $check = check Address($address);if ($check)else echo $check; ? ``` We can provide an address through the get parameter `Please Create ABitcoin Address For Me`. It uses `bcmath` for arbitrary precision calculations. It's checked via `check Adress` which has to return true in order to continue. We iterate over the chars of the address and add that to the result of `bcmul($dec, "58", 0)`. Like the first variable name `origbase58` implies, this is base58 - (Fraction(n) / 16 % 16).numerator7``` It converts our number from decimal to a hexadecimal string. So you don't actually need it but to initally understand what it is doing it might be helpful. ```python hex(n)[2:].upper()'1BB63666D1882FDD5ED9DA658AFAF56502193C397E54470'``` The string is additionally padded with zeros for starting 1s in the address and if the length is odd. The length has to be 50 afterwards and the first two chars (1 byte) has to be zero. Since the required address already starts with a 1 that is converted to zeros this is no problem. # Crypto PHP No GPU Cores Will Be Harmed in the Solving of This Challenge! Url: Create ABitcoin Address For Me/ Tags: web security ## Solution We are greeted with `I'm not giving you any flags! Looking at the source: ``` I'm not giving you any flags! ``` We download the `bak`: ```php 0) return substr(strtoupper(hash("sha256",hash("sha256",pack("H*",substr($address,0,strlen($address)-8)),true))),0,8) == substr($address,strlen($address)-8);} $address = "35h K24tc LEWcg NA4Jxpvbk Nko Ac DGq QPs P";if (isset ($_GET["Please Create ABitcoin Address For Me"])) $check = check Address($address);if ($check)else echo $check; ? ``` We can provide an address through the get parameter `Please Create ABitcoin Address For Me`. It uses `bcmath` for arbitrary precision calculations. It's checked via `check Adress` which has to return true in order to continue. We iterate over the chars of the address and add that to the result of `bcmul($dec, "58", 0)`. Like the first variable name `origbase58` implies, this is base58 - (Fraction(n) / 16 % 16).numerator7``` It converts our number from decimal to a hexadecimal string. So you don't actually need it but to initally understand what it is doing it might be helpful. ```python hex(n)[2:].upper()'1BB63666D1882FDD5ED9DA658AFAF56502193C397E54470'``` The string is additionally padded with zeros for starting 1s in the address and if the length is odd. The length has to be 50 afterwards and the first two chars (1 byte) has to be zero. Since the required address already starts with a 1 that is converted to zeros this is no problem.

date: 02-May-2021 11:22next


2020-2021 © iitcanada.com
Sitemap