Commit graph

55 commits

Author SHA1 Message Date
Lukas Reschke
8222ad5157
Move logout to controller
Testable code. Yay.
2016-04-18 21:21:52 +02:00
Lukas Reschke
14f932f3c7 Add DAV authenticated also to other scopes
Fixes https://github.com/owncloud/core/issues/22893
2016-03-07 11:17:33 +01:00
Thomas Müller
8e36678873 Fix PHPDoc 2016-02-19 09:43:11 +01:00
Scrutinizer Auto-Fixer
0d0151a3e1 Scrutinizer Auto-Fixes
This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
2016-02-19 09:43:11 +01:00
Lukas Reschke
dfc3536d2b Catch auth coming from JS in OCS 2016-02-15 15:38:37 +01:00
Morris Jobke
083240482a Remove unreachable code in priavte/api.php 2016-02-14 21:12:29 +01:00
Thomas Müller
682821c71e Happy new year! 2016-01-12 15:02:18 +01:00
Lukas Reschke
c6f6a8758b Drop OC_SubAdmin and replace usages 2015-10-29 11:31:18 +01:00
Thomas Müller
cf9b8fc182 Merge pull request #18184 from owncloud/ocs-merge-headers
Merge headers of ocs results
2015-10-21 10:36:37 +02:00
Lukas Reschke
e03f0542e4 Strip directory from scriptName
`\OCP\IRequest::getScriptName` will also return the directory, so if ownCloud is installed in a subfolder such as `owncloud/` it will resolve to `/owncloud/ocs/v2.php`. This made this check fail and also made it return invalid status codes.
2015-10-12 23:39:16 +02:00
Morris Jobke
b945d71384 update licence headers via script 2015-10-05 21:15:52 +02:00
Thomas Müller
2c8eaacec7 Merge headers of ocs results 2015-09-21 11:54:46 +02:00
Thomas Müller
1d219cf799 With V2 we should ensure that the status codes are kept in sync 2015-08-13 10:45:25 +02:00
Thomas Müller
0595c05200 Adding header support to class OC_OCS_Result 2015-08-07 13:12:43 +02:00
Thomas Müller
db1416346c Following the spec:
"`statuscode`: The OCS status code of the response, everything except 100 MUST be handled as failure."
2015-08-05 17:49:44 +02:00
Thomas Müller
6c46430cdb Return 200 not null - we should return consistent types 2015-08-05 11:23:29 +02:00
Thomas Müller
649cc2fa89 Remove duplicate and unused code 2015-08-03 21:03:11 +02:00
Thomas Müller
bacf1603ff Adding ocs/v2.php with status code mapper 2015-08-03 16:05:50 +02:00
Morris Jobke
f63915d0c8 update license headers and authors 2015-06-25 14:13:49 +02:00
Joas Schilling
3f3f8c2f99 Fix usage of deprecated private constants 2015-04-18 10:30:02 +02:00
Joas Schilling
6ce1abfa5c Deprecate the OC_API constants in favor of the OCP ones 2015-04-18 09:29:52 +02:00
Jenkins for ownCloud
b585d87d9d Update license headers 2015-03-26 11:44:36 +01:00
Lukas Reschke
faddd1e256 Simplify code 2015-03-01 11:46:39 +01:00
Lukas Reschke
5c2fafa05f Read from IRequest instead of reading twice
Potentially fixes https://github.com/owncloud/core/issues/14541 and https://github.com/owncloud/core/issues/14506
2015-02-27 14:22:35 +01:00
Morris Jobke
06aef4e8b1 Revert "Updating license headers"
This reverts commit 6a1a4880f0.
2015-02-26 11:37:37 +01:00
Jenkins for ownCloud
6a1a4880f0 Updating license headers 2015-02-23 12:13:59 +01:00
Morris Jobke
6b3600d2bf Merge pull request #12918 from owncloud/use-uid-instead-of-login-name
Return UID instead of login name
2014-12-19 10:24:52 +01:00
Lukas Reschke
9031d79597 Return UID instead of login name
Without this OCS on LDAP is broken for API requests coming via Basic Authentication...
2014-12-17 20:33:22 +01:00
Lukas Reschke
a02b00445e Store result of authentication 2014-12-17 20:22:51 +01:00
Thomas Müller
320a3c3784 because OC_User::login will create a new session we shall only try to login if user and pass are set
ensure to never destroy an existing session
2014-11-26 09:19:10 +01:00
Jörn Friedrich Dreyer
5a588333b2 introduce and use getCurrentConnection() 2014-07-01 16:45:00 +02:00
Jörn Friedrich Dreyer
dd20b9f672 reset collection to 'root' after adding a route to the api 2014-07-01 14:21:20 +02:00
Vincent Petry
972fffbe02 Return 503 OCS response with requested format 2014-06-30 15:37:38 +02:00
Lukas Reschke
e88731a477 Some more PHPDoc fixes 2014-04-21 15:44:54 +02:00
Thomas Müller
756bbe8786 Merge pull request #7649 from owncloud/routing-public
Move routing classes to an interface and expose it in the public api
2014-03-17 21:07:05 +01:00
Thomas Müller
88f6dd7db1 fixing method names 2014-03-12 10:00:22 +01:00
Thomas Müller
743addd1e3 set content-type on ocs exceptions 2014-03-12 00:35:19 +01:00
Robin Appelman
26793e1f94 switch OC::getRouter usages to OC::$server->getRouter 2014-03-10 14:06:47 +01:00
Thomas Müller
25f523680a fixing ident 2014-03-07 20:06:06 +01:00
Thomas Müller
0d90b90d94 we first shall check if the current session is valid - otherwise the session-id will be regenerated on login via basic auth 2014-03-07 20:00:34 +01:00
Jörn Friedrich Dreyer
2a6a9a8cef polish documentation based on scrutinizer patches 2014-02-06 17:02:21 +01:00
Bjoern Schiessle
6845860470 keep response message 2014-01-13 12:27:05 +01:00
tomneedham
1449437c9e Merge multiple failed third party responses when returning the result 2013-11-14 01:21:54 +00:00
tomneedham
bb182bbfb2 Merge multiple shipped failures before responding. 2013-11-14 01:19:46 +00:00
tomneedham
ca5c39a3a1 Return failed shipped responses over succedded shipped responses 2013-11-14 01:14:37 +00:00
tomneedham
a39f3fdbf9 Return result object when only one successful response is returned 2013-11-14 01:10:56 +00:00
tomneedham
790055571d Update lib/private/api.php after merge conflict 2013-11-14 01:00:14 +00:00
tomneedham
b06682b7fb Merge branch 'ocs_api_fix_success_code' into oc_api_tests 2013-11-14 00:41:04 +00:00
tomneedham
f19caeed33 Remove OC_App dependancy from OC_API::mergeResponses() 2013-11-13 22:46:24 +00:00
Tom Needham
17e45e2002 Pick any none 100 status code before defaulting to 100 2013-11-13 00:45:49 +00:00