Bitcoin Forum
May 04, 2024, 05:24:36 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Need brainwallet php script  (Read 1178 times)
JetRX (OP)
Jr. Member
*
Offline Offline

Activity: 57
Merit: 10


View Profile WWW
August 13, 2015, 07:32:52 AM
 #1

I need to get out of my Passphrase:
1. Private Key
2. Address

There is a script for php?

— ApsMoney.com - Oбмeн Bitcoin, PM, Payeer,BTC-e, Пpивaт24
Be very wary of relying on JavaScript for security on crypto sites. The site can change the JavaScript at any time unless you take unusual precautions, and browsers are not generally known for their airtight security.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714800276
Hero Member
*
Offline Offline

Posts: 1714800276

View Profile Personal Message (Offline)

Ignore
1714800276
Reply with quote  #2

1714800276
Report to moderator
Kazimir
Legendary
*
Offline Offline

Activity: 1176
Merit: 1001



View Profile
August 13, 2015, 11:37:31 AM
 #2

Are you sure you would prefer a typical server-side solution (php) for something that can also be done client-side (javascript) ?

BitcoinJs works well for this, and allows you to do it completely locally & offline.

In theory, there's no difference between theory and practice. In practice, there is.
Insert coin(s): 1KazimirL9MNcnFnoosGrEkmMsbYLxPPob
coinableS
Legendary
*
Offline Offline

Activity: 1442
Merit: 1179



View Profile WWW
August 13, 2015, 11:41:52 AM
 #3

Are you sure you would prefer a typical server-side solution (php) for something that can also be done client-side (javascript) ?

BitcoinJs works well for this, and allows you to do it completely locally & offline.

Agreed, why does it have to be PHP?
You can get the JS brainwallet code as it is still available on github from previous commits.
https://github.com/brainwallet/brainwallet.github.io/commit/fa462be9af74da30ae7e78203c11b94a0f887539

fbueller
Sr. Member
****
Offline Offline

Activity: 412
Merit: 266


View Profile
August 13, 2015, 12:36:29 PM
 #4

JetRX: Depending on what passphrase you mean, try out https://github.com/Bit-Wasp/bitcoin-php. It's in composer too.

Some of the examples may be out of date, but an IDE will have you coding in no time.



Kazimir: Do you use electrum? That's python.. but on the client-side.

Bitwasp Developer.
AccountStore.biz
Newbie
*
Offline Offline

Activity: 22
Merit: 0


View Profile
August 13, 2015, 03:12:34 PM
 #5

Important detail: what website/tool did you use to create the brainwallet? if it was brainwallet.org, use the github link posted above. The problem is there is no standardization for brainwallets, each tool works differently, some tools will give a different address + private key for the same brainwallet phrase.
Kazimir
Legendary
*
Offline Offline

Activity: 1176
Merit: 1001



View Profile
August 13, 2015, 07:39:15 PM
 #6

By far the most common is to use this as your brainwallet:

private key = Sha256(passphrase)

This is also what brainwallet.org did.

In theory, there's no difference between theory and practice. In practice, there is.
Insert coin(s): 1KazimirL9MNcnFnoosGrEkmMsbYLxPPob
hexafraction
Sr. Member
****
Offline Offline

Activity: 392
Merit: 259

Tips welcomed: 1CF4GhXX1RhCaGzWztgE1YZZUcSpoqTbsJ


View Profile
August 13, 2015, 10:27:14 PM
 #7

By far the most common is to use this as your brainwallet:

private key = Sha256(passphrase)

This is also what brainwallet.org did.

That's insecure. For new brainwallet applications:

1) Consider if a brainwallet is truly necessary. If not, use more secure means. If it is, go to step 2.
2) Use a "slower" key stretching function with multiple rounds (to prevent brute force attacks), and use a long and secure passphrase.

I have recently become active again after a long period of inactivity. Cryptographic proof that my account has not been compromised is available.
coinableS
Legendary
*
Offline Offline

Activity: 1442
Merit: 1179



View Profile WWW
August 13, 2015, 10:28:08 PM
 #8

By far the most common is to use this as your brainwallet:

private key = Sha256(passphrase)

This is also what brainwallet.org did.

I think it would be worth noting that simply a sha256 hash of a passphrase or word will not produce a user-friendly bitcoin private key, it would have to then be converted to WIF.

http://bitcoin.stackexchange.com/questions/8247/how-can-i-convert-a-sha256-hash-into-a-bitcoin-base58-private-key


tspacepilot
Legendary
*
Offline Offline

Activity: 1456
Merit: 1076


I may write code in exchange for bitcoins.


View Profile
August 14, 2015, 09:10:42 AM
 #9

Are you sure you would prefer a typical server-side solution (php) for something that can also be done client-side (javascript) ?

BitcoinJs works well for this, and allows you to do it completely locally & offline.

I almost never use php myself, I'm more of a python/javascript/perl/bash person, but I just have to point out for the record that you can run php in a terminal as a simple executable.  Just put it on your $PATH and call "php" with your php file as the first argument.  Say this is your file hello.php:

Code:
<?php
  
echo "hello, world";
?>


Code:
$ php hello.php
hello, world
$

@OP, I hope anyone playing with brainwallets knows about this:
http://www.wired.com/2015/07/brainflayer-password-cracker-steals-bitcoins-brain/
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!