Adding middleware required for bug 838251.

@adrian r?

Note: this has to be merged into master before part 2 of this bug can be landed in socorro-crashstats.