mozregression

Kudos to k0s and sinemetu1, the current maintainers of mozregression, an idiot-proof script for helping you find the regression range for a bug. Give it two dates, and it automatically downloads and runs a nightly and, when you exit, asks you whether the bug is present or not and downloads another build accordingly, until you have a 24 hour window identified. And then it says “do you want to compile some code to narrow it down even more?”. Awesome.

(More regression-hunting tools.)

Web Standards Project Shuts; Not Paying Attention?

The WaSP has closed its doors, with a post titled “Our Work Here Is Done“:

Tim Berners-Lee’s vision of the web as an open, accessible, and universal community is largely the reality.

If by the web you mean “the desktop web”, then things are undeniably much better than they used to be. But what about the mobile web? Opera just shifted to WebKit precisely because the vision of Tim and the Web Standards Project is not a reality. Did they notice that happening?

They later go on to almost say the opposite:

The job’s not over, but instead of being the work of a small activist group, it’s a job for tens of thousands of developers who care about ensuring that the web remains a free, open, interoperable, and accessible competitor to native apps and closed eco-systems.

When was it not, in the end, up to developers? It’s always been up to the developers, and it was the case that the WaSP helped them. Seemingly no more.

I also saw this news on the same day that Lawrence Mandel posted a call for help with the numerous problems we are having due to people coding mobile websites which assume “Android”. That needs to change, and you can help. Is Mozilla now the flag bearer for web standards? Former WaSPers, join us and help out :-)

First Boot2Gecko White Label

This, I would suggest, is a sign of success. Firstly, it’s more people (to add to the 22 major companies on stage at MWC) who think our OS is good enough to compete and ship. Secondly, they are doing it without abusing our trademarks. Third, this is what open source is all about. We hope they’ll come and join our community and help make the code better. (And we need to work to make sure that’s easy for them to do.)

I note their screenshots are pretty hacked together, though; has no-one told them Boot2Gecko doesn’t use a hardware Back button or Search button? :-)

(Thanks to nukeador for the link.)

Understanding Mozilla: Communications

I’m running with my “Understanding Mozilla” idea – 5-minute shorts to explain things about the Mozilla project to new or existing participants.

Things at Mozilla change a lot; therefore, altering the presentation to fix bugs or incorporate new material should be easy. Therefore, it makes a lot more sense to use a “voiceover plus” approach, and to build it using Popcorn rather than as a compiled video that has to be re-edited in heavy duty video-editing software each time.

So, each short will be:

  • 5 minutes max
  • Scripted voiceover combined with stills, video and/or overlaid text
  • Script written collaboratively in wiki
  • Constructed using popcorn.js and Popcorn Maker
  • Easily remixable and rebuildable if things change

Here’s a draft script for the first one, on the subject of “Communications”. I expect that as I go through this process I’ll also be able to provide good feedback to the Popcorn team, which is all to the good.

Comments welcome, as are suggestions for future topics.

An Introduction to Modern Open Source Licence Patent Clauses

I bet that title sent shivers of pure pleasure up and down your spine, didn’t it? :-) This post explains why all modern open source licences have patent clauses, what they do (and don’t do), and why you should use and recommend licences which contain them. This question is relevant to discussions of licence choice.

I am not a lawyer, although I do sometimes play one in real life. If in doubt, consult the real deal.

This analysis will focus on the 3 most popular modern licences with patent clauses – the Apache License 2.0 (“APL”), the Mozilla Public License 2.0 (“MPL”), and the GNU General Public License 3.0 (“GPL”).

What Do They Do?

The APL (section 3) and the MPL (section 2.1, 1.11, 1.2, 1.3) say that if you make a contribution to the code, you have to grant all users a licence to any patent you hold which is infringed by your contribution, or by the whole thing as a result of adding your contribution. In the case of the GPL (Section 11, para 2), you have to grant a licence to any patent you hold which is infringed by any part of the modified work, at the time you contributed to it, whether you wrote or changed that part or not. So the GPL’s grant is wider in scope than the other two.

