• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mozilla-services / cliquet / 2726 / 3
100%
master: %

Build:
Build:
LAST BUILD BRANCH: 186-215-add-sqlachemy-pooling
DEFAULT BRANCH: master
Ran 18 Nov 2015 12:14PM UTC
Files 79
Run time 8s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

18 Nov 2015 11:57AM UTC coverage: 99.654%. First build
TOX_ENV=pypy

push

travis-ci

leplatrem
Load plugins after setting up authn/authz

While developing kinto-attachment, we realized that if plugins were included
before setting-up authn/authz, their views could not be protected by permissions.

For example, when a plugin defines a plugin like this in a view:

```python

    upload = Service(name="upload",
                     path="/upload",
                     description="",
                     factory=RouteFactory)
    @upload.get(permission="upload")
    def upload_get(request):
        return {"ok": True}

```

The factory is taken into account, but the authorization policy was never
called!

With this change, the plugins are included after ``cliquet.initialization.setup_authentication()``. Thus after ``config.include("pyramid_multiauth")`` thus after setting
up the authorization policy from setting ``multiauth.authorization_policy``.

The side-effet of this is that plugins cannot set default settings regarding auth.
It was the case of *cliquet-fxa* which defines an implicit setting ``multiauth.policy.fxa.use`` that allowed to just to specify ``fxa`` in the ``multiauth.policies`` setting.

The setting ``multiauth.policy.fxa.use`` must now be defined explicitly.

8059 of 8087 relevant lines covered (99.65%)

1.0 hits per line

Source Files on job 2726.3 (TOX_ENV=pypy)
  • Tree
  • List 0
  • Changed 0
  • Source Changed 0
  • Coverage Changed 0
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 2726
  • Travis Job 2726.3
  • 4dc068b0 on github
  • Next Job for TOX_ENV=pypy on order-include-plugins (#2727.3)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc