Cupid and Understanding Your Exposure

In a past life I was responsible for a number of Windows Enterprise Networking technologies including the EAP implementation and was a contributor to EAP-TLS.

As a result when I saw the Heartbleed vulnerability announced I was painfully aware of what an attacker could do if they encountered a EAP-TLS implementation based on a vulnerable version of OpenSSL.

I have read a few articles this morning discussing the implications to those who use EAP-TLS and many of them get it wrong; the core issue being they don’t seem to understand the various actors in a EAP-TLS negotiation.

To understand how EAP works you need to understand the following terms:

Peer; this is the client to the wireless network. Be it your desktop, laptop or mobile phone (though EAPs use is not limited to these types of devices). Sometimes this will be called the supplicant.

Authenticator; this is your wireless router, when it comes to authenticator this entity delegates that responsibility to the authentication server (typically over RADIUS).

Authentication Server; this is the entity who is responsible for deciding if the peer can have access or not, it is also typically the EAP-Server but it can delegate this to another entity as in the case of complex wireless federation systems like.

EAP Server; this is the entity who actually implements the EAP protocol.

When a client connects to a router the router is configured to forward all requests to an Authentication Server. This results in a tunnel through the router to the authentication server.

In the most common case that authentication server implements the EAP protocol along with all of the various protocols (methods) that it supports.

In a Windows environment that server is called the Network Policy Server (NPS),  CISCO’s is called Cisco Secure Access Control Server (ACS), Juniper’s is called Steel Belted Radius (SBR) and the two most common Open Source distributions are OpenRADIUS and FreeRadius both of which use OpenSSL ([1], [2]).

The reason I wrote this is most of these articles talking about CUPID do so in such a way that it suggests the wireless router itself is the issue; while this is technically possible because there are routers out that also contain the authentication server and EAP Server these are not commonly used – especially with a TLS based EAP method. The main reason for this is that this quickly doesn’t scale, one of the largest reasons being that environments mature enough to take on the management overhead of a TLS based solution also probably have to provide service to a space larger than a single access point could cover.

There is another class of wireless access solution that leverages a “wireless controller” that manages multiple radios for this very reason. These solutions also often have built in RADIUS and EAP servers (and in my experience they are based on one of the above OpenSource solutions) but again this capability doesn’t appear to be used often with TLS based EAP methods since organizations often already have existing authentication infrastructure (Active Directory and NPS for example) that they leverage instead.

Long story short your probably only at risk of this if your using one of the Open Source Radius servers but since some vendors just repackage this code there are deployment models where you may be exposed its just not super likely. Here is a quick decision tree to help you understand your exposure:

Cupid Exposure

Bitcoin adoption in payments

If you talk to someone about using Bitcoin as a payment technology your surely going to hear about how governments are classifying it as an asset and not a currency and what the corresponding tax implications are.

While I think the current tax situation is unfortunate and hope this trend changes I don’t think this is the largest issue (just look at the sales online retailers are seeing despite this change as a proof point). In-fact there is so much slop in the payments system it might even be reasonable to cover the tax implications through the efficiency improvements Bitcoin can bring to the ecosystem.

I think the larger issues are in-fact that the incentive models for the incumbents are such that it’s not likely they will be the ones driving this change.

Just consider that we have been using technology known to be grossly insecure for card-present transactions for over twenty years and even though viable alternatives exist they have not been adopted.

That despite the massive shift to online sales these incumbents have not presented the market a payment solution designed to work well for the Internet.

The rational for not doing so makes sense; when you are the incumbent you resist change as it has potential to weaken your position and the costs of the security issues (as long as measurable) can simply be passed on to the merchant as long as the buyers keep buying.

Simply put they have little incentive to change.

Despite this change is on the horizon; as more and more goes online the relevance of card present transactions diminish (link to retail buying trends) the world also becomes a smaller place and these incumbents start to face competition from governments with their own payments infrastructure like in Singapore and other countries.

This means customers are starting to have choices and as such there is a prime opportunity to see a seismic shift in the way these incumbents look at their businesses.

This shift may provide the impetus to the incumbents to modernize and address these competitive risks. One way that modernization could manifest would be through their own adoption of a virtual currency like Bitcoin or acquire the new entrants with solutions in these space; for example:

  • Payment processors could go out and buy large private mining concerns as their role is in Bitcoin is essentially the same.
  • Card Networks or issuing banks might go out and buy online wallets like BitGo and Blockchain.
  • Acquiring banks could go and buy payment providers like CoinBase and BitPay.

Regardless of how such a migration happens the use of a virtual currency as a foundational payments technology has the potential to reduce the number of entities involved in each transaction making transactions more secure and cheaper. If embraced by the incumbents in the payment ecosystem this could even align with their logical view of the world.

Bitcoin and the credit card ecosystem

We use our credit cards every day yet most of us don’t really understand what happens when we swipe a credit card at a merchant. Did you know there are no less than six different players (above and beyond the consumer and the merchant) involved in a typical transaction?

Acquiring Banks – These are the retail banks that serve the merchant, you can think of them as the entity managing the bank account where deposits go for the merchant.

Payment Processors – These are actually the entities that really make credit cards work, they ensure everyone gets paid in accordance with the associated agreements. Some of the largest players here are FirstData, Heartland, Chase and Bank of America.

Issuing Banks – These are the banks that serve the consumer by providing them credit cards. They not only evangelize and sell the cards but own the customer relationship.

Service Providers – It used to be the only way to take credit cards was to work with your “acquiring bank” but now consultants handle this work for the banks.

Hardware Providers – Those clunky credit card terminals come from somewhere as to the point of sale terminals stationed in every retail establishment you visit. One of the largest is Verifon.

Credit Card Networks – This is Visa, Mastercard, American Express and Discover these guys don’t really clear transactions they instead establish the rules by which the system works and establish the technological standards the system uses.

Each one getting a piece of every transaction performed with that card, that cut can range from 2% to 3% of a transaction; if we assume the low end for a $100 transaction this looks something like this:

Merchant  $98.00
Issuing Bank  $1.50
Card Network  $0.15
Split between payment processor, Service Provider and Acquiring Bank  $0.35

This is of course before currency conversion fees, interest, card-fees, credit card rewards, charge backs and the numerous other variables at play in these transactions.

Some reports suggest in 2013 there were more than $4 trillion in these card-based transactions in the US alone. It’s also worth noting that in the US more than many other countries cards are being used for smaller and smaller transactions and this trend is likely to expand as cash becomes less convenient.

Startups like Square and Level-up are trying to disrupt these card-present transactions like Paypal has done for the card-not-present transactions and by doing so they are really going after a share of the that .35c that is currently split between the various players and the money the hardware providers get out of the merchant.

This is a great business but the sheer number of players involved in the system makes it hard to make ends meet. These players try to game the system by building additional products based purchasing behavior and batching transactions but the current system is so complicated with and has so many players its simply hard to get the slop out.

More over the standards set by the credit card networks are weak, the technologies these systems are based on are easily compromised and even their more secure counterparts based on chip-and-pin don’t live up to their security promises.

Then there is the question of usability of these systems which are far from optimum, we have all tried swiping our cards or entering the pin finding the readers unable to work with the cards or seen someone swipe the card the wrong way.

NFC has long been touted as the solution to some of these problems but despite being over 10 years old, has its own security issues, has hardly been deployed and at best is just a new hardware layer on the already overly complicated system.

One way to address these problems is to setup a separate system that runs along side this existing framework. This system would be designed to be more secure, easier to use and have fewer moving parts. Such a system if done right could get the slop out of the payments system, merchants could get paid quicker, keep more of their profits, consumers and merchants alike could experience less fraud and we could even have a more usable system.

Bitcoin has the potential to be the catalyst and foundation to make this happen; I don’t think we will see card-present transactions based on efficient models of bitcoin use in the near future but I do think it will happen.

