Search content
Sort by

Showing 20 of 31 results by Falkvinge
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 30/10/2014, 23:25:28 UTC
Two things:

It works.

It's wonderful.

I love this. I'm logged in to Swarmops (my current project) before my phone has even confirmed it has transmitted the signed nonce. This is as smooth as Lastpass' autologins, except 2FA since it combines what you have with what you know (your phone's password, in this case).

If anybody wants to copy my C#/Asp.Net code, feel free. The relevant parts are easy to extract from Login and BitId here:
https://github.com/Swarmops/Swarmops/tree/master/Site5/Security

They may still be a little unstable with regards to threading on Mono (which sometimes cuts a request short and strange things like that), but the code works at a prototype level.

Cheers,
Rick
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 30/10/2014, 03:44:17 UTC
Ooops. That sounds like a more serious issue.
On its side, BitID protocol does not state any specific order for the parameters.

I may be wrong but to my knowledge, there's no notion of order in json. A lib forcing an order for json content seems to me like a bad implementation of json.

I would agree with this and I'm not certain this is even the case. I'm on a wild goose chase for bugs at this point to find out why my implementation isn't responding.

Cheers,
Rick
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 30/10/2014, 03:42:39 UTC
Ok, now I know exactly what the HTTP request from Onchain looks like (which works against the BitID demo). No wonder I couldn't get it to work. The phone app doesn't use Json at all, but does a full webform post.

This is what I was asking for in the spec as a sample:

Quote
POST http://dev.swarmops.com/Security/BitId.aspx HTTP/1.0
Content-Length: 272
Content-Type: application/x-www-form-urlencoded
Accept-Encoding: gzip
Host: dev.swarmops.com
User-Agent: android-async-http/1.4.4 (http://loopj.com/android-async-http)

signature=H2ooalc68rfcS%2FnEIrrCH2zUKYvjIuj%2Bp9DoQoVVkW39R3wVfNnbO7Pmd4UdkNf6FpQ%2FUGV3pfm4vrE9541za%2Fg%3D&uri=bitid%3A%2F%2Fdev.swarmops.com%2FSecurity%2FBitId.aspx%3Fx%3D4b593383a4674b83b31d066e0e87e60f8d1c1df565f568f%26u%3D1&address=14fRQCbR62EGzjPQks9XRAVRiqWhftn3dA

And here I was trying to interpret Json and wonder why the server did absolutely nothing... Smiley
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 29/10/2014, 22:05:06 UTC
Here's my notes, written while working on the python library. Hope it helps.

Thanks, it does! I found at least one reason my server doesn't pick up the response.

Quote
/callback

Does it have to be this (partial) URI, or is it just a header describing this section? That's unclear. I have been using a different URI, as I'm using the [WebMethod] feature of Asp.Net that lets you embed a Json-callable function on any page.

Quote
   Parameters:
        uri : string - required - bitid uri used as the challenge
        signature : string - required - signature of the bitid uri
        address : string - required - address used for authentication

Can we lock down that the parameters come IN THIS ORDER? That's not explicitly written, and some implementations (like C# which I'm using) are or can be order-sensitive, even with parameter names supplied.

Testing again now.

Cheers,
Rick
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 29/10/2014, 20:18:33 UTC
http://bitid.bitcoin.blue/login
And click on "manual", you'll get a curl example showing exactly how to POST on the demo server implementation.

Thanks, but that's not what I need. I'm trying to write a server-side implementation. I need to know what the client is sending to me, and to be honest, that's not specified. I'm in the blind. I'm trying to use a BitID client and just see whatever it is sending by pushing debug code out to production (accessible) servers. That's not how any development should be done but I'm given no choice right now.

In a spec, I'm expecting, and asking for something like this:

SAMPLE CLIENT LOGIN REQUEST

Quote
POST /Security/BitId HTTP/1.1
Host: bitid.example.com
Content-Type: application/json

{ "addr":"1dsfagahigaeguropiaasdazd","sign":"ÖIUYFQ(Et5yn9se8hgs8f9dghjf","callback_uri":"https://bitid.example.com","bitid_uri":"https://login.example.com" }

SAMPLE SERVER RESPONSE

Quote
200 OK
(a HTTP response)

Do you see where I'm coming from? It just says that four specific parameters are submitted as part of an HTTP POST. It doesn't say anywhere how those four parameters are encapsulated and encoded. I need to know that in order to implement this. (In this example, I wrote the spec part as if they were submitted using Json, which I don't think they are, but you get the point.)

Cheers,
Rick
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 29/10/2014, 14:25:35 UTC
Some feedback - this part was not clear to me:

Quote
POST the signature, the URI and the public key to the callback URL

Specifically, in what standard format are the parameters passed? Using Json? Http headers? Encoded onto the Uri? What? A tangible example of the exact HTTP POST request sent from the client, byte by byte, would have been enormously helpful here. As is now, I'm blind on the server side - I don't know what data to expect and have to guess how the client sends its data?
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 27/10/2014, 08:50:22 UTC
I intend to implement this as a 2FA sign-on in Swarmops over the next two weeks. I've never seen _anything_ matching its ease of use.

Is there redistributable server-side code somewhere I can use as a template? My platform is ASP.Net and C#. I would rather not reimplement crypto code, but I am happy to change its syntax keywords from another implementation language.

Cheers,
Rick


(Swarmops: https://github.com/Swarmops/Swarmops)
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 20/08/2014, 15:03:12 UTC
It is indeed point and confirm for first time; and next time it will auto confirm. No need to select and address, it will be created on the spot.

I see the privacy gains of not using an existing bitcoin address for authentication.

Will the private keys of this address also be backed up along with the wallet addresses? If not, then some recovery mechanisms will be necessary app-side. I guess that's necessary anyway.

As long as primary UX is point-and-logged-in (no more steps than enabling camera and pointing it at screen), I'm happy. Once this UX is good enough, what are the prospects of getting into the mainline Android client?

Cheers,
Rick
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 19/08/2014, 20:45:11 UTC
(I'm assuming here that the Android Wallet fork makes use of the fact that the Android wallet already has an address selection mechanism on the home screen, so it's literally just point-and-you're done for authentication; no need to confirm or select signing address?)
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 19/08/2014, 20:25:50 UTC
I really really REALLY want to launch this as the preferred authentication method for a project I'm developing. The ease-of-use is positively outstanding, and in particular, the lack of need to install Yet Another App as it just piggybacks on the bitcoin wallet. Do we have any idea (best wild-ass guess) when bitID may be available in the mainline Android client, something even marginally better than "between yesterday and in two forevers"?

Cheers,
Rick
Post
Topic
Board Bitcoin Wallet for Android
Re: Support for BitID ("Connect with Bitcoin")
by
Falkvinge
on 15/06/2014, 15:33:09 UTC
I was surprised to find BitID was not yet supported by the standard Android wallet (the one discussed in this forum) as I started doing some server-side login development today.

Are there plans to include it? This is two-factor authentication simpler than a login/password combination, and displaying a QR code as a login challenge on the login screen would be great security-wise AND usability-wise.

Cheers,
Rick
Post
Topic
Board Development & Technical Discussion
Re: [BIP][Draft] BitID - "Connect with Bitcoin" protocol
by
Falkvinge
on 15/06/2014, 15:21:08 UTC
Chiming in:

This particular protocol is the best to happen to usable security in a very, very long time.

This simple protocol extension offers two-factor authentication at higher usability and security than a one-factor login/password combo.

Assuming most people have some sort of screen lock on their phones, this provides for a two-factor authentication at the ease of pointing your phone at the screen. Bravo! Applause!

I actually wanted to start implementing this protocol server-side today, and was surprised to see that my Android wallet didn't yet have support for it.

I can't wait to offer something as simple and secure as this to users of my systems.

Cheers,
Rick
Post
Topic
Board Service Discussion
Re: To all Bitcoin price indexes please De-list MtGox so we can move on
by
Falkvinge
on 28/02/2014, 14:03:20 UTC
I strongly disagree. Having the Gox price/volume history is and remains absolutely essential, especially right now to find traces of insider trading or other signals to cross-correlate.

That doesn't mean it has to be front page, but don't delete anything FFS.
Post
Topic
Board Bitcoin Technical Support
Re: Cold Storage? Is this secure!
by
Falkvinge
on 26/02/2014, 21:32:58 UTC
I did a write-up here on a cold storage setup that a few people have deemed secure. YMMV.
Post
Topic
Board Armory
Re: Feature request: QR code comms for signing
by
Falkvinge
on 22/02/2014, 12:58:59 UTC
The problem is, when the time that you fall outside that 95%, you have to resort to another solution (such as USBs), which compromises the whole thing.   We really need 100% in order to be useful.

Good point, conceded. It's the one weak link in the chain that you want to eliminate, and on second thought, this is sound security practice.

Quote
It's bi-directional.  We need to transfer transaction data to the online computer, sign, then transfer the signatures off

Again, conceded. I pictured two one-way sessions, where an operator would have to change directions (pretty much like the USB key communications today), but the ability to communicate optically in the first place enables one single session which starts with the transfer of the unsigned transaction and ends with the broadcast of the signed transaction. For extra sci-fi points, there could be audible notifications in a synthetic voice as to what stage the session is in.

Quote
On the other hand, having two laptops facing each other might actually work, since the cameras are built-in.

Good thinking! I did a short test here, and a laptop plus a desktop computer is also feasible, as long as you have a webcam on top of the desktop computer monitor. You'll have to hold the laptop in place, but still.

Quote
I would argue that audio is not really hijackable -- there is basically zilch remote-code execution potential, assuming the offline computer is not compromised.  We have to make that assumption because all bets are off, otherwise.  There's a countless number of ways to get the keys off the offline computer if you assume arbitrary code execution there.

I'm going to be a total pain in the ass and disagree with that assumption. I know from myself that I really hate it when people do this, but hear me out and evaluate the thinking here:

Experience with security practices dictate the assumption that your code is the only piece that hasn't been compromised - that yours is the "last piece of code standing". If the Armory binaries have been corrupted through real-time code modification, then the game is over, but there are many cases where malware could have gotten into the offline computer without the ability to affect Armory.

So if Armory is compromised, the game is over. But I would take the position that the offline computer can be compromised in userspace without Armory getting compromised, and even if malware is running all over userspace, Armory could still be very able to perform its task securely. (Of course, if malware makes it to root or kernelspace, the game is over, but that's because of its ability to subvert the Armory I/O or binaries in that case.)

Also, remote code execution isn't the only vulnerability to watch out for. The offline computer can have had malware planted on it through a number of bad means - everything from USB-level exploits through an adversary physically gaining access to the machine and maybe installing a keylogger, sniffers, etc., maybe even in hardware. It's not just remote execution you want to prevent - you want to prevent any ability for the offline computer to communicate anything but signed transactions to the outside world. Having a keylogger or other sniffer is bad, but it may not mean any damage in practice, if and only if those pieces of malware are unable to report their findings to the outside world.

So I'm equally concerned about the elimination of known potential back channels from possible malware on the offline machine. If an Armory user isn't familiar with sound security practices, it could even be code running in a different, deliberately installed user account that is the adversary.

Again, thank you for a great piece of software, and thank you for considering the idea of optical communications. I appreciate that you're already considering sonic communications as a way to mitigate the original problem.

Cheers,
Rick
Post
Topic
Board Armory
Re: Feature request: QR code comms for signing
by
Falkvinge
on 21/02/2014, 16:52:56 UTC
Personally, I think QR code video is a great solution.  But that's significantly more challenging than simple QR codes.  And so far, Armory doesn't have a utility for scanning even regular QR codes.  It will have to be a robust solution, because there might be megabytes of data to transfer (could be fixed if we had something like SIGHASH_WITHINPUTVALUE).

Hmm, good point. However, in the general case, a display cycling some 1-8 QR codes must surely be sufficient? I just aimed my phone camera at this QR code on Wikipedia, with some 1800 bytes, and it nailed it without blinking. I can't tell how many percent of transactions would be smaller than 6-7 kilobytes, but I imagine it would be the overwhelming majority.

So while there may be cases where this mode of communication is not available, is that a reason to exclude it from the 95%-98% of typical cases?

Quote
Also, I was hesitant to implement something that requires the user to have multiple webcams, and have their webcam drivers setup, and then try to figure out what to point where and when, and have wires everywhere.  It's doable, but it's also not necessarily user-friendly.

Is that really the case? The communication would be one-way, there's no need for ACKs as the receiving computer can read the sending screen until all codes have been read. No need for a two-way protocol. There's an operator there, after all, who is alerted to when the data transfer is complete in some way.

Quote
That doesn't mean we shouldnt' do it, it's just that it's not a perfect solution for a general purpose tool.  I'd rather people use USB, than get fed up with something complicated they can't get working and forego offline wallets entirely.

I totally agree that usability is key, and that secure usability is one of the bitcoin ecosystem's big problems right now - I'd even call it a showstopper until that problem is solved. However, Armory is already halfway to the point of solving this specific problem with its configurable user levels of advancedness.

Quote
However, we have more resources on our team now... we may be able to prioritize it.  Right now we have an audio cable solution in the works, which also utilizes an analog channel which should be pretty darned secure.  But it's not ready yet.

An audio channel is a clear improvement over a USB key, but still hijackable as a side channel in the dire case malware has found its way onto the computers: all operating systems I know of allow for multiplexing several simultaneous applications to/from audio. However, in the same vein, webcam access and screen real estate is exclusive to one application, giving an advantage to the operator knowing that Armory has exclusive control of the communications channel?

Oh, and also, I almost forgot: Thank you for this great piece of software.

Cheers,
Rick
Post
Topic
Board Armory
Re: Feature request: QR code comms for signing
by
Falkvinge
on 21/02/2014, 13:46:10 UTC
I believe the reason than Alan has not yet implemented this is because some transactions are too big to fit in a QR code.

Otherwise, yeah, it would be pretty handy.

The advantage of synchronous optical communications with sender and receiver in one place, as opposed to asynchronous messaging across time or location, is that you can display a visual stream of QR codes. Therefore, there's really no limit to the amount of data transferrable.

Cheers,
Rick
Post
Topic
Board Armory
Topic OP
Feature request: QR code comms for signing
by
Falkvinge
on 21/02/2014, 13:30:34 UTC
As seen in the howto I posted a few weeks ago, Armory is now my primary wallet for security reasons, as I've chosen to not trust third-party services any longer *cough* Gox *cough*. I believe my fellow Armorists share the concern of coin security, and have chosen Armory for that primary reason.

Once you have your private keys in a manner that they will never ever touch a computer that has been, is, or will be connected to the internet, you need to examine the communications paths with this offline computer from a defense-in-depth perspective.

The weak link today is in how the unsigned transactions go to the offline computer, get signed there, and are moved back to the online computer. Email or clipboard is obviously out of the question, as that would require connecting the cold storage to a network. So realistically, that means a file is stored on some medium, that medium is physically moved to the offline computer and connected there, the transaction is signed, and the medium is moved back. The only medium that is used this way today is a USB stick.

Here's the vulnerable point. USB sticks contain firmware that can be exploited and malware embedded. That, in turn, can be used as an attack vector against a target system's USB drivers. Assuming we trust Armory, which we kind of have to, we want to be sure that no communication can get piggybacked by covert malware onto Armory's communication between its online and offline counterparts.

As long as we're doing that communication on multi-gigabyte USB sticks, the potential for a covert side channel is enormous.

Therefore, seeing how security has been the foundation and priority in building Armory, I'd like to see the ability for the online and offline computers to communicate signed/unsigned transactions optically using QR codes, instead. Have the online computer display the unsigned transaction on-screen with a QR code, have the offline computer use its webcam to read it, and vice versa for the return comms.

That way, we can be much more certain that no covert side channel is being used to extract information from the offline computer. We still must trust Armory, but this was about eliminating the possibility of piggybacking covertly on the transfer of Armory's data, which can be achieved if Armory communicates optically instead of via files.

Comments?

Cheers,
Rick
Post
Topic
Board Bitcoin Discussion
Re: Enjoy?
by
Falkvinge
on 15/02/2014, 08:22:02 UTC
So what did you do with your 1EnJoy vanity address?  And, if you don't mind me asking, what is the meaning behind your username?   Not trying to accuse anyone of anything, but it is a pretty big coincidence. 
There's no reason to believe it's him.

It's not an 1EnJoy address. See the screenshot I posted.
Post
Topic
Board Service Discussion
Re: MtGox Now Wants Deposit/Withdrawal Verification For BTC!
by
Falkvinge
on 14/02/2014, 15:58:06 UTC
Verification for BTC-withdrawals has been in place for some time now, that's nothing new.

not at gox. it never was. you're thinking of fiat.

Verification for bitcoin withdrawals were needed as far back as May 2011, when I started using Gox.