Created
November 21, 2018 02:59
-
-
Save toknT/b49824fabd8889a074e143d920a639f6 to your computer and use it in GitHub Desktop.
php eth
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* example of package https://github.com/digitaldonkey/ethereum-php | |
*/ | |
require __DIR__ . '/vendor/autoload.php'; | |
use Ethereum\DataType\EthD; | |
use Ethereum\Ethereum; | |
// https://web3js.readthedocs.io/en/1.0/web3-eth-accounts.html#recover | |
$recoveredAddr = Ethereum::personalEcRecover('Some data', new EthD('0xb91467e570a6466aa9e9876cbcd013baba02900b8979d43fe208a4a4f339f5fd6007e74cd82e037b800186422fc2da167c747ef045e5d18a5f5d4300f8e1a0291c')); | |
echo $recoveredAddr; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment