My 2012 San Francisco ballot

On Tuesday, I’ll be voting in person for the first time in my native California. I’ve only ever voted by mail before. (I voted from Berlin in the 2008 presidential election, and had a charming exchange in broken German with the women working at the post office. They, like nearly all of Germany, were following the election as big Obama fans, so I had little trouble convincing them of the significance of the letter I was handing off.)

I’m taking more care this year to get informed on each of the ballot initiatives for California and San Francisco, and to make good decisions on them. I’ve read most of the information in the official packet on these choices, and also consulted the ACLU Northern California recommendations, the SF Gate endorsements, the SF Bay Guardian endorsements, this column from Kevin Drum at Mother Jones, and a few others.

Here’s where I stand for now; I’m putting this up here as much as a record for me as for anybody else, but they’re subject to change before election day. If you think I’m making a terrible mistake, let me know.

  • Yes on Prop 30 — both 30 and 38 address spending on education and prevent a $5 billion cut to public schools, but 30 is the better proposal.
  • No on Prop 31 — from most accounts, a ballot initiative is the wrong place to make this sort of budget policy.
  • No on Prop 32 — this is one of those zombie initiatives that keep coming back, and would weaken the political power of unions in favor of corporations.
  • No on Prop 33 — I haven’t seen any good evidence this would help anybody but the insurance company whose CEO has pushed it onto the ballot.
  • Yes on Prop 34 — repeals the death penalty in CA. This one’s a very easy call for me to make: even if you’re a supporter of the death penalty in general, which I’m not, it certainly isn’t working in California.
  • No on Prop 35 — this one’s ostensibly about sex trafficking, but overreaches in a lot of places. EFF urges opposition, too.
  • Yes on Prop 36 — three strikes doesn’t work, and causes incredible damage in California. This initiative helps restore some of the original intent of the law.
  • Yes on Prop 37 — a bit of a tough call, as consensus seems to be that a ballot initiative is not exactly the right way to make this proposal law, and the loose language could cause problems. Mother Jones is split, too, with another writer opposing Kevin Drum’s position. But Monsanto has spent a lot of money trying to kill this, and that makes me think there must be something to it.
  • UPDATE: No on Prop 38 — originally I thought it’d be fine if both 30 and 38 passed, but I’ve read a little more about how the two would interact — namely, that the one with the larger majority gets enforced while the other one gets scrapped at worst or put in place piecemeal at best — and I’ve decided to vote against this one. I really hope 30 passes, though.
  • Yes on Prop 39 — closes a tax loophole that is not politically viable to address through the legislature. I’d rather these sorts of things weren’t addressed through ballot initiatives, but as long as it’s here…
  • Yes on Prop 40

With regard to San Francisco measures: there appears to be a bit more constraint with how these end up on the ballot. After consulting a few sources, it looks like the way to vote is yes to all except Measure F. That one, though proposed by well-meaning environmentalists, would commit the city to spending $8 million evaluating an ultimately unworkable plan to drain the Hetch Hetchy Reservoir.

Of particular interest is Measure G, which declares as City policy that corporations should not have the same constitutional rights as human beings. Although it’s not binding, and actual laws to the same effect would get very complicated very fast, I think the general principle is a nice one for the city to endorse.

HOWTO: Create an animated gif from a video with command line tools

