Dangerous Errors
Podcast Posts Presentations Synthwave About
Podcast Posts Presentations Synthwave About
  • RSA APJ 2014, CDS-W07 Slides Jul 30, 2014

    Here are the slides for my presentation, "Building and Breaking Privacy Barriers", at this year's RSA Asia Pacific and Japan conference in Singapore.

    The slides convey more theory than practical examples, but the ideas should come across without too much confusion. I expect to revisit the idea of a Rot network (a play on Tor) and toy with an implementation. Instead of blocking tracking bugs, the concept is to reduce their utility by sharing them across unrelated browsers -- essentially polluting the data.

    In any case, with this presentation over and out of the way, it's time to start working on more articles!

  • A Monstrous Confluence May 10, 2014

    You taught me language, and my profit on't

    Is, I know how to curse: the red plague rid you,

    For learning me your language!

    -- Caliban (The Tempest, I.ii.363-365)

    The announcement of the Heartbleed vulnerability revealed a flaw in OpenSSL that could be exploited by a simple mechanism against a large population of targets to extract random memory from the victim. At worst, that pilfered memory would contain sensitive information like HTTP requests (with cookies, credentials, etc.) or even parts of the server’s private key. Or malicious servers could extract similarly sensitive data from vulnerable clients.

    In the spirit of Caliban, Shakespeare's freckled whelp, I combined a desire to learn about Heartbleed’s underpinnings with my ongoing experimentation with the new language features of C++11. The result is a demo tool named Hemorrhage.

    Hemorrhage shows two different approaches to sending modified TLS heartbeats. One relies on the Boost.ASIO library to set up a TCP connection, then handles the SSL/TLS layer manually. The other uses a more complete adoption of Boost.ASIO and its asynchronous capabilities. It was this async aspect where C++11 really shone. Lambdas made setting up callbacks a pleasure — especially in terms of readability compared to prior techniques that required binds and placeholders.

    Readable code is hackable (in the creation sense) code. Being able to declare variables with auto made code easier to read, especially when dealing with iterators. Although hemorrhage only takes minimal advantage of the move operator and unique_ptr, they are currently my favorite aspects following lambdas and auto.

    Hemorrhage itself is simple. Check out the README.md for more details about compiling it. (As long as you have Boost and OpenSSL it should be easy on Unix-based systems.)

    The core of the tool is taking the tls1_heartbeat() function from OpenSSL's ssl/t1_lib.c file and changing the payload length — essentially a one-line modification. Yet another approach might be to use the original tls1_heartbeat() function and modify the heartbeat data directly by manipulating the SSL* pointer's s3->wrec data via the SSL_CTX_set_msg_callback().

    In any case, the tool's purpose was to "learn by implementing something" as opposed to crafting more insidious exploits against Heartbleed. That's why I didn’t bother with more handshake protocols or STARTTLS. It did give me a better understanding of OpenSSL's internals. But still, I'll add my voice to the chorus bemoaning its readability.

  • RSA USA 2014, DSP-R04A Slides Feb 28, 2014

    Here are the slides for my presentation, DSP-R04A Is Your Browser a User Agent or a Double Agent?, at this year's RSA USA conference in San Francisco.

    This departed from a security focus into the realm of privacy, noting how browsers struggle (or not) against tracking mechanisms and how various organizations build views of web site visitors.

  • Audit Accounts, Partition Passwords, Stay Secure Jan 6, 2014

    It’s a new year, so it’s time to start counting days until we hear about the first database breach of 2014 to reveal a few million passwords. Before that inevitable compromise happens, take the time to clean up your web accounts and passwords. Don't be a prisoner to bad habits.

    There's no reason to reuse a password across any account. Partition your password choices so that each account on each web site uses a distinct value. This prevents an attacker who compromises one password (hashed or otherwise) from jumping to another account that uses the same credentials.

    Penny-farthing

    At the very least, your email, Facebook, and Twitter accounts should have different passwords. Protecting email is especially important because so many sites rely on it for password resets.

    And if you’re still using the password kar120c I salute your sci-fi dedication, but pity your password creation skills.

    Next, consider improving account security through the following steps.

    Consider Using OAuth — Passwords vs. Privacy

    Many sites now support OAuth for managing authentication. Essentially, OAuth is a protocol in which a site asks a provider (like Facebook or Twitter) to verify a user’s identity without having to reveal that user’s password to the inquiring site. This way, the site can create user accounts without having to store passwords. Instead, the site ties your identity to a token that the provider verifies. You prove your identify to Facebook (with a password) and Facebook proves to the site that you are who you claim to be.

    If a site allows you to migrate an existing account from a password-based authentication scheme to an OAuth-based one, make the switch. Otherwise, keep this option in mind whenever you create an account in the future.

    But there’s a catch. A few, actually. OAuth shifts a site’s security burden from password management to token management and correct protocol implementation. It also introduces privacy considerations related to centralizing auth to a provider as well as how much providers share data.

    Be wary about how sites mix authentication and authorization. Too many sites ask for access to your data in exchange for using something like Facebook Connect. Under OAuth, the site can assume your identity to the degree you’ve authorized, from reading your list of friends to posting status updates on your behalf.

    Grant the minimum permissions whenever a site requests access (i.e. authorization) to your data. Weigh this decision against your desired level of privacy and security. For example, a site or mobile app might insist on access to your full contacts list or the ability to send Tweets. If this is too much for you, then forego OAuth and set up a password-based account.

    (The complexity of OAuth has many implications for users and site developers. We’ll return to this topic in future articles.)

    Two-Factor Auth — One Equation in Two Unknowns

    Many sites now support two-factor auth for supplementing your password with a temporary passcode. Use it. This means that access to your account is contingent on both knowing a shared secret (the password you’ve given the site) and being able to generate a temporary code.

    Your password should be known only to you because that’s how you prove your identity. Anyone who knows that password — whether it’s been shared or stolen — can use it to assume your identity within that account.

    A second factor is intended to be a stronger proof of your identity by tying it to something more unique to you, such as a smartphone. For example, a site may send a temporary passcode via text message or rely on a dedicated app to generate one. (Such an app must already have been synchronized with the site; it’s another example of a shared secret.) In either case, you’re proving that you have access to the smartphone tied to the account. Ideally, no one else is able to receive those text messages or generate the same sequence of passcodes.

    The limited lifespan of a passcode is intended to reduce the window of opportunity for brute force attacks. Imagine an attacker knows the account’s static password. There’s nothing to prevent them from guessing a six-digit passcode. However, they only have a few minutes to guess one correct value out of a million. When the passcode changes, the attacker has to throw away all previous guesses and start the brute force anew.

    The two factor auth concept is typically summarized as the combination of “something you know” with “something you possess”. It really boils down to combining “something easy to share” with “something hard to share”.

    Beware Password Recovery — It's Like Shouting Secret in a Crowded Theater

    If you’ve forgotten your password, use the site’s password reset mechanism. And cross your fingers that the account recovery process is secure. If an attacker can successfully exploit this mechanism, then it doesn’t matter how well-chosen your password was (or possibly even if you’re relying on two-factor auth).

    If the site emails you your original password, then the site is insecure and its developers are incompetent. It implies the password has not even been hashed.

    If the site relies on security questions, consider creating unique answers for each site. This means you’ll have to remember dozens of question/response pairs. Make sure to encrypt this list with something like the OS X Keychain.

    Review Your OAuth Grants

    For sites you use as OAuth providers (like Facebook, Twitter, Linkedin, Google+, etc.), review the third-party apps to which you’ve granted access. You should recognize the sites that you’ve just gone through a password refresh for. Delete all the others.

    Where possible, reduce permissions to a minimum. You’re relying on this for authentication, not information leakage.

    Use HTTPS

    Universal adoption of HTTPS remains elusive. Fortunately, sites like Facebook and Twitter have set this by default. If the site has an option to force HTTPS, use it. After all, if you’re going to rely on these sites for OAuth, then the security of these accounts becomes paramount.

    Maintain Constant Vigilance

    Keep your browser secure. Keep your system up to date. Set a reminder to go through this all over again a year from now — if not earlier.

    Otherwise, you risk losing more than one account should your password be exposed among the millions. You are not a number, you’re a human being.

  • Soylent Grün ist Menschenfleisch Dec 27, 2013

    Silicon Valley green is made of people. This is succinctly captured in the phrase: When you don't pay for the product, the product is you. It explains how companies attain multi-billion dollar valuations despite offering their services for free. They promise revenue through the glorification of advertising.

    Investors argue that high valuations reflect a company's potential for growth. That growth comes from attracting new users. Those users in turn become targets for advertising. And sites, once bastions of clean design, become concoctions of user-generated content, ad banners, and sponsored features.

    Population Growth

    Sites measure their popularity by a single serving size: the user. Therefore, one way to interpret a company’s valuation is in its price per user. That is, how many calories can a site gain from a single serving? How many servings must it consume to become a hulking giant of the web?

    Dystopian Books

    You know where this is going.

    The movie Soylent Green presented a future where a corporation provided seemingly beneficent services to a hungry world. It wasn't the only story with themes of overpopulation and environmental catastrophe to emerge from the late '60s and early '70s. The movie was based on the novel Make Room! Make Room!, by Harry Harrison. And it had peers in John Brunner's Stand on Zanzibar (and The Sheep Look Up) and Ursula K. Le Guin's The Lathe of Heaven. These imagined worlds contained people powerful and poor. And they all had to feed.

    A Furniture Arrangement

    To sell is to feed. To feed is to buy.

    In Soylent Green, Detective Thorn (Charlton Heston) visits an apartment to investigate the murder of a corporation’s board member, i.e. someone rich. He is unsurprised to encounter a woman there and, already knowing the answer, asks if she’s "the furniture." It's trivial to decipher this insinuation about a woman's role in a world afflicted by overpopulation, famine, and disparate wealth. That an observation made in a movie forty years ago about a future ten years hence rings true today is distressing.

    We are becoming products of web sites as we become targets for ads. But we are also becoming parts of those ads. Becoming furnishings for fancy apartments in a dystopian New York.

    Women have been components of advertising for ages, selected as images relevant to manipulating a buyer no matter the irrelevance of their image to the product. That's not changing. What is changing is some sites' desire to turn all users into billboards. They want to create endorsements by you that target your friends. Your friends are as much a commodity as your information.

    In this quest to build advertising revenue, sites also distill millions of users' activity into individual recommendations of what they might want to buy or predictions of what they might be searching for.

    And what a sludge that distillation produces.

    There may be the occasional welcome discovery from a targeted ad, but there is also an unwelcome consequence of placing too much faith in algorithms. A few suggestions can become dominant viewpoints based more on others' voices than personal preferences. More data does not always mean more accurate data.

    We should not excuse an algorithm as an impartial oracle to society. They are tuned, after all. And those adjustments may reflect the bias and beliefs of the adjusters. For example, an ad campaign created for UN Women employed a simple premise: superimpose upon pictures of women a search engine’s autocomplete suggestions for phrases related to women. The result exposes biases reinforced by the louder voices of technology. More generally, a site can grow or die based on a search engine's ranking. An algorithm collects data through a lens. It's as important to know where the lens is not focused as much as where it is.

    There is a point where information for services is no longer a fair trade. Where apps collect the maximum information to offer the minimum functionality. There should be more of a push for apps that work on an Information-to-Functionality relationship of minimum requested for the maximum required.

    Going Home

    In the movie, Sol (Edward G. Robinson) talks about going Home after a long life. Throughout the movie, Home is alluded to as the ultimate, welcoming destination. It's a place of peace and respect. Home is where Sol reveals to Detective Thorn the infamous ingredient of Soylent Green.

    Web sites want to be your home on the web. You'll find them exhorting you to make their URL your browser's homepage.

    Home Page

    Web sites want your attention. They trade free services for personal information. At the very least, they want to sell your eyeballs. We've seen aggressive escalation of this in various privacy grabs, contact list pilfering, and weak apologies that "mistakes were made."

    More web sites and mobile apps are releasing features outright described as "creepy but cool" in the hope that the latter outweighs the former in a user's mind. Services need not be expected to be free without some form of compensation; the Web doesn't have to be uniformly altruistic. But there's growing suspicion that personal information and privacy are being undervalued and under-protected by sites offering those services. There should be a balance between what a site offers to users and how much information it collects about users (and how long it keeps that information).

    The Do Not Track effort fizzled, hobbled by indecision of a default setting. Browser makers have long encouraged default settings that favor stronger security, they seem to have less consensus about what default privacy settings should be.

    Third-party cookies will be devoured by progress; they are losing traction within the browser and mobile apps. Safari has long blocked them by default. Chrome has not. Mozilla has considered it. Their descendants may be cookie-less tracking mechanisms, which the web titans are already investigating. This isn't necessarily a bad thing. Done well, a tracking mechanism can be limited to an app's sandboxed perspective as opposed to full view of a device. Such a restriction can limit the correlation of a user's activity, thereby tipping the balance back towards privacy.

    If you rely on advertising to feed your company and you do not control the browser, you risk going hungry. For example, only Chrome embeds the Flash plugin. An eternally vulnerable plugin that coincidentally plays videos for a revenue-generating site.

    Lightbeam Example

    There are few means to make the browser an agent that prioritizes a user's desires over a site's. The Ghostery plugin is one tracking countermeasure available for all major browsers. Mozilla's Lightbeam experiment does not block tracking mechanisms by default; it reveals how interconnected tracking has become due to ubiquitous cookies.

    Browsers are becoming more secure, but they need a site's cooperation to protect personal information. At the very least, sites should be using HTTPS to protect traffic as it flows from browser to server. To do so is laudable yet insufficient for protecting data. And even this positive step moves slowly. Privacy on mobile devices moves perhaps even more slowly. The recent iOS 7 finally forbids apps from accessing a device's unique identifier, while Android struggles to offer comprehensive tools.

    The browser is Home. Apps are Home. These are places where processing takes on new connotations. This is where our data becomes their food.

    Soylent Green's year 2022 approaches. Humanity must know.

1 ... 15 16 17 18 19 ... 30

Dangerous Errors

  • zombie
  • mutantzombie
  • mutantzombie.bsky.app
  • SecurityWeekly

Cybersecurity and more | © Mike Shema