Bitcoin Forum
December 14, 2024, 01:48:18 PM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: transfer bitcoin to another address with a private key  (Read 140 times)
recode6 (OP)
Newbie
*
Offline Offline

Activity: 1
Merit: 2


View Profile
May 07, 2024, 11:27:27 AM
Merited by ABCbits (1), bitmover (1)
 #1

I still have a private key from an old Bitcoin wallet (circa 2012), and I have a private key. I downloaded the bitWallet app for iOS, entered my private key there and my wallet with balance and all transactions was displayed. I wanted to transfer bitcoins to my new wallet, but I get the error mandatory-script-verify-flag-failed (Public key is neither compressed or uncompressed)

my secret key is 52 characters long, starts with 5HpH

I am ready to very generously thank anyone who can help me!
LoyceV
Legendary
*
Offline Offline

Activity: 3528
Merit: 17822


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
May 07, 2024, 12:11:25 PM
Merited by ABCbits (3), bitmover (2), hosseinimr93 (1)
 #2

I still have a private key from an old Bitcoin wallet (circa 2012), and I have a private key.
That's probably a valuable wallet, so you should NOT enter the private key into a hot wallet, risking everything if your wallet gets compromised.

Quote
I downloaded the bitWallet app for iOS, entered my private key there and my wallet with balance and all transactions was displayed. I wanted to transfer bitcoins to my new wallet, but I get the error mandatory-script-verify-flag-failed (Public key is neither compressed or uncompressed)
I don't use iOS or BitWallet, but I can recommend Electrum. Even better if you do it securely, by keeping the private key offline. This is how I would do it:
Online:
Install Electrum on your PC.
Import your address to create a watch-only wallet.
Preview the transaction, Copy the unsigned transaction. Put it on a USB stick.

Offline and running without hard drive storage:
Get a Linux LIVE DVD. Use Knoppix or Tails for instance, or any other distribution that comes with Electrum pre-installed.
Unplug your internet cable. Close the curtains. Reboot your computer and start up from that DVD. Don't enter any wireless connection password. Keep it offline.
Start Electrum. Import your private key.
Copy your unsigned transaction from the USB stick, load it into Electrum.
CHECK the transaction in Electrum. Check the fees, check the amount, check all destination addresses (character by character).
If all is okay, sign the transaction. Copy it back to your USB stick.
Turn off the computer. That wipes the Live LINUX from memory and all traces are gone.

Online:
Use your normal online Electrum to (check again and) broadcast the transaction.

Bonus:
After moving all your Bitcoin, and once the transaction confirmed, check if you own Forkcoins.

You're not the first to get this error from BitWallet.

▄▄███████████████████▄▄
▄█████████▀█████████████▄
███████████▄▐▀▄██████████
███████▀▀███████▀▀███████
██████▀███▄▄████████████
█████████▐█████████▐█████
█████████▐█████████▐█████
██████████▀███▀███▄██████
████████████████▄▄███████
███████████▄▄▄███████████
█████████████████████████
▀█████▄▄████████████████▀
▀▀███████████████████▀▀
Peach
BTC bitcoin
Buy and Sell
Bitcoin P2P
.
.
▄▄███████▄▄
▄████████
██████▄
▄██
█████████████████▄
▄███████
██████████████▄
███████████████████████
█████████████████████████
████████████████████████
█████████████████████████
▀███████████████████████▀
▀█████████████████████▀
▀██████████████████▀
▀███████████████▀
▀▀███████▀▀

▀▀▀▀███▀▀▀▀
EUROPE | AFRICA
LATIN AMERICA
▄▀▀▀











▀▄▄▄


███████▄█
███████▀
██▄▄▄▄▄░▄▄▄▄▄
████████████▀
▐███████████▌
▐███████████▌
████████████▄
██████████████
███▀███▀▀███▀
.
Download on the
App Store
▀▀▀▄











▄▄▄▀
▄▀▀▀











▀▄▄▄


▄██▄
██████▄
█████████▄
████████████▄
███████████████
████████████▀
█████████▀
██████▀
▀██▀
.
GET IT ON
Google Play
▀▀▀▄











▄▄▄▀
NotATether
Legendary
*
Offline Offline

Activity: 1820
Merit: 7476


Top Crypto Casino


View Profile WWW
May 09, 2024, 06:29:42 AM
 #3

