Commit graph

81 commits

Author SHA1 Message Date
Aditya Hase
99f17c651c Use 'in' instead of 'has_key' 2017-09-04 16:05:58 +05:30
Rushabh Mehta
e71fb55702 Merge branch 'develop' into fix-urlencode 2017-08-11 13:01:24 +05:30
Aditya Hase
e324406c8a Import six.moves.urllib.parse.urlencode instead of urllib.urlencode 2017-08-11 00:38:26 +05:30
Aditya Hase
769338f136 Replaced all instances of basestring with six.string_types 2017-08-11 00:10:11 +05:30
Aditya Hase
375dfd601d Replaced urlparse imports with six.moves.urllib.parse (#3847) 2017-08-03 11:43:28 +05:30
Aditya Hase
9d7d384a63 Replaced urllib.quote imports with six.moves.urllib.parse.quote (#3837) 2017-08-02 17:09:16 +05:30
Aditya Hase
ec9a01e3aa Replaced 'except' clause syntax (#3827) 2017-08-02 16:58:24 +05:30
Aditya Hase
774c5fd2c6 Replaced mixed usage of tabs and spaces for indents with tabs only (#3828) 2017-08-01 11:53:58 +05:30
Rushabh Mehta
aef98daae4 [add] catch errors flake8 (#3800) 2017-07-27 11:34:44 +05:30
Manas Solanki
6d35855a7b Fix for dropbox settings (#3749) 2017-07-25 11:25:28 +05:30
Revant Nandgaonkar
0fa951f893 Oauth2 tests (#3756)
* Test for oauth2 test_authorize_guest_redirect

* fix test oauth2

* [Fix] using py requests instead of werkzeug test client

* [Fix] https://www.codacy.com/app/frappe/frappe/pullRequest?prid=788942

* Test OAuth 2 Authorization Code Bearer Token flow

* [Fix] https://www.codacy.com/app/frappe/frappe/pullRequest?prid=788942
2017-07-24 11:25:05 +05:30
Saurabh
88c8df2350 [minor][fix] check for oauth1 access_key and access_secret before generating dropbox's oauth2 token (#3593) 2017-07-03 12:30:34 +05:30
Saurabh
ee13f1bc93 [fix] bypass setup_dropbox page via rest api 2017-06-20 18:39:47 +05:30
Saurabh
ec16d11ae6 generate oauth2 access token from oauth1 access token 2017-06-20 18:39:47 +05:30
Saurabh
0c6b1c4481 [fix] fixes to oauth 2 token generation for frappe cloud users 2017-06-20 18:39:47 +05:30
Saurabh
eb2611dd83 [enhance] update dropbox backup to be compatible with Dropbox V2 api 2017-06-20 18:39:46 +05:30
Saurabh
9b8d020ace Merge branch 'master' into develop 2017-06-13 15:16:34 +05:30
almeidapaulopt
b17b73c4f3 GSuite integration (#3252)
* GSuite initial commit

* GSuite initial commit

* cleanups

* exception handle

* gsuite script: add doGet

* Add GSuite integration to the upload popup

* hide dialog fields if gsuite disabled

* move gsuite code to gsuite.js from upload.js

* documentation

* change name format

* typo on GSuite

* copy paste the file .gs

* fix:don't show gsuite when creating a file in filemanager

* add version to webapp

* add webapp default url

* move webapp to html fied

* fix rebase

* fixes for codecy
2017-06-13 14:55:07 +05:30
almeidapaulopt
374f85bfd6 several throw translations (#3441)
* several throw translations

* small fix

* codacy fixes

* fix import _

* Create file_list.js

* Create feedback.py
2017-06-13 14:32:47 +05:30
Revant Nandgaonkar
5a0eb81340 [fix] OAuth2 Frappe Server URL Validation (#3397)
* [fix] OAuth2 Frappe Server URL Validation

Only request and validate the frappe_server_url if hostname is not equal to frappe_server_hostname
request.get to localhost by using hostname results into timeout

* check domains in local.conf.domains as well

* removed unused variable as per codacy
2017-06-12 16:12:49 +05:30
rohitwaghchaure
4e2749354b [fix] Refresh the page error during configuration in dropbox (#3338) 2017-05-19 11:13:47 +05:30
tundebabzy
6fbe20caaa Except and raise statement python 3 compatible style (#3216)
* changes exception and raise statements to python 3 style

* changes except statement to python 3 style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* changes except and raise statement to python 3 compatible style

* adds six.reraise to fix python 3 style raise statements with traceback

* fixes indentation
2017-05-11 10:51:59 +05:30
Saurabh
0943b684d3 [minor][fix] check also for dropbox_setup_via_site_config while showing Take Backup Now (#3256) 2017-05-10 14:02:25 +05:30
Rushabh Mehta
c02d5e5778 [fix] proposed for https://github.com/frappe/erpnext/issues/8423 2017-04-18 11:15:25 +05:30
Saurabh
286b79bd90 Stripe payment integration (#2867)
* [fix] setting page for stripe

* checkout flow for stripe payment

* controller to handle stripe checkout and authorization
2017-04-06 17:27:23 +05:30
Saurabh
7620bb3789 Deprecate Integration Broker (#2831)
* [fix] remove razorpay from integration service

* [fix] clean-up js side integration service dependancies

* [fix] remove integration service, .py cleanup, move integration request to integration

* [fix] move oauth to integrations and deprecate integration broker

* [fix] mark services enabled and update integrations listing

* [fix] V7.1 and V7.2 integration service related pathch fixes and move payment gateway dotype to core module

* [fix] create payment gateway records if not exists

* [fix] module page for integrations

* [minor][fix] minor checks

* [fix] remove integration broker module only if not allocated to any doctype
2017-03-14 11:24:26 +05:30
Rohit Waghchaure
8a2c83918b changed user_roles to roles 2017-03-06 14:42:13 +05:30
Saurabh
f2b41d7d43 [fix] LDAP Settings and script update to be more generic #2666 (#2679) 2017-02-15 14:50:16 +05:30
Nabin Hait
1de3b597ac Merge branch 'master' into develop 2017-01-13 14:33:23 +05:30
Saurabh
76e41feac7 [minor][fix] #6875 (#2569) 2017-01-12 11:25:21 +05:30
Rushabh Mehta
042e2b09cb [design] Redesign, cleanup Login, Message pages (#2564)
* [cleanup] login, message pages

* [style] cleanups

* [cleanup]

* [cleanup] update password

* [fix] name for web form (fixes edit-profile)
2017-01-10 14:44:42 +05:30
Rushabh Mehta
d989a95472 [feature] document versioning #2469 (#2523)
* [feature] document versioning #2469

* [minor] remove on_update from WebsiteGenerator

* [fix] delete shares when deleting user

* [test] don't run delete in background if test

* [fix] test_db

* [added] Deleted Document

* [fix] added track_changes in all documents

* [fix] add to deleted only if exists

* [fix] in_install flag in deleted documents

* [minor] name will always be reset
2016-12-29 18:01:42 +05:30
Rushabh Mehta
c4296c71b1 [fix] encode filename dropbox_settings.py, frappe/erpnext#7070 2016-12-26 16:50:31 +05:30
Nabin Hait
f2bc961e1b Fixed merge conflict 2016-12-23 17:35:38 +05:30
Nabin Hait
a3cd960eed fixed version conflict 2016-12-20 11:35:28 +05:30
Rushabh Mehta
a74a9d1afe [fix] dropbox access for site_config 2016-12-19 12:59:27 +05:30
Saurabh
3952338b73 [urgent][fix] convert use_sandbox param to integer to avoid false data sandboxing (#2384) 2016-11-28 12:37:33 +05:30
Rushabh Mehta
7c8652fbf2 [docs] added some style and some fixes (#2352) 2016-11-22 10:55:32 +05:30
Nabin Hait
85c8bbab8d Merge branch 'master' into develop 2016-11-17 16:42:45 +05:30
Saurabh
4d7f1c33cf [minor][fix] typo fix 2016-11-17 12:25:41 +05:30
Saurabh
8b4a9b7394 [urgent][fix] PayPal payemnt fix 2016-11-14 20:17:41 +05:30
Saurabh
9ff094d8de [fix] paypal sandboxing to test dummy payments (#2281)
* [fix] paypal sandboxing to test dummy payments

* [fix] sandbox testing for razorpay
2016-11-10 09:58:56 +05:30
Revant Nandgaonkar
a16e6a143f OpenID Connect for Frappe (#2227)
* Add field for client_secret in Oauth Client Doctype

* openid_profile endpoint in oauth2.py

* added stub methods for OpenID Connect in RequestValidator

* [Fix] using werkzeug url_fix on uri

* added 3 oidc methods in RequestValidator

* Added Frappe Section in Social Login Keys

Add section in `Social Login Keys` for fields `Frappe Client ID` and `Frappe Client Secret` and additional field Frappe OAuth 2 Server because github, facebook and google have fixed urls, Frappe server URL can change as per the hosting domain/server/company

* [Fix] accept code id_token param for oidc

* generate id_token jwt alg HS256

* Updates to OAuth 2 and OIDC

`OAuth Authorization Code` and `OAuth Bearer Token` DocType made RO
Delete Invalid Codes and Revoked Tokens periodically
generate and send `id_token` only if scope of token is `openid`

* [Fix] Periodically delete revoked tokens

* Social Logins untested

* Enabled Frappe social login

* [Docs] OpenID Connect and Frappe social login

* [Fix] Allow multiple scopes for OAuth 2

* [Docs] Added screenshot steps to configure openid and frappe social login

* saved doctype to solve merge conflict

* [fix] re-added client_secret after resolving merge conlict

* [Fix] frappe_userid and default scope
2016-11-07 22:25:11 +05:30
Saurabh
427a97774e [path][fix] paypal integration 2016-10-31 20:20:43 +05:30
Saurabh
371d9d1f75 [minor][fix] path fixes for manual dropbox backup 2016-10-31 11:41:55 +05:30
Saurabh
6f210f9401 [fix] typo fix 2016-10-25 13:03:34 +05:30
Revant Nandgaonkar
d48b270bf5 OAuth 2 Provider for frappe (#2167)
* OAuth 2.0 Classes Added

Added oauthlib in requirement.txt
Added class WebApplicationServer for Authorization code grant and Bearer tokens.
Added class OAuthWebRequestValidator for Validating Oauth Request for Web Application

* copied code from mnt_oauth needs review

* [New] OAuth2 Doctypes and endpoints added

Integrations > OAuth Provider Settings
Integration Broker > OAuth Bearer Token
Integration Broker > OAuth Authorization Code
Integration Broker > OAuth Client
endpoints for authorize, approve, get_token, revoke_token and test_resource

* oauth2.py: renamed skipauth to skip_auth

* [Fix] Parse URL instead of storing it in settings

* [Fix] get skip_auth from OAuth Provider Settings

* Success URL format. Failure URL added. Confirmation dialog layout changed.

* Validate access token if passed during use of REST API

* OAuth Confirmation colours fixed

* Multiple Changes

Added links for OAuth under Integrations in Module list.
Updated permissions on OAuth doctypes.
Updated layout of OAuth Client doctype.

* [Docs] Integrations > How to setup OAuth

* [Docs] Integration > Using OAuth

* [Fix] get_token endpoint must to handle POST request

* [Fix] http verbs and responses for OAuth 2.0 Endpoints

* [Fix] accept oauth2 access_token from headers

* Removed unused imports from api.py
2016-10-25 10:28:32 +05:30
Saurabh
0f11170c7e [minor][fix] remove raise import error (#2186) 2016-10-24 15:29:16 +05:30
Rushabh Mehta
b8b2811aa6 [minor] 2016-10-18 14:23:06 +05:30
Rushabh Mehta
1026a48a97 [refactor] code for integration service scheduled events 2016-10-13 14:59:23 +05:30