Commit Graph

21 Commits

Author SHA1 Message Date
Awais Qureshi
81bab4d01a Pyupgrade in common/djangoapps/third-party-auth/tests. 2021-03-19 15:39:48 +05:00
Robert Raposa
40611bb915 ARCHBOM-1667: fix: remove authentication from auth exchange (#26618)
* Remove authentication, including SessionAuthentication, to fix CSRF
  exemption by dropping CSRF check of SessionAuthentication.
* Several changes to make it more clear that only POST is supported and
  clean up GET method testing.
* Removed the temporary 403 error logging that wasn't working.
* Removed test_single_access_token which was written for DOP, but
  doesn't work with DOT. See
  [MA-2122](https://openedx.atlassian.net/browse/MA-2122) for a ticket
  about implementing this for DOT, although it doesn't seem to be a
  priority. NOTE: A comment was added to the ticket explaining that this
  test was removed.
* GET now returns default error for methods not allowed.

ARCHBOM-1667
2021-02-23 10:57:11 -05:00
Jawayria
7be5a683aa Applied pylint-amnesty to third_party_auth 2021-02-03 13:37:05 +05:00
Kyle McCormick
151bd13666 Use full names for common.djangoapps imports; warn when using old style (#25477)
* Generate common/djangoapps import shims for LMS
* Generate common/djangoapps import shims for Studio
* Stop appending project root to sys.path
* Stop appending common/djangoapps to sys.path
* Import from common.djangoapps.course_action_state instead of course_action_state
* Import from common.djangoapps.course_modes instead of course_modes
* Import from common.djangoapps.database_fixups instead of database_fixups
* Import from common.djangoapps.edxmako instead of edxmako
* Import from common.djangoapps.entitlements instead of entitlements
* Import from common.djangoapps.pipline_mako instead of pipeline_mako
* Import from common.djangoapps.static_replace instead of static_replace
* Import from common.djangoapps.student instead of student
* Import from common.djangoapps.terrain instead of terrain
* Import from common.djangoapps.third_party_auth instead of third_party_auth
* Import from common.djangoapps.track instead of track
* Import from common.djangoapps.util instead of util
* Import from common.djangoapps.xblock_django instead of xblock_django
* Add empty common/djangoapps/__init__.py to fix pytest collection
* Fix pylint formatting violations
* Exclude import_shims/ directory tree from linting
2020-11-10 07:02:01 -05:00
Talia
7100316f19 updating all the third_party_auth tests! 2020-09-30 16:35:36 -04:00
Manjinder Singh
953b0e728b Remove ThirdPartyAuthProviderApiPermission (#23195)
* Remove ThirdPartyAuthProviderApiPermission

Also removed ProviderApiPermissions and ApiPermissionsAdminForm and removal of DOP for third_party_auth

* Removing model

* Replaced long_token with default_token_generator

* Adding skip to test_migrations_are_in_sync
2020-02-27 15:42:09 -05:00
Feanil Patel
9cf2f9f298 Run 2to3 -f future . -w
This will remove imports from __future__ that are no longer needed.

https://docs.python.org/3.5/library/2to3.html#2to3fixer-future
2019-12-30 10:35:30 -05:00
Zainab Amir
7eb21f4dec Change version of social-auth-app-django (#21956)
Microsoft social login is not working on edx mobile app. The issue
is fixed in newer version of social-auth-app-django.

PROD-718
2019-12-12 18:07:34 +05:00
Nimisha Asthagiri
e5c258948d third_party_auth python-3 upgrade 2019-09-28 12:42:51 -04:00
aarif
ccff822a28 ran python-modernize and isort on files mentioned in INCR-396 2019-07-19 10:04:05 -04:00
Michael Youngstrom
e7898d153d Move to python3-saml 2019-01-30 16:35:16 -05:00
Saleem Latif
ec2a36b4a4 Third Party Authentication (SSO): Default values for SAML attributes 2018-10-22 11:03:01 +05:00
Uman Shahzad
8b65ca17c5 Migrate to latest, split python-social-auth.
PSA was monolothic, now split, with new features, like
a DB-backed partial pipeline. FB OAuth2 version also upped.

Partial pipelines don't get cleared except when necessary.
They persist for special cases like change of browser while
still mid-pipeline (i.e. email validation step).

Refactor, cleanup, and update of a lot of small things as well.

PLEASE NOTE the new `social_auth_partial` table.
2017-06-20 22:05:36 +05:00
Andy Armstrong
93235d118d Reorder imports using isort (except lms and cms) 2017-05-30 16:04:54 -04:00
Clinton Blackburn
4cc7628696 Upgraded to Python Social Auth 0.2.21 to resolve migration issue 2017-03-10 23:06:02 -05:00
Jesse Shapiro
ce2ab5b15c Adding 'visible' field for SSO providers 2016-09-08 11:27:09 -04:00
Calen Pennington
18e1610043 Remove the create_user argument to setUp.
Instead, use a class attribute to define test behavior. This allows for
easier addition of new mixins over time.
2016-05-04 11:35:55 -04:00
J. Cliff Dyer
1df040228a Configure LMS to select oauth2 providing library.
Available backends:

* django-oauth-toolkit (DOT)
* django-oauth2-provider (DOP)

* Use provided client ID to select backend for
  * AccessToken requests
  * third party auth-token exchange
* Create adapters to isolate library-dependent functionality
* Handle django-oauth-toolkit tokens in edX DRF authenticator class

MA-1998
MA-2000
2016-03-30 14:21:27 +00:00
Braden MacDonald
b4904adc1e Use ConfigurationModels for third_party_auth, new metadata fetching - PR 8155 2015-06-26 13:23:59 -07:00
Braden MacDonald
350f98ebde Changes for compatibility with latest python-social-auth (0.2.7) 2015-06-18 19:31:47 -07:00
Nimisha Asthagiri
dfcef9ddcb MA-95: Update Registration endpoint to support 3rd party credentials
Automatically link edX account with social account in login mobile API path
2015-03-20 15:43:40 -04:00