If this approach can simply half the current cost structure of the payments that would put 1%-1.5% back in the merchants pockets, if along the way it reduces charge backs, currency conversion fees, and the other miscellaneous charges that infect this system it can foundationally change the way we look at commerce.

Bitcoin has this potential and I for one am excited to see what the next few years have in-store.

Proving assets under management is important but it is not an audit

Recently Bitstamp did a public display of assets under management and while I think its important they and others (like Kraken and the Vault of Satoshi) do this it does not an audit make.

Just look this video where Roger Ver attests things look good at Mt. Gox or what happened with Neo&Bee.

Don’t get me wrong what Bitstamp, Kraken and Vault of Satoshi are doing is great but they are not “audits” at least useful ones.

au-dit : an official inspection of an individual’s or organization’s accounts, typically by an independent body.

What kind of litmus test must be passed for me to consider something a useful “audit”?

  1. Does it look at evidence in balance? For example if someone has a million dollars in the bank but has signed first right debt agreements for two-million your still likely out of luck in the event they go under.
  1. Does it look at the complete picture? Its entirely possible an entity has all of its assets under its control and is debt free but the principals have unobstructed access to the funds or that the security and engineering practices are so lax that at any given moment a system can be compromised without detection.
  1. Does it measure practices to a standard? Audits are performed to some standard, for example the Sarbanes Oxley audits use a standard set of criteria that help assure financials are being tracked published accurately. While the WebTrust for CA audits ensures that certificate authorities are following common minimum standards for securing their operations.
  1. Is the standard relevant to the business in question? The risks in each system are different even if only subtly; there are many things in a WebTrust for CA audit that might be relevant to a bitcoin exchange but there are just as many things that are not the same is true for a SOX report. For an audit to be valuable it has to be one that was designed to prove something relevant.
  1. Is it performed by an independent third-party? Conflicts of interest are abound and when money is involved people often do the wrong thing. While the use of celebrity people from the community in a pinch is fine (and no disrespect intended) these individuals have a vested interest in the success of bitcoin.
  1. Is it performed by a qualified individual or group? Often times the “low bid” auditor wins but these are the same auditors who ask for stupid things.

So to-date has there been a single usfull bitcoin audit? I think its safe to say no. I would go so far to say that the practices of most Bitcoin entities are not actually audit-able because one has to design processes and procedures to ensure that they are and this slows down the “innovation train”.

In Coindesk post about Bitstamp’s “audit” Mike Hearn was quoted as saying “It’s a bit early to be setting standards yet” I would respond by asking the question if not now when? In my opinion this is exactly the right time to be tackling this problem.

These standards take time to be developed and have impacts on the way businesses operate and starting now not only ensures that the rapid growth in the Bitcoin ecosystem takes into consideration meeting some shared requirements on liquidity, solvency, audibility, transparency and security but by doing it now the requirements end-up being defined by the Bitcoin community instead of thrust upon it.

Regardless we need to be honest about what’s being shown when these events occur, they do little more than prove an entity has an amount of Bitcoin but nothing more.

Liquidity risk and management in Bitcoin

In finance, liquidity risk is the risk that a given security or asset cannot be traded quickly enough in the market to prevent a loss (or make the required profit). 

This of course begs the question how liquid do you need to be? Surely the answer is at least partially tied to the volatility of the asset in question and what your individual exposure to the potential loss might be.

When it comes to Bitcoin, at least more so than with physical assets, the more liquid you are the more at risk you are in that liquidity also means that the corresponding wallet keys are easily accessible.  And the more accessible the corresponding keys are the more at risk they are.

One can manage these risks a number of ways the most simple being not keeping “all your eggs in one basket” by keeping only the funds that must be readily available “online” and then using schemes like P2SH and Shamir Secret Sharing to manage the associated keys.