The above affects contributors. There are also clauses which relate to users. In the case of the MPL (section 5.2) and the GPL (section 10, para 3), you lose your right to use the software at all if you launch a patent suit against someone else regarding that software. In the case of the APL (section 3), you lose any patent licences you might have got to the code (which may be none), but you don’t lose your copyright rights.

What Don’t They Do?

In the case of the APL and MPL, they don’t make a contributor grant a licence to patents which the code already implemented before they came along, or which someone else made the code implement while they were contributing. In all cases, if the code is changed in the future by someone else to implement a patent, the licences don’t make the contributor grant a licence to that patent. (I.e. if BigCorp has a patent on the Bar algorithm, and they contribute some non-Bar-related code to project Foo, you can’t get a free license to the Bar patent by changing Foo to implement it.) And they don’t protect you at all from the patents of people who are neither contributors nor users, including patent trolls.

Why Are They Good?

  • They provide some protection to stop one member of the community suing another one. This particularly applies to the MPL and GPL, which rescind all rights (including copyright rights) to the code when a suit is filed, thereby giving the small, patentless guy some power when this happens.
  • Relatedly, they make big companies much more comfortable about collaborating on a codebase together. Without a patent licence, the first big company you recruit to work on your code will scare off any additional ones, because they are concerned about the first company’s patents.
  • If your code is widely-enough used, it provides some protection from third parties who would not want to lose their rights to use it.

Patent clauses do not solve the software patent problem. But they do mitigate it and, in the presence of the problem, they do help build collaborating communities. That is why all modern open source licences have a patent clause, and why you should only use and promote licences which have them, and encourage others to do the same.

Relicensing: When Do You Have To Ask?

When an open source project or codebase is considering a move from one licence to another, one question which may affect whether they go ahead or not is whether they have to track down and ask permission of all the contributors. (Another question is how many people will be upset by the change; that is out of scope here. This post is about what is possible, not about what is wise.)

By “relicensing”, I mean “make it so that the code can only be used by following the terms of the new licence”. This is distinct from dual-licensing, where the code can be used under either set of terms. For example, jQuery is dual-licensed MIT/GPL, and so it can be used and redistributed under MIT, or GPL, or both.

When you relicense, you may have to continue following the terms of the old license as well, or you may not – it depends on the exact licences concerned. If a project moves from the MIT licence to the GPL licence, users would need to obey both sets of terms – although the MIT requirements are a tiny subset of the GPL ones; the only relevant term in the MIT licence is “preserve this notice”. By contrast, if a project moves from LGPL 2.1 to GPL, as permitted by LGPL section 3, then you delete the LGPL boilerplate and replace it with the GPL one, and only GPL terms apply from then on.

So when do you have to ask in order to relicense? You don’t have to ask if:

  • The project has formally aggregated copyright (e.g. each contributor has signed a CLA), and the aggregate copyright holder agrees; or
  • The move is to a later version of the same licence, and either the license allows that (e.g. the MPL), or the license boilerplate on the files permits it (e.g. the standard GPL boilerplate); or
  • The move is to a “compatible” license.

The last bullet is a tricky one; what makes two licenses, A and B, compatible? “Compatible” is a word used with regard to licences in a number of senses. Here, I mean that it’s possible to migrate from users/distributors being required to obey License A to users/distributors being required to obey License B (and possibly A as well; see above). The first thing to note is that compatibility of this sort is not symmetric – A → B does not imply B → A. To be certain in any case requires an analysis of the two texts, but in general:

  • Two permissive licenses are compatible if the terms of A are a subset of, or can be complied with at the same time as, the terms of B.
  • Permissive licenses are usually compatible with copyleft licenses, with the notable exception (according to the FSF) of Apache Public License 2.0 → GNU General Public License 2.0.
  • Two copyleft licenses are not compatible unless A has a specific provision which allows relicensing under B.
  • Copyleft licenses are never compatible with permissive licenses (that would destroy the copyleft).

Being specific, the following compatibility diagram, while incomplete, may help with the most common open source licenses. “+” means “or later” where such a clause is optional.

