Bitcoin Forum
October 02, 2024, 02:54:06 AM *
News: Latest Bitcoin Core release: 27.1 [Torrent]
 
  Home Help Search Login Register More  
  Show Posts
Pages: « 1 2 3 4 5 6 7 8 9 [10] 11 »
181  Bitcoin / Project Development / Re: [PAY] Patch bitcoin v0.5.1rc2 to send a HTTP POST when a new block is accepted on: January 22, 2012, 02:56:35 PM
Code:
<?php
            $_SERVER
['REQUEST_METHOD'] = 'POST' AND 
            !empty(
$_SERVER['CONTENT_TYPE']) AND
            
$_SERVER['CONTENT_TYPE'] = 'application/json'
?>

This is, of course, wrong. Corrected condition:

Code:
            $_SERVER['REQUEST_METHOD'] == 'POST' &&  isset($_SERVER['CONTENT_TYPE']) && $_SERVER['CONTENT_TYPE'] == 'application/json'

AND == && in php lol

its even the first example on the logical operators page in the php manual

http://www.php.net/manual/en/language.operators.logical.php
182  Bitcoin / Project Development / Re: [PAY] Patch bitcoin v0.5.1rc2 to send a HTTP POST when a new block is accepted on: January 22, 2012, 02:41:46 PM
Very nice Smiley

Not sure how to decode the scriptsig, but I dont use sender for now anyway.

The scriptSigs seem to be split up into 2 parts by a space
I'm not 100% sure but i think the first part is the actual sig and the 2nd part is the senders pubkey

anyway this should be done soon im just adding the block posting part now for my needs and adding in the code to make this usable by the
config file im gna make it like this
monitortx(true|false)
monitortxurl=http://example.com/foo.php
monitorblock(true|false)
monitorblockurl=http://example.com/foo.php
183  Bitcoin / Project Development / Re: [PAY] Patch bitcoin v0.5.1rc2 to send a HTTP POST when a new block is accepted on: January 22, 2012, 12:48:53 PM
sorry it took so long i had some bugs to work out....