The Bitcoin ecosystem has clearly embraced these things as concepts, at least in the abstract in that “cold wallet” and “hot wallet” are synonymous concepts in the ecosystem. With that said the strategies you use to mitigate risk when you hold $10,000 USD should be different than when you hold $100,000 USD and this is not something individuals have had to take responsibility for historically.

One of the most fundamental changes Bitcoin represents today is that you, the principal are now also principally responsible for keeping your funds safe. Despite this we are still faced with the problem people struggle to understand the risks they are exposed to on the digital realm.

This is why in Bitcoin’s short history we find case after case of individuals putting their assets in the hands of under funded practically anonymous entrepreneurs with no real experience in finance or computer security.

The recent influx of capitol into the Bitcoin ecosystem has the potential to change this but it will also change the nature of Bitcoin at least in-part. The technology has been painted as the Libertarian’s dream and in many respects it might be but for broad acceptance it needs to embrace some level of regulation if it’s to see adoption outside that niche.

Liquidity risk management is a great example; How much of their assets should an exchange keep online? How quickly do they need to settle transactions? Should they be required to have 100% of the funds associated with their internal ledgers? Should they keep their assets and liabilities private or make them public? Should they be mandated to have security and fraud-analytics in place so they can detect abuse and market manipulation? Should they be required to carry insurance to protect consumers from negligence?

It is my belief that requirements like the above would strengthen the Bitcoin ecosystem and make it a more viable means for the less technical and the financial ecosystem to adopt Bitcoin.


SWIFT, CHIPS, ACH, Fedwire and Bitcoin…

Bank transfers, especially international bank transfers, can be incredibly complicated with many players both directly and indirectly involved.

As you might imagine its actually even more complicated and nuanced than it looks on the surface; in fact banks often times maintain accounts with each others to accelerate transfers as well.

This on the surface makes lots of sense but when you consider that in the US alone there are around 6,800 federally insured financial institutions and that there are over 200 sovereign nations that this quickly becomes an unworkable approach.

This is why there are these clearing-house entities; they act as brokers of these relationships.

Something else that many don’t realize is that not all banks belong to these organizations. As a result there is a routing problem that’s not dissimilar to the routing problems on the internet — there are many ways those funds might get transferred from one location to another each with their own cost and performance penalties.

But if only some banks belong to these organizations and every bank doesn’t have an account with each other how do they facilitate the interbank transactions? Through intermediaries of course; often via larger banks just like how the smaller banks outsource credit cards to third-party card issuers.

Over the years numerous attempts have emerged to modernize the banking system but interests are entrenched and something as fundamental as banking doesn’t change overnight. The efforts that have been successful have either looked like new products for banks to sell or solve immediate and tactical cost structure issues in their businesses.

Unfortunately this often results in more transactional intermediaries and not less, this is why in 2014 when we have global internet connectivity can still take a week (or more) for interbank transfers to actually settle.

One of the reasons I like Bitcoin is it represents a model where this slop and inefficiency can be removed which can dramatically speed up the financial system at the same time it has the potential to significantly reduce costs to all the players in the ecosystem and in the process kick off a new wave of innovation.

The largest hurdles are certainly regulatory and resistance to adopt technologies not under their direct control but like the ban on export of strong cryptography from the United States any restrictions that are put in place will only last for a limited time because its impossible to stop to use of the associated concepts and when their critical mass represents a competitive disadvantage the financial ecosystem would jump in near unison to take advantage of them.

Beyond Builders, Defenders, and Breakers

There are lots of different types of Security Practitioners out there. At a high level they can all be thought of as Builders, Defenders or Breakers.

Another taxonomy commonly used categorizes them into more role-focused categories:

  • Operations Security (OPSEC)
  • Communications security (COMSEC)
  • Counter-intelligence
  • Information security (INFOSEC)
  • Signal Security (SIGSEC)
  • Transmission security (TRANSEC)

Unfortunately neither of these taxonomies does an effective job at expressing areas of focus nor skill-set.

