Commit Graph

357 Commits

Author SHA1 Message Date
Piotr Mrówczyński 9fec4031b3
Adjust query/event logging code in favour of more complex owncloud/diagnostics (#27643)
* Adjust query/event logging code in favour of more complex owncloud/diagnostics
* Add descriptions to IQueryLogger and IEventLogger interfaces
2017-04-26 13:19:43 +02:00
Jörn Friedrich Dreyer fff6d6e3e8
Refactor auth methods
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-04-26 01:08:53 -03:00
Christoph Wurst d091793ceb Contacts menu
* load list of contacts from the server
* show last message of each contact

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2017-04-25 20:47:17 +02:00
Julius Härtl 7548825743
Responsive app menu
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2017-04-25 17:31:24 +02:00
Julius Haertl 68a63ad3f3
Implement scss variable injection by OC_Defaults
Signed-off-by: Julius Haertl <jus@bitgrid.net>

Add Scss variables to example theme and theming app

Signed-off-by: Julius Haertl <jus@bitgrid.net>

Use SCSSCacher to build theming css

Signed-off-by: Julius Härtl <jus@bitgrid.net>

Update theming.scss

Signed-off-by: Julius Härtl <jus@bitgrid.net>

Code cleanup

Signed-off-by: Julius Härtl <jus@bitgrid.net>

Fix tests

Signed-off-by: Julius Härtl <jus@bitgrid.net>

Inject SCSSCacher for easier testing

Signed-off-by: Julius Härtl <jus@bitgrid.net>

Fix typehint

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>

Generate absolute URLs

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>

Fix tests to always use absolute urls for theming images

Signed-off-by: Julius Härtl <jus@bitgrid.net>

MailheaderColor -> ColorPrimary

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2017-04-25 11:39:45 +02:00
Joas Schilling 3d671cc536 Merge pull request #4443 from nextcloud/cleanup-unused-imports
Remove unused use statements
2017-04-24 11:47:37 +02:00
Morris Jobke c54a59d51e
Remove unused use statements
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-04-22 19:23:31 -05:00
Morris Jobke 2b6f6dac00
Remove unused variables
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-04-22 18:20:51 -05:00
Joas Schilling 1c0bffe87f
Fix translations
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-04-18 16:40:53 -05:00
Joas Schilling bd37021587
Fix casing of same origin frame option
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-04-12 12:37:32 +02:00
Lukas Reschke afb5d45705 Merge pull request #4256 from nextcloud/theming
Move OC_Defaults to OCP\Defaults
2017-04-11 14:39:46 +02:00
Joas Schilling 9e3a3eebf9
Lowercase "data" correctly
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-04-10 11:13:46 +02:00
Morris Jobke 5b4adf66e5
Move OC_Defaults to OCP\Defaults
* currently there are two ways to access default values:
  OCP\Defaults or OC_Defaults (which is extended by
  OCA\Theming\ThemingDefaults)
* our code used a mixture of both of them, which made
  it hard to work on theme values
* this extended the public interface with the missing
  methods and uses them everywhere to only rely on the
  public interface

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-04-09 21:43:01 -05:00
Kawohl bee0a3699e
removed path to datadir
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-04-04 19:07:59 -05:00
Christoph Wurst a7cc8c86ab
Redirect to 2FA selection screen
Apps like 'rainloop' use \OCP\Util::isLoggedIn() to check whether the
current request is authenticated. Since we redirected to the index
page before, it resulted in an infinite redirection loop. This change
sets the redirection URL to the 2FA selection page, which is the only
allowed page in that authentication state.

Fixes https://github.com/nextcloud/server/issues/3702

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2017-04-03 14:31:57 +02:00
Jan-Christoph Borchardt 354a24e0aa
also rename defaultMailHeaderColor to defaultColorPrimary
Signed-off-by: Jan-Christoph Borchardt <hey@jancborchardt.net>
2017-03-29 18:23:23 +02:00
Julius Härtl 698396a927
Add fallback to getMailHeaderColor so we don't break existing themes
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2017-03-29 18:23:23 +02:00
Jan-Christoph Borchardt 9a75714c22
rename confusing getMailHeaderColor to getColorPrimary, ref #3491
Signed-off-by: Jan-Christoph Borchardt <hey@jancborchardt.net>
2017-03-29 18:23:23 +02:00
Morris Jobke dbf6b7ff86 Merge pull request #4127 from nextcloud/update-legacy-csp-policy
Update legacy CSP policy
2017-03-28 17:47:32 -06:00
Lukas Reschke 3a90ab7e0a
Update legacy CSP policy
Aligns it with the one enforced by the AppFramework

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2017-03-28 23:55:31 +02:00
Morris Jobke da11931815 Merge pull request #4084 from nextcloud/fix-log-spam-with-too-few-navigation-items
Don't spam the log with "Undefined index showInHeader"
2017-03-27 15:53:08 -06:00
Georg Ehrke fc044caab1 Merge pull request #4072 from nextcloud/move-x-frame-options-into-php
Move X-Frame-Options into PHP
2017-03-27 15:05:22 +02:00
Joas Schilling 81d87b01fe
Don't spam the log with "Undefined index showInHeader"
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-03-27 10:24:10 +02:00
Joas Schilling 0229c16e5f
Don't use the dropdown for one item only
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-03-26 21:23:18 +02:00
Joas Schilling 054e161eb5
Manage the right side menu via the navigation manager as well
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-03-26 19:40:41 +02:00
Joas Schilling ec330c7ac4
Register the app management in the normal way
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-03-26 19:08:51 +02:00
Lukas Reschke bff6c8aafc
Move X-Frame-Options into PHP
The public calendar view should be embeddable and we can't do that if the .htaccess sets a global X-Frame-Options.

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2017-03-26 17:26:11 +02:00
Lukas Reschke 6a470e5935
Merge JS for template prepend
Shaves off 14 requests.

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2017-03-24 20:37:13 +01:00
Roeland Jago Douma eda98ed3df
Merge vendor js
There is a bunch of javascript we always load from vendors. This
combines this into 1 javascript file. Which reduces the number of
request by ~10.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2017-03-23 13:40:23 +01:00
Roeland Jago Douma e4d4fb5352
Only initialize backbone once
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2017-03-22 22:48:58 +01:00
Roeland Jago Douma 4518a28924 Revert "Bundle vendor js" 2017-03-22 17:01:54 +01:00
blizzz 0b5e1814be Merge pull request #3977 from nextcloud/di_ng2
Make DI work for all apps
2017-03-22 15:36:52 +01:00
Joas Schilling 9667ac2b8e
Register the namespace with the autoloading to allow reverse recovery
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-03-22 11:55:04 +01:00
Roeland Jago Douma a427e130ae
When debug don't load the bundled file
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2017-03-22 08:58:28 +01:00
Roeland Jago Douma 98a14909e1
Bundle more default vendor js
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2017-03-22 08:49:03 +01:00
Roeland Jago Douma 7195a9323d
Merge vendor js
There is a bunch of javascript we always load from vendors. This
combines this into 1 javascript file. Which reduces the number of
request by ~10.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2017-03-22 08:48:10 +01:00
Lukas Reschke 450a899f01 Merge pull request #3945 from nextcloud/downstream-27298
Adding file, line, class and function to the query logger (#27298)
2017-03-20 13:16:10 +01:00
Thomas Müller 45567572c8
Adding file, line, class and function to the query logger (#27298)
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-03-19 23:39:51 -06:00
noveens 8c27437ac0
HTTP 1.1 used when giving 403 and 404 errors while attempting to download non-existent file
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-03-19 23:14:26 -06:00
Morris Jobke edd55b0ea9
Use SystemConfig instead of AllConfig for DB stuff
* preparation for followup PRs to clean up the DB bootstrapping

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-03-19 15:53:49 -06:00
Morris Jobke cd4ebe2777 Merge pull request #3008 from nextcloud/appmenu-experiment
Show apps in header
2017-03-16 13:03:41 -06:00
Roeland Jago Douma 57c1be8633 Merge pull request #3802 from Ko-/master
Check that set_time_limit is not disabled before calling it
2017-03-16 12:27:26 +01:00
Julius Haertl 7eae6690ad
Make app management icon act like a normal app icon
Signed-off-by: Julius Haertl <jus@bitgrid.net>
2017-03-16 11:55:09 +01:00
Julius Haertl 61dc78e6dc
Fix menu issues
Signed-off-by: Julius Haertl <jus@bitgrid.net>
2017-03-16 11:55:09 +01:00
Julius Haertl a630e4629f
Generate seperate menu list for header bar
Signed-off-by: Julius Haertl <jus@bitgrid.net>
2017-03-16 11:55:09 +01:00
Julius Haertl e3e4cb3e67
Move active app to the first slot
Signed-off-by: Julius Haertl <jus@bitgrid.net>
2017-03-16 11:55:09 +01:00
Morris Jobke 252858ec5e
Do not double cherck app update
In base.php the apps are already checked for an update. No need to
repeat this during loading of the app.

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-03-13 18:07:41 -06:00
Ko- 0024b67aaf Check that set_time_limit is not disabled before calling it
Signed-off-by: Ko- <k.stoffelen@cs.ru.nl>
2017-03-11 17:04:21 +01:00
Lukas Reschke 42ee401376 Merge pull request #3778 from nextcloud/verify_jpg_files
Test if a file is a valid jpg file
2017-03-10 18:17:51 +01:00
Morris Jobke a5ba1f7803
Remove legacy class OC_Group and OC_User
* basically a straight replacement of the wrapped code at the calling code parts

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-03-09 17:35:09 -06:00
Morris Jobke 0c22a66967
Add more styles to the server.scss
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-03-09 15:36:03 -06:00
Roeland Jago Douma f2cf85fad2
[PoC] combine 2 scss files!
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2017-03-09 20:42:34 +01:00
Roeland Jago Douma 7dd760d737
Test is a file is a valid jpg file
During preview generation if we provide an invalid JPG file the system
errors out with a PHP Fatal Error. Now we can't catch Fatal Errors (in
5.6). I suspect that exif_imagetype to fall back to the extention.

However a valid jpg file has a size. So we request the size of the image
and just drop out if that returns false.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2017-03-08 21:48:30 +01:00
Joas Schilling 9f82bb9b4f Merge pull request #3689 from nextcloud/cleanup-legacy-classes
Cleanup not used legacy classes
2017-03-03 12:04:27 +01:00
Morris Jobke 6174a514b7
Get rid of static OCS::notFound()
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-03-03 00:41:21 -06:00
Morris Jobke d85a351e77
Cleanup not used legacy classes
* Person was removed via #2170
* other lcasses/interfaces are not used at all

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-03-03 00:31:33 -06:00
Sebastian Wessalowski e399097e3a Remove deprecated OC_User::isLoggedIn
Signed-off-by: Sebastian Wessalowski <sebastian@wessalowski.org>
2017-03-02 22:59:39 +01:00
Joas Schilling 079888f918
Fix code quality a bit
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-02-22 14:53:15 +01:00
Joas Schilling 1e281bc616
Use 90% JPEG quality for thumbnails and previews by default
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-02-22 14:53:15 +01:00
Morris Jobke 2b898bd82c Revert "cache the storage info for 5 min" 2017-02-16 11:58:45 -06:00
Lukas Reschke cf582a6d14 Merge pull request #3439 from nextcloud/oc-26963
Make sure invalid images don't flood the log file
2017-02-16 16:34:18 +01:00
Lukas Reschke 92c74d2f9a
Don't force displayname if backend already provides one
`\OC_User::loginWithApache` is used in combination with backend mechanisms like our SSO / SAML integration. Those can optionally already provide a displayname using other means. For example by mapping SAML attributes.

The current approach makes it however impossible for backends using `\OCP\Authentication\IApacheBackend` to set a displayname on their own. Because the display name will simply be overwritten with the loginname.

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2017-02-16 13:55:48 +01:00
Morris Jobke 200a28255e
Always enable avatars
* we introduced this setting in the begining because our
  avatar support caused some performance issues, but we
  fixed them and should only provide one way how Nextcloud
  looks

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-02-13 17:53:33 -06:00
Victor Dubiniuk 2585f195da
Check if color exists in palette before using it
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2017-02-10 16:27:51 +01:00
Joas Schilling 69046c6662
Make sure invalid images don't flood the log file
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-02-10 13:44:16 +01:00
Morris Jobke 5bad417e57 Merge pull request #2044 from nextcloud/login-credential-store
Login credential store
2017-01-30 19:30:04 -06:00
Robin Appelman f55260bc83 Merge pull request #3214 from nextcloud/cache-storage-info
cache the storage info for 5 min
2017-01-24 13:49:45 +01:00
Robin Appelman cbc18b7c8b
hash the path used for the cache key to prevent key length problems
Signed-off-by: Robin Appelman <robin@icewind.nl>
2017-01-24 11:18:05 +01:00
Robin Appelman e38a978623
cache the storage info for 5 min
Signed-off-by: Robin Appelman <robin@icewind.nl>
2017-01-23 14:52:50 +01:00
Vincent Petry 0aaf209c66
Prevent PHP request to get killed when using fclose callback (#26775)
* Prevent PHP request to get killed when using fclose callback

* Add ignore_user_abort everywhere where the time limit is set to 0

Signed-off-by: Robin Appelman <robin@icewind.nl>
2017-01-23 12:33:20 +01:00
Joas Schilling fcfb4205bc
Fix tests
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-01-13 18:33:43 +01:00
Joas Schilling 587eca3ccd
Remove the magic parsing of the description
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-01-13 18:33:42 +01:00
Christoph Wurst 140555b786
always allow remembered login
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2017-01-11 19:20:11 +01:00
Joas Schilling ec4b0d1e84
Remove group restrictions when those are not allowed anymore
Signed-off-by: Joas Schilling <coding@schilljs.com>
2017-01-04 10:40:14 +01:00
Lukas Reschke 91c87d3a7a Merge pull request #2820 from nextcloud/testing-md5home
Testing md5home (#26854)
2016-12-23 12:22:15 +01:00
Morris Jobke 44052210a2
Only show version in settings - do not list channel
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2016-12-22 14:19:29 +01:00
Vincent Petry b32e252fb0
Testing md5home (#26854)
* Allow clearing default user backends in config.php

When specifying "user_backends" in config.php, a new option "default"
when set to false will prevent the default user backend to be
registered. The default one is the database backend.
This makes it possible to select exclusive user backends from apps.

* Testing app provides test user backend for alternative homes

The backend provide md5 result to getHome()

* Only md5 the user home when it's not the admin

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2016-12-22 11:03:42 +01:00
Lukas Reschke 32bf8ec826
Don't use cached informations for app version
When installing an app from the appstore the `\OC_App::getAppVersion` code is triggered twice:

- First when the downloader tries to compare the current version to the new version on the appstore to check if there is a newer version. This protects against downgrade attacks and is implemented in `\OC\Installer::downloadApp`.
- Second, when the app is actually installed the current version is written to the database. (`\OC\Installer::installApp`)

This fails however when the version is actually cached. Because in step 1 the cached version will be set to "0" and then be reused in the second step.

While this is probably not the cleanest version I assume this is an approach that is least invasive. Feedback and suggestions welcome :)

Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2016-12-09 18:01:45 +01:00
Felix A. Epp 98bdef8d83 Cahnge URL for desktop clients directly to pop-up
by adding `/#install-clients` to the URL

Signed-off-by: Felix A. Epp <work@felixepp.de>
2016-12-08 12:40:52 +01:00
Morris Jobke a2867c0664
Properly check the data dir
* fixes #1364

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2016-12-05 23:35:35 +01:00
Morris Jobke d86b29b42b Merge pull request #2066 from nextcloud/fix-redirect-double-encoding
do not double encode the redirect url
2016-11-29 17:21:43 +01:00
Morris Jobke 734dd3a2e6
Use correct channel information
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2016-11-29 11:29:43 +01:00
Joas Schilling d2ff6c569e
Keep the filemtime for files when downloading them in a zip/tar
Signed-off-by: Joas Schilling <coding@schilljs.com>
2016-11-28 11:36:10 +01:00
John Molakvoæ (skjnldsv) 9528045178
Add jquery ui fixes js file
+ fix autocomplete width (fix #2324)

Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2016-11-25 16:44:51 +01:00
Lukas Reschke 7eaaffeee0
Update link to the docs to 11
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2016-11-22 13:29:24 +01:00
Robin Appelman 58685413d2
fix white screen of death in maintenance mode when theming is disabled
Signed-off-by: Robin Appelman <robin@icewind.nl>
2016-11-21 13:10:55 +01:00
Felix Epp 1614b310ef Add system config htaccess.IgnoreFrontController for prettyURLs w/o mod_env
Added the system config which sets all conditions to true that query the
FrontControllerActive mod_env variable.

Signed-off-by: Felix A. Epp <work@felixepp.de>
2016-11-16 22:28:49 +01:00
Morris Jobke 43e22f4da4
Add autoloader path for newly installed apps too
* followup to https://github.com/nextcloud/server/pull/2148
* problem noticed in https://github.com/nextcloud/files_antivirus/pull/11

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2016-11-16 12:55:34 +01:00
Roeland Jago Douma d03446a0ae Merge pull request #2148 from nextcloud/add_autoloader_before_enabling
Add autoloader before enabling apps
2016-11-16 12:09:39 +01:00
Joas Schilling b2248efd75
Allow to register Providers
Signed-off-by: Joas Schilling <coding@schilljs.com>
2016-11-16 09:25:45 +01:00
Joas Schilling 13ff56bfc5
Allow to register settings/types via info.xml
Signed-off-by: Joas Schilling <coding@schilljs.com>
2016-11-16 09:25:44 +01:00
Joas Schilling 280d5325c7
Allow to register activity filters via info.xml
Signed-off-by: Joas Schilling <coding@schilljs.com>
2016-11-16 09:25:40 +01:00
Morris Jobke 3c00ff2616 Merge pull request #2145 from nextcloud/docs_to_com
docs are on nc.com
2016-11-16 00:57:35 +01:00
Roeland Jago Douma d826e04757
Add autoloader before enabling apps
Else apps that require already autoloading in the installer
(files_antivius) die hard!

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2016-11-15 22:28:57 +01:00
Roeland Jago Douma 39f336035b
docs are on nc.com
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2016-11-15 19:17:42 +01:00
Roeland Jago Douma 7a8bf6ea26
Fix tests
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2016-11-15 18:10:17 +01:00
Roeland Jago Douma 028c668293
Do not cache version info in the sessions
If the session is cleared and closed for whatever reason the loadVersion
will write to the session anyways. This will lead to an exception.

This should fix #1303

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2016-11-15 17:53:12 +01:00
Thomas Müller 895b638a2c
We need to ensure that the app holding the objectstore implementation is loaded - fixes owncloud/objectstore#38 2016-11-14 15:00:45 +01:00
Christoph Wurst 0ebffa4a5f do not double encode the redirect url
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2016-11-09 16:14:46 +01:00
Joas Schilling 9296038d78
Fix preview URLs
Signed-off-by: Joas Schilling <coding@schilljs.com>
2016-11-08 16:39:13 +01:00