I still have a private key from an old Bitcoin wallet (circa 2012), and I have a private key. I downloaded the bitWallet app for iOS, entered my private key there and my wallet with balance and all transactions was displayed. I wanted to transfer bitcoins to my new wallet, but I get the error mandatory-script-verify-flag-failed (Public key is neither compressed or uncompressed)

my secret key is 52 characters long, starts with 5HpH

I am ready to very generously thank anyone who can help me!

This is an uncompressed private key. So it should be making uncompressed legacy addresses. (Uncompressed segwit address transactions will not be published to the mempool.)

Try to manually create a transaction that sweeps its outputs to another address, using the bit Python package:

1. Install Python if you don't have it already
2. Open a terminal and type

Code:
pip install bit
Now according to the README you are supposed to create and broadcast a transaction by opening Python and doing something like this:

Code:
from bit import Key

my_key = Key(<place your private key in here as a string, so '5HpH....'>)

output = [
    # Replace the dots with your new address here
    # BE CAREFUL. You need to leave some balance out to use as a transaction fee.
    # So you're not going to send the entire balance, otherwise there will be nothing left to send as the fee.
    ('..........', 0.0035, 'btc')
]

my_key.send(output)
# should show you the transaction ID

███████████████████████
████▐██▄█████████████████
████▐██████▄▄▄███████████
████▐████▄█████▄▄████████
████▐█████▀▀▀▀▀███▄██████
████▐███▀████████████████
████▐█████████▄█████▌████
████▐██▌█████▀██████▌████
████▐██████████▀████▌████
█████▀███▄█████▄███▀█████
███████▀█████████▀███████
██████████▀███▀██████████

███████████████████████
.
BC.GAME
▄▄▀▀▀▀▀▀▀▄▄
▄▀▀░▄██▀░▀██▄░▀▀▄
▄▀░▐▀▄░▀░░▀░░▀░▄▀▌░▀▄
▄▀▄█▐░▀▄▀▀▀▀▀▄▀░▌█▄▀▄
▄▀░▀░░█░▄███████▄░█░░▀░▀▄
█░█░▀░█████████████░▀░█░█
█░██░▀█▀▀█▄▄█▀▀█▀░██░█
█░█▀██░█▀▀██▀▀█░██▀█░█
▀▄▀██░░░▀▀▄▌▐▄▀▀░░░██▀▄▀
▀▄▀██░░▄░▀▄█▄▀░▄░░██▀▄▀
▀▄░▀█░▄▄▄░▀░▄▄▄░█▀░▄▀
▀▄▄▀▀███▄███▀▀▄▄▀
██████▄▄▄▄▄▄▄██████
.
..CASINO....SPORTS....RACING..


▄▄████▄▄
▄███▀▀███▄
██████████
▀███▄░▄██▀
▄▄████▄▄░▀█▀▄██▀▄▄████▄▄
▄███▀▀▀████▄▄██▀▄███▀▀███▄
███████▄▄▀▀████▄▄▀▀███████
▀███▄▄███▀░░░▀▀████▄▄▄███▀
▀▀████▀▀████████▀▀████▀▀
Cricktor
Legendary
*
Offline Offline

Activity: 980
Merit: 1624


Crypto Swap Exchange


View Profile
May 09, 2024, 01:11:06 PM
 #4

In 2012 Bitcoin wasn't worth a lot compared to today, so your private key may control a substantial value at today's rate. (You don't need to disclose it, not asking for it, keep your details private!)

I would go the much safer procedure that LoyceV suggested. Do not enter a private key on an online device which security you can't assess. There are so many ways to compromise your private key which non-security tech savvy people don't know about, that I highly recomment to play it as safe as possible.

NotATether's procedure is on an online device and requires a good understanding how Bitcoin transaction work to not mess up funds. If you spend e.g. only half of an UTXO to only one destination output address, the other half of your input UTXO will turn into transaction fee!

Don't know about your knowledge of Bitcoin's transaction model, but remember that a Bitcoin transaction consumes (destroys by spending) every transaction input(s) completely to the output(s) minus required transaction fee. Check for reasonable transaction fee at https://mempool.space.

This is important, don't skip to display a preview of your transaction details and check *everything* carefully. Never skip this step!
CHECK the transaction in Electrum. Check the fees, check the amount, check all destination addresses (character by character).

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
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!