MIT/BSD → Apache 2.0 → MPL 2.0 → LGPL 2.1+ → GPL 2.0+
                                      ↓         ↓
                                 LGPL 3.0+ → GPL 3.0+ → AGPL 3.0+

This diagram is meant as a guide only, and does not cover some particular twists; for example, it does not reflect the Apache 2.0/GPL 2.0 incompatibility, and you can only relicense from the MPL to a GPL license if you combine with existing GPLed code and dual-license the MPLed part. But it gives the general idea.

A separate question is: what boilerplate headers do I put on the relicensed files? A big part of that question is whether you end up having to obey both licences or just the new one, and that depends on the two licences concerned. So this question is complicated enough that it’s best to ask for advice for any specific case. (But implementing the answer is probably a lot easier than chasing down hundreds of contributors!)

Join the Organ Donor Register

A friend who will soon need a double lung transplant (due to a genetic illness) tells me:

96% of people believe donating organs is the right thing to do but only 30% have joined the NHS Organ Donor Register. 1 in 2 people die on the double-lung waiting list.

Please take a few minutes to sign up. If you are in the UK, see here. If not, do a web search for the register in your country. (Sadly, they won’t take my organs, but they will probably take yours.)

No One Considered…

Micire’s talk was an excellent example of what can happen when a device maker doesn’t lock down its device. It seems likely that no one at Google or Samsung considered the possibility of the Nexus S being used to control space robots when they built that phone. But because they didn’t lock it down, someone else did consider it—and then went out and actually made it happen.

— LWN (an awesome publication; do subscribe)

“Understanding Mozilla” Videos

In conversation in the Mountain View office last week, I pondered that it would be very useful to make some 5-minute short videos explaining bits of Mozilla to new community members. They would be slides-and-voiceover, so they could be easily edited and patched, and would be based on pre-written scripts for maximum content in minimum length.

My name for the project was “Understanding Mozilla”. So you would have “Understanding Mozilla: Communications”, “Understanding Mozilla: Development”, “Understanding Mozilla: Documentation” and so on. They might be good for the onboarding process, but would be useful standalone.

It’s clear that great minds think alike, because the very next day, there was an announcement that someone else is already doing it under the name “Viki”.

Awesome :-)

Don’t Use Non-Open-Source Code In Mozilla

tl;dr: Don’t use third party code which isn’t clearly marked as open source in Mozilla projects, even if the developer says you can. This includes HighCharts. Consult the licensing team if in doubt.

Mozilla is an open source organization. Our manifesto says that “free and open source software promotes the development of the Internet as a public resource.” I hope never to see the day when we decide as an organization to ship non-open-source software; if we ever did, that decision would have to come from the very top.

However, it turns out that sometimes we accidentally do ship or require stuff with a non-open-source licence. So I thought it might be helpful to clarify some common situations. In particular, Mozilla developers should not use:

  • Code put up on Github (or anywhere else) without an explicit licence
  • Code which is is only available for non-commercial use (e.g. CC-BY-NC)
  • Code which you can’t make derivatives of (e.g. CC-BY-ND)
  • Code whose developer says “sure, it’s not open source, but it’s OK for you to use it”
  • Non-open-source code which lives elsewhere on the web and is pulled in by URL (e.g. a JS library)

One non-commercial-use-only library (HighCharts) made it into one Mozilla website (with permission of the developer) and, despite a bug being filed to remove it, it hasn’t been removed and has in fact been used in at least one more major Mozilla web property – and it could have been even more if I hadn’t noticed someone else saying they were planning to use it. Hence this blog post, to try and make sure it doesn’t spread any further. There are alternatives – Rickshaw has been suggested. It’s a lot of hassle to remove working code once it’s integrated and deployed, and the best way to avoid that hassle is not to use such a library in the first place.

There’s lots of code in the world which we can’t use due to its licence. The fact that you have a copy of that code on your hard drive doesn’t make it any more usable. :-)

European Cybersecurity Strategy and Proposed Network Security Directive