Sometimes I see a few seconds of a video I’m watching and I think that it’d make a great animated gif. But because I don’t always have access to a bunch of graphics software, and because I might be using my Ubuntu or OS X box, it’s nice to have a process that works with widely- and freely-available free software command line tools. So I’ve worked out a process that uses the command line and requires only the programs mplayer, imagemagick, and gifsicle. Here’s how it goes:

  1. Make sure you have the programs installed. On Ubuntu (or most anything Debian-based with large enough repositories — these are common programs) it should just be a matter of

    sudo apt-get install mplayer imagemagick gifsicle

    On Mac OS X, first install the Homebrew package manager, and then install these programs with

    brew install mplayer imagemagick gifsicle

  2. Isolate the segment of video you want to clip out. You’re just looking for a timestamp, so you can do this in any video player. Once you’ve got a rough clip selected, use mplayer to export that to image files. You can use the following line to do that (there are some example values in there that I’ll explain afterward):

    mplayer -ao null -ss 0:02:06 -endpos 5 -vo gif89a:outdir=gif videofile.mp4

    Here’s what each flag means.

    • -ao means audio output. It’s set to null, because there’s no sound.
    • -ss is the start position. What follows is the H:MM:SS timestamp of the beginning of the clip you want.
    • -endpos is the end position of the clip, in seconds. So here I’ve taken out a 5 second clip.
    • -vo is the video output. The next bit says to output gifs (that’s gif89a into the directory called “gif”. You can put them into whatever directory you want of course.

      For some reason the I don’t have the gif89a video output driver installed on my OS X computer, so I instead use png or jpeg in the place of gif89a up there. Your mileage may vary.

  3. You now should have a directory full of stills. In case you used any other format to output them, I use one line of imagemagick’s mogrify to convert them:

    mogrify -format gif *.png

  4. Then go through and remove the images at the start and the end that you don’t want in the final gif. Sometimes I cheat on the command line here, and just look at all the pictures with Preview or Image Viewer and delete the ones I don’t need.
  5. Finally, use gifsicle to wrap it all up into an animated gif. I usually start with the line

    gifsicle --colors=256 --delay=4 --loopcount=0 --dither -O3 *.gif > animation.gif

    and then tweak the parameters from there. Different source material calls for different settings, and I try to keep the final output as small as possible.

If you make a lot of gifs and like to mess with a lot of values, it might make sense for you to do it graphically. But this flow works pretty well for me.

100 years of cinematic copyright

I know this is a wonky thing, but I was reading the Library of Congress blog this week when I saw an article about the centennial of copyright for film works. Prior to that date, film was not on the list of classes of work that were eligible. Filmmakers would instead send in collections of stills from the film, because photographs had already been eligible since 1865, like this series from 1894 of a man named Fred Ott sneezing in an Edison Kinetoscope movie. By the way, I love that this is what movies used to be.

It’s telling — if not surprising — that film studios lobbied at the time for a limit on the statutory damages that could be issued against them for unintentional copying. From the post:

At the urging of the movie industry, the amendment also limited statutory damages that could be awarded against movie studios for innocent infringement of nondramatic works.

How things change. Today’s movie industry, of course, has been one of the largest institutional supporters of insane levels of statutory damages, even filing a brief in support of the RIAA and a $1.92 million fine against a p2p song downloader.

The tragedy, of course, is that the content industry’s addiction to expanding copyright scope has caused it to discard its own history. And that’s our cultural history, too. In William Patry’s latest book, “How to Fix Copyright,” he goes into the sad history of film archiving: Hollywood doesn’t even own copies of many of the films it has produced, and the distended term length has made it difficult to be certain of the legality of preservation efforts by archives and the like. The Library of Congress initially refused to collect samples, because the film was printed on highly flammable nitrate film, but now holds copies of some 200,000 movies. But there is also difficult-to-find and rare footage spread across 1,750 archives.

The failure to archive is real and frustrating. The article refers to one of the first films that was submitted for copyright protection, another of Edison’s films called “The Charge of the Light Brigade.” (Another non-surprise: it’s based on an earlier poem by Alfred, Lord Tennyson, and inspired a 1968 film by the same name.) It was apparently issued as an extra on the Region 2 DVD release of that 1968 film, but I can’t find it online.

Square’s security anti-patterns

Square dongles really truly make processing credit cards not just easier, but possible for all sorts of groups that didn’t have access before: I’ve bought from bands selling merchandise, taxi drivers, food cart operators, and more. I’m worried, though, that Square also makes credit card fraud easier by teaching credit card users security anti-patterns.

In practice, using a Square reader is pretty similar to using any other credit card reader. At the money part of the transaction, you hand your card to the vendor or swipe it yourself through a little dongle hooked up to the headphone jack of an iOS or Android device. Then you enter your email, if you want a receipt sent to you, and sign with your finger on the screen.

That’s the standard description. But it could also be described as handing your credit card to a stranger with a skimmer, and then giving him your signature. That’s what makes it an anti-pattern: it has become commonly used, but is counter-productive to security efforts.

In the overwhelming majority of cases, both parties are honest, and nothing goes wrong. But it’s easy to imagine a few ways it could go wrong. For one thing, if the vendor is dishonest, he could intentionally record the data and use it or sell it later. That’s how a standard skimmer works, and the same problem exists every time you hand your card to the waiter at a restaurant.

Even if both parties are honest though, they are trusting the integrity of the software. I haven’t heard of it yet, but again it’s not too hard to imagine malware that attacks exploits in, say, Android or iOS themselves, and surreptitiously records and sends the card data to the attacker. Such malware could target a wide swath of devices and transactions, and would be more difficult to pinpoint as the source of the data leak.

Unlike the first scenario, this one is exacerbated in the Square era. Previously, malware targeting point-of-sale devices had to be very specialized. Now, though, point-of-sale devices are general purpose computers and vulnerable to commonly known exploits. And in many scenarios, they’re used for other purposes, too, exposing them to more attack vectors.

Really, though, the problem here is not with Square, but with the structure of credit card security. Our card numbers are a secret, and the only information required to carry out many transactions, but we also entrust them with every stranger we make a payment to.

We used to address this issue by an ad hoc security-by-point-of-sale system. If somebody had an official point-of-sale system, our intuition said they were trustworthy, and that was pretty robust. But it’s failing the same way that, say, security-by-letterhead has failed. Technology has made attacks we’ve dismissed as prohibitively difficult much easier, and we need to change our behavior to reflect that.


photo: The infamous Square card reader. used under CC BY

My sceneries from the plane window

I was really struck by Maira’s “Sceneries From The Plane Window,” so I decided to shoot my own on my trip back from Portland. Her camera is better than mine, and the conditions in her plane were a bit better suited for photography, but I like the way some of these turned out.

The object in the front of the photograph is the propeller, and my arm (and bright green wrist-band) are a bit too visible in these. Most unfortunately, though, I had to put my camera away for the descent; it’s too bad, because we got an incredible aerial view of San Francisco.

We got that view flying into Oakland from the north, so if you are doing that, I can recommend a window seat on the right hand side.