Questions tagged [javascript]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1
vote
0answers
32 views

Bitcoin Script - Beautify

My question is if something exists to do the job in the opposite direction of miniscript. Miniscript's intention is to help:     ...writing (a subset of) Bitcoin Scripts in a structured way, enabling ...
0
votes
3answers
54 views

The best JavaScript libraries supporting Bitcoin Core?

I have downloaded and installed Bitcoin full node on my Linux server and I'd like to start working with the bitcoin core to create wallet, addresses, and transactions. What is the best JS libraries ...
0
votes
1answer
393 views

How to Create Bitcoin Cash HD Walllet in Javascript

I am trying to create a Bitcoin Cash HD wallet through mnemonic phrase, but I don't know any npm package that is compatible with HD wallets and Bitcoin Cash. Could someone help me build the BCH HD ...
1
vote
2answers
411 views

How to use `scantxoutset`

Looking to fetch the UTXOs for a given address and can't seem to find the correct command syntax. Here is an implementation in bitcoin-core via javascript, but I also experience the same on bitcoin-...
0
votes
1answer
62 views

How to get BTC transfer amount from raw tx using bitcoinjs

Suppose I have following object console.log(bitcoinjs.Transaction.fromHex(rawTx)); The output Transaction { version: 2, locktime: 1655960, ins: [ { hash: <Buffer dc 4d aa 10 db ...
1
vote
0answers
25 views

How can I use PSBT in a JavaScript project?

I am trying to use PSBT in a Bitcoin project. The idea is to generate keys and sign transactions client-side. I am already familiar with bitcoinjs-lib but I find the API rather complicated. It would ...
0
votes
2answers
43 views

Generating Bitcoin address from private key in browser console

I am a newbie Bitcoin evangelist and I have a recommendation to see all the code responsible for computing yourPublicKey from yourPrivateKey, especially for big deal addresses. The easiest way to ...
1
vote
2answers
71 views

Understand how transaction size and fees calculation works in caravan

Looks like there is no activity in caravan github repository so maybe someone here can help me with this issue. Already mentioned everything in the below link however my three basic questions are: ...
1
vote
0answers
21 views

Sign transaction externally

I create a transaction with inputs from a given address / public key without signatures. Every input needs to be signed. I use a different method to generate the signatures so I can't provide a ...
0
votes
1answer
278 views

how to place a bitforex api buy order

I have read the documentation for BitForex on placing a buy order here: https://github.com/bitforexapi/API_Doc_en/wiki/Order Then after understanding that, I read the API Call Description ...
0
votes
0answers
52 views

bitcoind: How to get rawblock data with ZeroMQ

I am trying to use the zeromq api for bitcoind to get rawblock but its not working with the code I've provided below. I am able to get hashtx and rawtx if I remove the filter but not hashblock and ...
5
votes
5answers
6k views

Ripple testnet explorer

This is Ripple main Explorer. But where can i find the transactions ledger from wallets on Ripple testnet.
2
votes
1answer
906 views

A NodeJS implementation on creating addresses from a Bitcoin (zpub, xpub) address

I'm looking for a lightweight node package which can handle creating btc receiving addresses on the server using an extended public key (segwit). Like this one: ...
0
votes
1answer
352 views

Is it possible to talk to bitcoin RPC API with Javascript and WITHOUT using a node server?

I am planning on building a Wallet and want to know if I can hook something like an Electron native JavaScript app to Bitcoin RPC without running node.js for the server calls, so using something like ...
0
votes
1answer
707 views

Signature for this request is not valid

im testing the binance api but cant get over the signature problem can u spot a mistake on my signature?: const crypted = CryptoJs.HmacSHA256("timestamp=" + new Date().getTime().toString() + "&...
0
votes
1answer
71 views

How to create an application which constructs a transaction using `bcoin` (javascript)?

I am new to development. I am working on a project and I am trying to use bcoin. I want to create an application which has a UI, where the user will be asked to enter Destination address and amount. ...
5
votes
1answer
2k views

How do I remove Wallet from Bcoin?

I'm playing with bcoin cli and created lots of wallets. Is there any way to remove wallet via WalletDB Api?
1
vote
2answers
94 views

Bitcoinja-lib. bitcoin.payments is null

I installed bitcoinjs-lib with command: meteor npm install bitcoinjs-lib. The installation command "flow-typed install -f 0.27 bitcoinjs-lib@2.2.0" didn't work. No idea what flow-typed is and the ...
0
votes
0answers
32 views

How to connect to an ElectrumX server using JavaScript WebSockets?

I'm trying to connect to an ElectrumX server from an HTML webpage. But I can't get a working connection. I've tried with many servers from Electrum's servers.json list but none worked. Here's the ...
1
vote
0answers
23 views

Is there any 'Metamask-like' app for Bitcoin? [duplicate]

9 months ago someone asked this same question: Metamask-like web3 inject for bitcoin but I was wondering if there had been be any changes since then. I'm currently looking for a Chrome extension that ...
0
votes
0answers
25 views

Multisig Wallet Help

Hello everyone I'm jud3v and i'm searching an api that provide me the same as electrum wallet for creating multisig wallet 2-of-3 for my client to protect there btc with multisignature. I have already ...
0
votes
1answer
33 views

how to sign a multiple output transaction

currently i m using below code,how to add multiple address to address. let transaction = new bitcore.Transaction() transaction .from(txoSet) .to( ...
1
vote
1answer
57 views

How do I get old blocks while running a pruned node?

Hello I'm trying to build a NodeJS app that fetches Bitcoin blocks, potentially old ones, and I'm running into issues. I've downloaded Bitcoin Core but I don't have enough space to run a full node and ...
0
votes
0answers
32 views

How can i mine bitcoins to direct wallet using JavaScript?

I heard that we can mine bitcoins using javascript direct to the wallet? How can I create Program, script or application which direct mines to the wallet & I even search online but did not get ...
0
votes
0answers
49 views

Edge private keys

I want to read the balance on my Edge wallet programatically. I have thus taken the wallet's Master Private Key, which I had expected to be a BIP39 seed phrase but is instead a hex value, and am ...
0
votes
0answers
74 views

broadcasting bitcoin transaction issue using bitcore-explorers

I have been trying to do a transaction using bitcore-lib. I have successfully created transaction object. let bitcore_transaction = new bitcore.Transaction() .from(utxos[0]) .to(to, +...
0
votes
1answer
33 views

JavaScript Mining System Design

How do I verify a unconfirmed transaction using JavaScript ?
0
votes
1answer
322 views

Javascript library or code that can convert an “uncompressed” bitcoin private key to a compressed one

I forked a pretty old brain wallet generator: https://dvdbng.github.io/memwallet/ -- Currently it generates uncompressed bitcoin private keys. Is there a javascript library that can convert an ...
9
votes
1answer
22k views

Byte array to hexadecimal and back again in JavaScript [closed]

I can generate a byte array with var myByteArray = window.crypto.getRandomValues(new Uint8Array(16)) and I get 181,143,16,173,231,56,63,149,181,185,224,124,84,230,123,36 I can then turn this into ...
1
vote
3answers
6k views

Is the bitdigger chrome extension fraud?

Today, while I was watching a video on YouTube, I found the video on the bitdigger extension that mine bitcoins with chrome browser. I just want to know if it is fraud or legit? Is it possible to mine ...
0
votes
1answer
43 views

Using only Javascript and JS related Bitcoin Libraries. How do you extract the Bitcoin Address from a private key?

I'm building an js related application that only stores my user's bitcoin private keys, but not the public key or bitcoin address to save space. Is there a javascript library that can output the ...
0
votes
1answer
351 views

Creating a raw bitcoin transaction and signing it with the private key using php and javascript

I have a full bitcoin core node setup and would like to use it to just "broadcast" my signed transactions. But what is required to make a raw transaction using PHP and Javascript? The variables I have ...
0
votes
1answer
1k views

How do you sign data with a private key? [javascript]

Using BlockCypher’s signing tool (link), I can sign the following data: 05de69f5d37f41340eed3230f03d2394dde5e497738a76f027b7d962a0cbdf39 with the private key: ...
2
votes
1answer
31 views

Ardor: How to decide if an asset can be send?

My (Javascript) frontend needs to decide whether the user can send an Ardor/Ignis asset in his account. My code checked for: quantityQNT >= amount_to_send But I realise that this doesn't work if ...
2
votes
1answer
114 views

I have a 100 character text message and I want to encrypt this message with my bitcoin “PUBLIC KEY” and decrypt it with my private key in Javascript

Are there any javascript libraries that can encrypt a 100 character text message using your bitcoin public key, but only be able to decrypt it with your bitcoin private key? I'm looking to create a ...
0
votes
1answer
195 views

Generating Output Script from Bitcoin.js or other Javascript Library

I'm attempting to use the Ledger Wallet API to sign a multi-sig transaction. The API works as follows: var inputs = [ [ "71f97fa2a21486ecd99674a8ae068d92acd2e9db49c199473be39984e6cbe0f6", "00000000"...
1
vote
1answer
4k views

generating private key from bip39 seed

according to bip39, I maked 12 mnemonic words and then get a 512 bit seed from them. now I want to know how must I convert this seed to private key ? what functions must I use ? please introduce me ...
1
vote
1answer
441 views

Derive next HD segwit address from xpub/ypub

I've been using the smartbit api to derive the next receiving address for a while now. However it only works for Legacy addresses and not Segwit addresses. I now have a Ledger Nano s and need a ...
0
votes
1answer
796 views

UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'fromSeedBuffer' of undefined

I am getting Getting error at this line var root = bitcoin.HDNode.fromSeedBuffer(seed); UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'fromSeedBuffer' of undefined Here is ...
0
votes
1answer
198 views

Explain blockexplorer UTXO

Bitcoin testnet I used the following code to obtain info about unspent outputs: const blockchainInfo = require('blockchain.info') const blockexplorer = blockchainInfo.blockexplorer.usingNetwork(3) ...
0
votes
1answer
272 views

How to make a persistent SPV wallet? (bcoin)

I created a wallet on a SPV node. The wallet is initialized from a mnemonic. After receiving some transactions, the wallet's balance looks like: { account: -1, tx: 3, coin: 3, unconfirmed: 136300, ...
1
vote
1answer
382 views

Ardor API: Not able to use POST requests with Axios due to CORS issues [closed]

I am having issues with POST requests to the Ardor API. This code: <!DOCTYPE html> <html> <head> <script src="https://unpkg.com/axios/dist/axios.min.js"></script> &...
1
vote
1answer
60 views

How can I generate the qrcode client-side that would be compatible with the Ardor Wallet qrcode

I'd like to generate a qrcode the same way the Ardor Wallet generates it, such that it would be compatible. I found qrcode related javascript shipped with the Ardor node download in ardor/html/www/js/...
2
votes
2answers
334 views

What's the POST endpoint to broadcast a transaction in copay's server?

AFAIU, copay's server implementation is bitcore-wallet-service. From its README, I can deduce that a multi-sig wallet will use the /v1/txproposals/ endpoint to create a new transaction proposal that ...
1
vote
1answer
182 views

Can you explain this JS code?

Can someone explain this JS code to me please? Maybe line by line? I am trying to understand and learn from it. Is this code creating a raw transaction based on an existing redeemScript? Or is it ...
4
votes
1answer
243 views

How do the JavaScript SecureRandom() vulnerabilities affect me?

A recent post on the Bitcoin-dev mailing list talks about multiple vulnerabilities in JavaScript SecureRandom() class. Apparently this class has been used in multiple cryptocurrency wallets that use ...
1
vote
1answer
801 views

Creating Testnet Bitcoin Transaction with bitcoinjs-lib

I'm trying to setup a simple bitcoin testnet transaction using the bitcoinjs-lib npm module. It seems like I'm building the transaction correctly, and I receive the hex code but I think I'm unable to ...
3
votes
1answer
2k views

Bruteforce bitcoin address - I know the words + public address but not the order

I have a long list of 1million+ permutations of a 12 word BIP39 seed. How can I try them all on a bitcoin address? edit: I know the address and the 12 words but i don't know the order of the words
0
votes
1answer
837 views

Javascript library to explore bitcoin blockchain data by connecting to a local running node

I need to get data of a block using the block height. Is there a javascript library to get block data from the Bitcoin blockchain, by connecting to local running node or a 3rd party blockchain ...
0
votes
1answer
377 views

How to set up a private chain/local testnet : reverse engineering the blockchain code

Long story short, I want to set up a private chain/a testnet blockchain that can run locally just to fiddle and play with it just to learn how it works. So I have a general understanding of how things ...