That is not to say these taxonomies are not valuable but the leave me wanting. It also seems if I tell someone I work in “computer security” they either immediately ask me if I can hack someone’s Facebook account or they ask me about what antivirus they should run; this of course isn’t how I think about security either.

So how do I think about security practitioners? I try to categorize them based on their areas of specialty and professional focus and for me this looks something like this the bellow mind-map.

Security Practitioner









Attacker Mind Map for Bitcoin

When thinking about how to protect something its useful to think about who you are protecting from. This normally starts with brainstorming categories of attackers along with their capabilities and motivations. From there you often move on to defining persona’s for the attackers that help personalize and more granularly categorize their skills, resources and motivations.

This is just a quick stab at a Mind Map of who potential attackers are for a Bitcoin business, you may also be interested in the post I just did on Bitcoin itself. Both are far from complete but they might be useful to you when thinking about how to to protect your systems and prioritize appropriately.

Bitcoin Attacker Capabilities and Motivations

Hardware Based Key Management and Bitcoin

Hardware based key management solutions like Smart Cards and Hardware Security Modules provide a lot of value. Probably the most important being that the keys are moved out-of-process into a totally separate computer. This goes a long way towards protecting keys from being stolen via by malware or exposing keys to an attacker via software defects like happened with Heartbleed.

Depending on the device you choose you may also get:

  1. Third-party assurances that their cryptographic implementations and random number generators are sound which is incredibly hard to be sure of when you just pick something up blindly off the Internet.
  2. A verifiable supply chain with third-party assurances and audit trails the devices have not been tampered with.
  3. Hardware that makes it obvious it has been tampered with and is resistant to such attacks.
  4. Protection from side channel attacks such as Differential Power Analysis, Electromagnetic Leakage and Timing Attacks.
  5. Basic policy enforcement mechanisms like preventing keys from being exported, limiting which users can use them and requiring M of N users approve.
  6. Mechanisms to securely clone keys from one device to another to improve survivability of failure and compromise.
  7. Some devices support the concept of “Remote Pin Entry Devices” so that the cryptographic device can be stored in one location but the tokens used to approve an operation to happen with the keys managed by it can be located anywhere on the globe.

Despite how valuable these solutions are they are not without their shortcomings one of which is that for the last twenty years they have not changed much short of getting faster and adding support for newer mandated algorithms.

One of the reasons these devices have not changed is that Common Criteria (CC) and FIPS 140-2 verification, the standards they must conform with to be sold to their largest customers, make it excruciating hard to change and as such the incentive model is set up to discourage innovation and often encourage bad behavior.

These restrictions also have resulted in them not supporting algorithms not mandated by these standards this means in the case of Bitcoin the decision to use secp256k1 in the protocol precludes their use or limits their use to a limited feature set and significantly reduced performance.

Additionally since PKCS#11 (the library one uses to work with these devices) doesn’t specify how to generate a secp256k1 key any code written to use such device ends up being proprietary.

The net-effect of this is if you buy one of these devices your going to be spending $5,000 for a device that gives you some of the above properties that you can write custom software on that would be able to do about 24 secp256k1 operations a second.

This is more than enough for a personal wallet but nowhere near enough for an exchange or payment provider; which means these vendors, are not using these sorts of techniques to keep your keys safe.

There have been a number of solutions that have been started by individuals to bring some of these protections to Bitcoin to-date they are all incomplete, unusable, unmaintained or not available.

The most promising being the Trezor but based on what we know of these systems its seems very unlikely they will provide the kind of protection one gets from a commercial hardware security module or many of the other features these devices often have.

And even if they do since they are for the most part by individuals with limited resources who knows if they will be around or available a year from now? If you have lots of Bitcoin in these devices and the vendor goes down or the device fails what are you to do?

That is not to say this these projects are not good, in-fact I will order a Trezor once they start taking orders again but they should be thought of as a Wallet and not a Safe or Vault as they will not protect from a well healed attacker and without much more work are not appropriate for cold-wallet storage of large amounts of Bitcoin.