Be compatible with very old 0.7 repositories on GAE
Fix generic protection handling for GAE