Bitcoin Forum
December 04, 2016, 06:14:17 AM *
News: To be able to use the next phase of the beta forum software, please ensure that your email address is correct/functional.
 
   Home   Help Search Donate Login Register  
Pages: [1] 2 »  All
  Print  
Author Topic: [REVIEW] Name lookup branch (bitcoind send genjix@fishysnax.com 99999)  (Read 6845 times)
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 10, 2011, 06:22:19 AM
 #1

- I plan to put in account locking after several wrong attempts (lock 30 mins after 5 wrong attempts).
- Password recovery is handled by the server admin- their own policies.
- I originally thought to update periodically with the name server but if you're generating a ton of keys then your wallet will get big very quickly... maybe it could update with the server everytime you generate a new key.

This was on the development roadmap, http://bitcointalk.org/index.php?topic=4170.msg60385
"design/implement a secure DNS-like "map string to bitcoin address" system  (so I can send bitcoins to "gavin@acm.org")"

https://github.com/genjix/bitcoin/tree/bitnom
(install libcurl-dev)

I've setup a test server at fishysnax.com

If you want to make an account then run:
bitcoind updatens yournickname@fishysnax.com yourpassword

That creates a new account if it doesn't yet exist. It also updates the stored address too everytime you run that.

You can change your password with:

bitcoind setnspassword yournickname@fishysnax.com yourpassword newpassword

And you can send me a tip with either:

bitcoind send genjix@fishysnax.com 10
bitcoind send 1GPBcN1wKSZ1L3FAQ1hpz9GGr1sPeAZgg8 10