How does this look?
Code:
{
"method":"monitortx",
"params":[
{
"hash":"e0065cfb99b2479cbd7479fbe7c70864b5de5ba67c8f3bf58eb460ea2ef094b3",
"ver":1,
"vin_sz":4,
"vout_sz":2,
"lock_time":0,
"in":[
{
"prev_out":"12e1a620f7e90c3f877c8f6369aaf71100ab15be17de0d3c2802c26790f5a3c9",
"n":1,
"scriptSig":"30450221009572ef611ba5940e3842bcbf255a4b1e79c32c39549cc412655c39f0ad727413022022c07128a0cf3b111ce7faf7a7283fa48dd8563adaadd26a477d7e41e09dfbaf01 047fac59c7a28fd6069a00307ab853d0915cb6fec4df84df422b79e0ad3049be0e87cfaf9ca823a06ebee5fb04bc267b3bd0f782579a501397a35d49ada02075dc"
},
{
"prev_out":"d037bfa871865f5020e3a9edb0ad8e3bfeee25bbc6115476c3fb1cd105361c8f",
"n":0,
"scriptSig":"30460221008945b51f2616e4197f60bdec7c2b79cf9cb597faa631accf4b0d00081c525e26022100820c3e1cd2c9d0aec02fccc73dd22baef1a5746b78d3bc4c8df92f21abcf606601 047f094b909687bb621d9ecb02a3f5f7938a0dc71917beec1d21055a69094f030bf210d059b2ad6f872d717826e9dee0348aef7716c8c93911e911a067103c0b69"
},
{
"prev_out":"c8356c7f33245c77a31f75c4534b31993a5d4f47985208d7bf4e708b6e6cb9ad",
"n":0,
"scriptSig":"304502202c30da244b961e570d964cb9d6998e17b0a0349131d8cf0cfa36d214534ecf0b022100b65775ff34b27ed5b0688f5dd4f2b2a1d0c623dd0340891f7845b72757e8ed4701 04ce18444917f2dd3c8f5a4f262556ab9dd04ad482799ee8e92c92735c66957bd42a9e55f894a408ca3ce42d96f6efa221f81e914b49422ff8cfc1b8a950fc91f0"
},
{
"prev_out":"8302ab4b9b5fb426bc8a41e343d2006bafbab95883622cd954e068f2787a3e97",
"n":0,
"scriptSig":"3046022100e2b880f9cfbfeecbd8bb76629ecbff654ed915f8ff8557937f376cffedd8b98f022100ef63e5cd8af0531e2e53d4be8ee73690eb4537ac19663ed054c1c05235eaa12701 04c78a58082241cb3c8c09ef57f9104fc4c28d4ff13252f8bbce0c0eedbbafd92b66639bd48c850016b2442db22474e333cdf2ae3ef6f237eb4be22e582fcf0563"
}
],

"out":[
{
"value":505.96647463,
"scriptPubKey":"OP_DUP OP_HASH160 609c3e000d66225caf5ad27245978d33ed761ee6 OP_EQUALVERIFY OP_CHECKSIG"
},
{
"value":173.16000000,
"scriptPubKey":"OP_DUP OP_HASH160 c56d7f3e011ce6f40d7399667fb2bc116e643b38 OP_EQUALVERIFY OP_CHECKSIG"
}
]

],
"id":null
}

I just used a simple php script to catch the data

Code:
<?php

      
if (
            
$_SERVER['REQUEST_METHOD'] = 'POST' AND 
            !empty(
$_SERVER['CONTENT_TYPE']) AND
            
$_SERVER['CONTENT_TYPE'] = 'application/json'
            
) {
$stringData file_get_contents('php://input');
$myFile "test.txt";
$fh fopen($myFile'w') or die("can't open file");
          
fwrite($fh$stringData);
fclose($fh);
        }
                

?>
184  Bitcoin / Project Development / Re: [PAY] Patch bitcoin v0.5.1rc2 to send a HTTP POST when a new block is accepted on: January 22, 2012, 09:34:16 AM
I've had a little bit of time to work on this today.
I made a new thread just to handle posts like Gavins blockmonitor does.
When a new transaction is received and gets accepted to the memory pool it will put a new post in the query to be sent out.
Very nice, that is exactly what I wanted, a post per tx, and since its localhost it should be fast enough to keep.

You can use it like getmemorypool("transactions") and it will dump out all unconfirmed transactions
Also useable, but then you would need to poll it every so often and check if theres new transactions.

Did you get a POST system working in your test?
If so could you show what data the post script would receive ?

Havn't tested it yet... I should be ready to test in about 15 mins I'll let you now what happens
185  Bitcoin / Project Development / Re: [PAY] Patch bitcoin v0.5.1rc2 to send a HTTP POST when a new block is accepted on: January 22, 2012, 08:56:00 AM
I've had a little bit of time to work on this today.
I made a new thread just to handle posts like Gavins blockmonitor does.
When a new transaction is received and gets accepted to the memory pool it will put a new post in the query to be sent out.

Is this what you wanted? or do you want a whole dump of the transactions in the memory pool?
I just ran across some code in the new source it's a new RPC command: getmemorypool

You can use it like getmemorypool("transactions") and it will dump out all unconfirmed transactions

anyway lemme know what you think
186  Other / Off-topic / Re: I hate paypal. on: January 21, 2012, 08:28:26 AM
http://www.screw-paypal.com/horror_stories/horror_stories.html
187  Bitcoin / Project Development / Re: [PAY] Patch bitcoin v0.5.1rc2 to send a HTTP POST when a new block is accepted on: January 21, 2012, 07:55:19 AM
if your already getting the blocks why not just pull the transaction data from the blocks?

edit: err nevermind just thought about what i said lol if its in a block then it has atleast 1 confirm

188  Bitcoin / Development & Technical Discussion / Re: Is there a "beta" Bitcoin network? on: January 20, 2012, 11:37:41 PM
yes there is read this:   https://en.bitcoin.it/wiki/Testnet
189  Bitcoin / Development & Technical Discussion / Re: bitcoin-qt build error on: January 20, 2012, 11:19:17 PM
me too i finally got it to build but it wont run.... i was told nobody has built it in windows that even the windows exe was built in linux using gitian so im working on building with gitian now
190  Bitcoin / Development & Technical Discussion / Need help, when building in qt creator it builds bitcoind instead of bitcoin-qt on: January 19, 2012, 07:18:22 AM
Can someone help me please? I have a feeling its just a configuration somewhere?

the file it makes after compiling is named bitcoin-qt but its actually bitcoind also the file wont run
191  Bitcoin / Development & Technical Discussion / Re: Does anyone tryed to host bicoind on free Amazon AWS cloud? on: January 18, 2012, 05:26:05 AM
maybe we should make a daemon that flushes IO less often, and keep more stuff in ram :p
I thought about it, I see no problem to implement this.

Ok interesting....

I don't think you should dismiss the mistake the Polish exchange made. He was running on an EC2 which apparently is just for computing or CPU time. When those boxes go down, they wipe the data. That's how he lost his coins. Amazon has another cloud service for redundant distributed storage.

How do you propose to have a fault tolerant backup of your private key's if it's on an EC2?
For example, once a minute/hour/day ... cronjob making an secure wallet.dat archive and coping it into safer place(s).

<3 cron jobs
192  Bitcoin / Development & Technical Discussion / Re: Please help test: Bitcoin-Qt, bitcoind version 0.5.2rc1 on: January 18, 2012, 03:32:15 AM
oh i see.... any estimated date for 6.0?
193  Bitcoin / Development & Technical Discussion / Re: Please help test: Bitcoin-Qt, bitcoind version 0.5.2rc1 on: January 18, 2012, 02:41:12 AM
just wondering why arn't some of the new RPC functions that are in the source built into this build?  like  getblockbyhash?
194  Bitcoin / Development & Technical Discussion / bitcoin-qt build error on: January 18, 2012, 01:29:45 AM
ok so i followed the directions on this page for building in windows

https://github.com/bitcoin/bitcoin/blob/master/doc/readme-qt.rst

the boost dependencies was missing the assign folder in the includes so i got it from boost

now im getting this error

Code:
./build\init.o: In function `Z23SetStartOnSystemStartupb':
C:\Users\Stcupp\Downloads\bitcoin-bitcoin-v0.5.1-126-g43cda5f\bitcoin-qt-build-desktop-Qt_4_7_4_for_Desktop_-_MinGW_4_4__Qt_SDK__Debug/../bitcoin-bitcoin-43cda5f/src/init.cpp:578: undefined reference to `CoInitialize@4'
C:\Users\Stcupp\Downloads\bitcoin-bitcoin-v0.5.1-126-g43cda5f\bitcoin-qt-build-desktop-Qt_4_7_4_for_Desktop_-_MinGW_4_4__Qt_SDK__Debug/../bitcoin-bitcoin-43cda5f/src/init.cpp:584: undefined reference to `CoCreateInstance@20'
C:\Users\Stcupp\Downloads\bitcoin-bitcoin-v0.5.1-126-g43cda5f\bitcoin-qt-build-desktop-Qt_4_7_4_for_Desktop_-_MinGW_4_4__Qt_SDK__Debug/../bitcoin-bitcoin-43cda5f/src/init.cpp:605: undefined reference to `IID_IPersistFile'
C:\Users\Stcupp\Downloads\bitcoin-bitcoin-v0.5.1-126-g43cda5f\bitcoin-qt-build-desktop-Qt_4_7_4_for_Desktop_-_MinGW_4_4__Qt_SDK__Debug/../bitcoin-bitcoin-43cda5f/src/init.cpp:615: undefined reference to `CoUninitialize@0'
C:\Users\Stcupp\Downloads\bitcoin-bitcoin-v0.5.1-126-g43cda5f\bitcoin-qt-build-desktop-Qt_4_7_4_for_Desktop_-_MinGW_4_4__Qt_SDK__Debug/../bitcoin-bitcoin-43cda5f/src/init.cpp:620: undefined reference to `CoUninitialize@0'
collect2: ld returned 1 exit status
mingw32-make.exe[1]: *** [debug\bitcoin-qt.exe] Error 1
mingw32-make.exe: *** [debug] Error 2
19:28:32: The process "C:\QtSDK\mingw\bin\mingw32-make.exe" exited with code 2.
Error while building project bitcoin-qt (target: Desktop)
When executing build step 'Make'

does anyone know whats going wrong here?
195  Economy / Services / Re: Will hold a big banner of your website in London. on: January 17, 2012, 11:45:20 PM
I dunno, $20 an hour doesn't seem terribly unreasonable.

I don't think id do it for anything under $20 a hour lol not worth my time i was just sayin there are lots of people that will do it a lot cheaper. tax season is almost here il be seeing a lot of people dressed up in statue of liberty suits
196  Bitcoin / Development & Technical Discussion / Re: Does anyone tryed to host bicoind on free Amazon AWS cloud? on: January 17, 2012, 05:28:47 PM
Read this:
http://siliconangle.com/blog/2011/08/01/third-largest-bitcoin-exchange-bitomat-lost-their-wallet-over-17000-bitcoins-missing/

sounds like a bad idea this pool lost over 17,000 coins using a amazon EC2 server
197  Bitcoin / Project Development / Re: Anyone want to fess up? on: January 17, 2012, 04:16:54 PM
lol probably a skid from http://hackforums.net/

most of them don't know how to code or anything they just buy scanners and trojans from other people heck most of the time they dont even know how to set them up lmao
198  Bitcoin / Project Development / Re: [PAY] Patch bitcoin v0.5.1rc2 to send a HTTP POST when a new block is accepted on: January 17, 2012, 10:14:51 AM
im actually working on something like this for myself just haven't had the time to work on it hopefully today i will have the time to get and compile all the dependencies and start coding... i have another project i need to finish up first though

check this patch out:
https://bitcointalk.org/index.php?topic=1319.msg15065#msg15065

monitorblocks <url> [monitor=true] [startblockcount=0]
POST block information to <url> as blocks are added to the block chain.
[monitor] true will start monitoring, false will stop.
Pass [startblockcount] to start monitoring at/after block with given blockcount.

199  Economy / Services / Re: Will hold a big banner of your website in London. on: January 14, 2012, 08:34:32 AM
Lol thats still like $20 a hour

hell i live in the US and some of my friends have dressed up in costumes and waved banners for companies around where i live before they only pay like $8-$10/hr max
200  Other / Beginners & Help / Re: Safety measurements of major exchanges on: January 14, 2012, 08:11:08 AM
"Safety measures" is what you wanted to use.
http://translate.google.com/ doesn't hurt.

For example somebody want to sell his coins for 10.1234 USD per Coin and accidently misses one key and is selling the coins for 0.1234 USD instead.

Answer that: how is MtGox supposed to know that you ACCIDENTALLY missed a key as opposed to using a very low rate rate ON PURPOSE?
People do crazy trades eg. when trying to manipulate the btc/usd rate. Is the purpose of a bitcoin exchange to interfere with their users' trading?
Does your bank tell you what they think about a bank transfer you are sending? No, because it's none of their business. The same goes for exchanges.

Don't trade when you're in a hurry, sick, tired, or intoxicated Smiley



Wake up please.

It just need to pop up a warning if the price you entered is like 120% or 150% different from current prices.

There is such a thing in the game EVE Online, if something cost 1000 and you type a sell order for 100 it warn you.

For example, http://wiki.eveonline.com/wikiEN/images/a/ab/Market3.jpg it tell you the % difference from regional average.

So please take back things like
Quote
Don't trade when you're in a hurry, sick, tired, or intoxicated
Quote
how is MtGox supposed to know that you ACCIDENTALLY missed a key as opposed to using a very low rate rate ON PURPOSE?
And other hurr durr
+1
Pages: « 1 2 3 4 5 6 7 8 9 [10] 11 »
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!