The European Commission recently published 2 documents:

* the Cybersecurity Strategy of the European Union (English version; 20 pages)
* the Proposed Directive on Network and Information Security (English version; 27 pages + 2 annexes)

Mozilla is trying to work out whether we need to have a position on these documents and, if so, what that position should be. How might this affect the open web? Are there any actions we could or should take in response?

This is part of the work of the new Public Policy module. Particularly if you live in the EU, we would appreciate it if you would read one or the other and indicate any parts of it which are particularly of interest to you and to Mozilla.

The first document, the Strategy, sets forth the EU’s vision of cybersecurity. The second one, the proposed NIS Directive, if enacted, would require all Member States, and key “Internet enablers” such as e-commerce platforms, social networks, plus critical infrastructure companies (energy, transport, banking, and healthcare) to take action to ensure “a secure and trustworthy digital environment throughout the EU”. This might mean, for example, requiring them to adopt risk management practices and report major security incidents on their core services.

(I would expect these documents to be available in other EU languages but, although the press release is, I can’t see where the documents are. Pointers gratefully received.)

Summer of Code 2013

Summer of Code[0] 2013 is on! The Mozilla Project is hoping to be involved again, so in the next five weeks we need to produce a list of suitable projects to support our application.

Can you think of an 8-week task you might be able to guide a student through? It doesn’t matter where in Mozilla you contribute. We are collecting project ideas for every part of the project – Firefox, Firefox OS, Thunderbird, SeaMonkey, Bugzilla, L10n, NSS, IT, Documentation and many more.

If you have an idea, put it on the Brainstorming page, which is our idea development scratchpad. Please read the instructions at the top – following them vastly increases your chances of your idea getting added to the formal Ideas page.

[0] For those who are not familiar with it, Summer of Code is where Google pays students to work on free software projects – as long as those projects can provide support and a mentor for the particular task the student is undertaking. This is a great opportunity for us as a project to introduce new people to Mozilla, and for you as an individual to get new people involved in your team :-) In the past, it has been the source of major features of our flagship products. For example, the 3D web page debugging tool Tilt started life as a SoC project.

Norton Making Firefox Crash

My stepfather recently sent me an email:

Firefox keeps crashing and I keep receiving an apology and having to restore things. I switched off my computer and downloaded a new Firefox file but things are still the same.

I asked him for 10 crash signatures from about:crashes (sidenote: why does the “copy raw data to clipboard” button on about:support not also copy data about the last 10 crashes?) and found that the crash was in a DLL belonging to Norton Confidential. Symantec say they should have a fix by the end of the month. (Incidentally, Socorro is awesome.) Although I don’t know what their update uptake rate is.

There are loads of reports in SUMO about this. Scoobidiver says that this issue alone accounts for 8% of all Firefox 18 crashes. Every time this happens, I wonder how many people, who do not have Mozilla employees in their family to email, simply give up on Firefox because “it keeps crashing”, not knowing that a) it’s not our fault and b) there may be a fix coming in a few weeks?

Should we be even more aggressive in blocking crashy binary addons as soon as we see a crash-stats spike?

[Update: here’s his follow-up:

I have Norton 360 but if I disable it while on Firefox, does this leave me vulnerable? Would I be better using Internet Explorer and waiting for the system to be fixed?

Norton Confidential actually does password encryption (?) and phishing protection (which we already have), but people are scared to disable any of this stuff because the anti-virus companies have made them afraid.

Another comedy point: look at the titles of the top 4 Google hits for “Norton Confidential.]

Producing Open Source Software: 2nd Edition Kickstarter

Regular readers of this blog will know that over the last year I’ve been posting striking quotes from “Producing Open Source Software”, an excellent book written by Karl Fogel in 2005, published by O’Reilly, and available online.

I’ve just been informed by Devdatta that Karl is looking to update the book for a 2nd edition, which will also be available under a free license.

If you think this book contains as much wisdom as I do, head over to Kickstarter and chip in. He needs US$10,000, and currently has just under US$5,000.