(Spent all my BTC on new laptop after it broke... Still owe him 50 BTC Wink
1480832057
Hero Member
*
Offline Offline

Posts: 1480832057

View Profile Personal Message (Offline)

Ignore
1480832057
Reply with quote  #2

1480832057
Report to moderator
1480832057
Hero Member
*
Offline Offline

Posts: 1480832057

View Profile Personal Message (Offline)

Ignore
1480832057
Reply with quote  #2

1480832057
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 10, 2011, 06:29:08 AM
 #2

to run the server you need LAMP

cp bitcoin/contrib/ns/* /var/www/

in mysql:
CREATE DATABASE bitnom;
CREATE TABLE lookup(nickname VARCHAR(100) NOT NULL, PRIMARY KEY(nickname), passhash VARCHAR(128) NOT NULL, address VARCHAR(44) NOT NULL);
(as specified by DATABASE file)

create a file in /var/db.bitnom.inc with these contents:
<?php
   mysql_connect('localhost', 'your_login', 'your_pass') or die(mysql_error());
   mysql_select_db('bitnom') or die(mysql_error());
?>
(as specified by db.php)

It should work now.
mizerydearia
Hero Member
*****
Offline Offline

Activity: 574



View Profile
March 10, 2011, 06:32:44 AM
 #3

to run the server you need LAMP

Is PostgreSQL acceptable?
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 10, 2011, 03:49:29 PM
 #4

to run the server you need LAMP

Is PostgreSQL acceptable?

Try it. Should work I think.

Could you turn on SSL as well for me to test?

BTW GET is enabled for accessing people's addresses, like:

http://fishysnax.com/getaddress/?nickname=genjix

(but not for anything else).
Luke-Jr
Legendary
*
expert
Offline Offline

Activity: 2086



View Profile
March 10, 2011, 05:23:47 PM
 #5

This would make for a good replacement for IP transactions, if it is specified to support comments (can be used to say who it is from, or what invoice is being paid) and uses SRV records. Unlike IP transactions, the simple HTTP nature allows people to just upload a script with a pre-defined list of addresses and write the comments for each address, using a stock web hosting service...

jgarzik
Legendary
*
qt
Offline Offline

Activity: 1470


View Profile
March 10, 2011, 06:29:13 PM
 #6

Just use TXT records and the current x-btc: URI specification.

Jeff Garzik, bitcoin core dev team and BitPay engineer; opinions are my own, not my employer.
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 10, 2011, 08:14:51 PM
 #7

Just use TXT records

Why? Not everyone wants to get a hostname and they prefer to use a provider.
jgarzik
Legendary
*
qt
Offline Offline

Activity: 1470


View Profile
March 10, 2011, 08:21:34 PM
 #8

Just use TXT records

Why? Not everyone wants to get a hostname and they prefer to use a provider.

If you are using a provider, then the provider can use TXT records.


Jeff Garzik, bitcoin core dev team and BitPay engineer; opinions are my own, not my employer.
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 10, 2011, 08:44:11 PM
 #9

But you still need to set the records or new passwords using bitcoin. ATM that's done by POST requests using bitcoin rpc commands (setnewpassword, updatens).

The only change is that now you require that anybody that wishes to setup a provider must also setup a DNS.

Like this anybody can buy a cheap webhosting service with a free DNS. Then they create an account and disable others making new accounts (so it's only for them).

What does have a DNS offer in exchange? Here you can see a request, http://fishysnax.com/getaddress/?nickname=genjix

Just asking.
jgarzik
Legendary
*
qt
Offline Offline

Activity: 1470


View Profile
March 10, 2011, 09:00:39 PM
 #10

Like this anybody can buy a cheap webhosting service with a free DNS. Then they create an account and disable others making new accounts (so it's only for them).

What does have a DNS offer in exchange? Here you can see a request, http://fishysnax.com/getaddress/?nickname=genjix

Directly storing the information in DNS is much faster, with newer network lookups and connections.

The official bitcoin client simply isn't designed for storing and serving lots of little bits of static data to the general public.

Jeff Garzik, bitcoin core dev team and BitPay engineer; opinions are my own, not my employer.
Donations / tip jar: 1BrufViLKnSWtuWGkryPsKsxonV2NQ7Tcj
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 10, 2011, 09:23:55 PM
 #11

Like this anybody can buy a cheap webhosting service with a free DNS. Then they create an account and disable others making new accounts (so it's only for them).

What does have a DNS offer in exchange? Here you can see a request, http://fishysnax.com/getaddress/?nickname=genjix

Directly storing the information in DNS is much faster, with newer network lookups and connections.

The official bitcoin client simply isn't designed for storing and serving lots of little bits of static data to the general public.

I'm not sure you understand how the patch works...

And lookups are done with bog standard MySQL. You can't get faster than that. And talking about speed here for a name lookup is premature.

Still not sure what you're arguing... Are you saying that each user is assigned a subdomain like: genjix.wikipedia.org ?
chromicant
Jr. Member
*
Offline Offline

Activity: 40


View Profile
March 10, 2011, 10:07:40 PM
 #12

Directly storing the information in DNS is much faster, with newer network lookups and connections.

The official bitcoin client simply isn't designed for storing and serving lots of little bits of static data to the general public.

How would you see this work? I have an email that's, say, chromicant@gmail.com or something@gimp.org. I don't quite have control of the DNS servers in question...one I can nag an admin to change, and the other would never insert something into their DNS at this point.

How would I be able to find the mapping of email to a bitcoin address to send BTC? Or am I completely missing the point of this exercise?

Hal
VIP
Sr. Member
*
expert
Offline Offline

Activity: 314



View Profile
March 11, 2011, 07:54:36 PM
 #13

This was on the development roadmap, http://bitcointalk.org/index.php?topic=4170.msg60385
"design/implement a secure DNS-like "map string to bitcoin address" system  (so I can send bitcoins to "gavin@acm.org")"
I had the impression the roadmap called for a BitDNS-like decentralized mapping system, since Gavin asked to map "strings" to addresses. Maybe I misunderstood.

Hal Finney
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 11, 2011, 08:04:20 PM
 #14

This was on the development roadmap, http://bitcointalk.org/index.php?topic=4170.msg60385
"design/implement a secure DNS-like "map string to bitcoin address" system  (so I can send bitcoins to "gavin@acm.org")"
I had the impression the roadmap called for a BitDNS-like decentralized mapping system, since Gavin asked to map "strings" to addresses. Maybe I misunderstood.

I think you did.

- BitDNS is a block chain decentralised DNS system.
- DNS-like means a system like DNS (federated servers).
Gavin Andresen
Legendary
*
qt
Offline Offline

Activity: 1652


Chief Scientist


View Profile WWW
March 12, 2011, 01:31:50 AM
 #15

I had the impression the roadmap called for a BitDNS-like decentralized mapping system, since Gavin asked to map "strings" to addresses. Maybe I misunderstood.

In my head I was imagining a way of telling bitcoin to subscribe to some service(s) that did the mapping-- maybe a setting in the GUI where you could specify "use these six services, in this order, to try to resolve bitcoin addresses that aren't plain-old-bitcoin-addresses."  With the services specified by name+URL (and some standard REST-ful protocol was defined for mapping string to bitcoin address).  Or maybe name+pattern+URL.

I haven't looked at genjix' patch, and haven't thought deeply about security issues-- but I bet there are lots...


How often do you get the chance to work on a potentially world-changing project?
Luke-Jr
Legendary
*
expert
Offline Offline

Activity: 2086



View Profile
March 12, 2011, 02:16:21 AM
 #16

Reasons to use HTTP over DNS:
1. Compatible with cheap webhosting available anywhere
2. Can generate new addresses (or pull them off a list) for every transaction
3. Can be provided a comment, invoice ID, or from address to save in a database (associated with the generated address)

genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 12, 2011, 03:02:50 AM
 #17

Usernames are case insensitive and can contain any character.

Urls can have port numbers and paths attached.

**@genjix@** rules@fishysnax.com:443/path/to/

That's a valid address. The username = "**@genjix@** rules"

Now the URL is called using some remote methods like url + path + '/getaddress/' so that the implementation is non-specific to PHP. Anybody is free to create their own specific implementation with their own server policy. The current policy happens to be very simple (update record, set password, get address).

Like a user who wanted to setup their own private provider could setup an implementation on their server and disable creation of new accounts.

Obviously I want to get something in there with PK crypto... But haven't come up with a properly secure scheme yet. Many of them are prone to MITM attacks. However this can be used for small amounts effectively like a post on irc for somebody to send you X BTC to genjix@foo.org without having to open bitcoin.

There's 2 class of queries- the public fetch record (uses GET) and the 2 calls to change things and require a password (and hopefully more security in the future- uses POST).

The POST queries return a JSON. If there's a key by the name of "status" then it was successful and the value will give you an update as to what occured. If there's a key called "error" then it was unsuccessful and the value is an error message. The JSONs can also have other entries depending.
Gavin Andresen
Legendary
*
qt
Offline Offline

Activity: 1652


Chief Scientist


View Profile WWW
March 12, 2011, 03:18:58 AM
 #18

Seems like this feature doesn't need to be part of the RPC interface-- why not just (ignoring error handling/etc) do the equivalent of:

Code:
ADDRESS = $(curl https://fishysnax.com:443/path/to?id=genjix)
bitcoind sendtoaddress $ADDRESS 1

... from whatever code is calling the RPC?


How often do you get the chance to work on a potentially world-changing project?
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 12, 2011, 04:13:29 AM
 #19

Seems that domain names doesn't need to be part of your web browser. Why not do:
Code:
BAR=$(grep google /etc/hosts | split 1)
firefox $BAR

You know it's not the same.
genjix
Legendary
*
expert
Offline Offline

Activity: 1232


View Profile
March 12, 2011, 04:19:01 AM
 #20

I'm thinking that on first usage, it seamlessly creates a new account and uploads the public key of the first bitcoin address in your wallet. Then you sign further POST requests using that key. That way the server can verify that you are who you claim to be.

Should a person need to have their public key changed/removed (because they lost their wallet) then they can contact the server admins and they can decide how/whether to delete their account so they can create a new one.
Pages: [1] 2 »  All
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!