Commit graph

24 commits

Author SHA1 Message Date
Joseph Schorr
306e79e493 Move trigger tests into pytest
Note that we split the tests between endpoints/building and buildtrigger
2018-07-19 11:10:19 -04:00
Joseph Schorr
d32efc4e17 Move anon checked test to pytest 2018-07-12 15:24:49 +03:00
Joseph Schorr
924dda296f Fully migrate API security tests into the pytest test suite
Also adds an additional test that ensures that at least one security test exists for every (api endpoint, http method) pair.
2018-07-08 18:33:21 +03:00
Joseph Schorr
c35eec0615 Add ability for triggers to be disabled
Will be used in the followup commit to automatically disable broken triggers
2018-03-01 16:49:28 -05:00
Joseph Schorr
9a452ace11 Add configurable limits for number of builds allowed under a namespace
We also support that limit being increased automatically once a successful billing charge has gone through
2018-02-20 16:54:22 -05:00
Joseph Schorr
188ea98441 Add new decorator to prevent reflected text attacks
Instead of disabling repo names with periods in them, we simply disallow calls to the API when they are GET requests, whose path ends in a dot, and that do not have a referrer from the frontend.
2018-02-20 11:33:45 -05:00
Joseph Schorr
9e16a989f5 Audit the number of SQL queries we make in writing manifests, and significantly reduce in the common case
Instead of 41 queries now for the simple manifest, we are down to 14.

The biggest changes:
  - Only synthesize the V1 image rows if we haven't already found them in the database
  - Thread the repository object through to the other model method calls, and use it instead of loading again and again
2018-01-25 11:10:43 -05:00
Joseph Schorr
ce56031846 Move notifications into its own package 2017-07-25 17:00:06 -04:00
josephschorr
074b4e4981 Merge pull request #2810 from coreos-inc/joseph.schorr/QUAY-747/common-data-interface
Convert endpoints/common into using a data interface
2017-07-24 15:59:13 -04:00
Joseph Schorr
8a96647d6e Add feature flag to enable team syncing setup when not a superuser 2017-07-21 11:06:21 -04:00
Joseph Schorr
f976ffbdc7 Change endpoints/common to use a data interface 2017-07-20 16:01:39 -04:00
Joseph Schorr
aecec02b6c Change common_login to take in a user uuid, instead of a user DB object 2017-07-20 16:01:39 -04:00
Joseph Schorr
7736de24fe Add common_login test 2017-07-20 16:01:39 -04:00
Joseph Schorr
bf3e941d7f Fix notification system to use the new tuple correctly 2017-07-13 22:43:26 +03:00
Joseph Schorr
b6f1782642 Change notificationworker to use a data interface 2017-07-12 17:40:45 +03:00
Joseph Schorr
8ac20edfb2 Move verbs security tests into pytest style 2017-06-28 12:48:02 +03:00
Joseph Schorr
2f018046ec Move conduct_call into a common test lib for all endpoints 2017-06-28 11:38:36 +03:00
Joseph Schorr
7debd44b54 Switch fixture imports to wildcard in prep for full db test fixes 2017-04-24 16:45:14 -04:00
Joseph Schorr
abf179eb09 Move fixtures under test, since they are shared globally 2017-03-23 15:42:45 -04:00
Joseph Schorr
3813d0d23d Add tests for all notification event calls 2017-03-10 11:26:12 -05:00
Joseph Schorr
198bdf88bc Move OAuth login into its own endpoints module 2017-02-16 16:27:54 -05:00
Joseph Schorr
d47696b69c Add support for sub binding field 2017-02-16 16:27:53 -05:00
Joseph Schorr
7b386e9d63 Move endpoint test fixtures to a non-conftest file 2017-02-16 16:27:53 -05:00
Joseph Schorr
2c35383724 Allow OAuth and OIDC login engines to bind to fields in internal auth
This feature is subtle but very important: Currently, when a user logs in via an "external" auth system (such as Github), they are either logged into an existing bound account or a new account is created for them in the database. While this normally works jut fine, it hits a roadblock when the *internal* auth system configured is not the database, but instead something like LDAP. In that case, *most* Enterprise customers will prefer that logging in via external auth (like OIDC) will also *automatically* bind the newly created account to the backing *internal* auth account. For example, login via PingFederate OIDC (backed by LDAP) should also bind the new QE account to the associated LDAP account, via either username or email. This change allows for this binding field to be specified, and thereafter will perform the proper lookups and bindings.
2017-02-16 16:27:53 -05:00