summaryrefslogtreecommitdiffstats
path: root/lib/public/AppFramework
Commit message (Collapse)AuthorAgeFilesLines
* Initialize \OCP\AppFramework\Http\ZipResponse::$resourcesChristoph Wurst2021-02-171-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Move TemplateProvider registration to boot context and make template type ↵Julius Härtl2021-01-281-0/+11
| | | | | | registration lazy Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Add a hint about the direction of priorityJoas Schilling2021-01-151-1/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Update license headersChristoph Wurst2020-12-301-1/+0
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #24702 from nextcloud/enhancement/well-known-handler-apiChristoph Wurst2020-12-181-0/+14
|\ | | | | Add well known handlers API
| * Add well known handlers APIChristoph Wurst2020-12-161-0/+14
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Update all license headers for Nextcloud 21Christoph Wurst2020-12-167-2/+8
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Log an error when setting a custom header on "Not Modified" responsesJoas Schilling2020-12-151-0/+14
|/ | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Update comment to reflect current CSP policyThomas Citharel2020-12-121-1/+1
| | | JS unsafe-eval was removed a long time ago in https://github.com/nextcloud/server/pull/11028
* Fix DataResponse typehintsRoeland Jago Douma2020-11-191-4/+4
| | | | | | | | | We use this already in several places where we just pass strings or numbers. This all works because we just convert it to a json response in the end. So better to have the typehints reflect this. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Merge pull request #24189 from nextcloud/enh/csp/frame-ancestorsRoeland Jago Douma2020-11-181-0/+2
|\ | | | | Set frame-ancestors to none if none are filled
| * Set frame-ancestors to none if none are filledRoeland Jago Douma2020-11-181-0/+2
| | | | | | | | | | | | | | | | frame-ancestors doesn't fall back to default-src. So when we apply a very restricted CSP we should make sure to set it to 'none' and not leave it empty. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Remove some IRouter methodsRoeland Jago Douma2020-11-171-0/+5
|/ | | | | | | | | This is not the end. IRouter needs to burn. But it is a start. 🎵 we didn't start the fire 🎵 Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Remove deprecated OCSResponseRoeland Jago Douma2020-11-011-95/+0
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Type the \OCP\AppFramework\Services\IInitialState::provideLazyInitialState ↵Christoph Wurst2020-10-281-1/+4
| | | | | | closure with Psalm Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add psalm types for the event dispatcherChristoph Wurst2020-10-151-2/+3
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add Psalm type for the bootstrap registration contextChristoph Wurst2020-10-121-2/+13
| | | | | | This can potentially catch a few bugs with wrong class strings. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Add template typing to the QBMapperChristoph Wurst2020-10-121-2/+17
| | | | | | | | | | | | | The QBMapper is kind of a generic type, though this concept does not exist in php. Hence you have a lot of type coercion in subtypes (mappers in the individual apps) because you suddenly don't expect an Entity[] but your specific type. Luckily Psalm lets us type those. Then in the subclass you can psalm-implement the mapper with a concrete type and psalm will do all the magic to ensure types are used correctly. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format code to a single space around binary operatorsChristoph Wurst2020-10-0512-28/+28
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Move initial state provider to boostrapRoeland Jago Douma2020-10-042-0/+62
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Add acutal response to BeforeTemplateRenderedEventJulius Härtl2020-09-241-1/+12
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Remove @suppress SqlInjectionCheckerMorris Jobke2020-09-161-3/+0
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Fix writing BLOBs to postgres with recent contacts interactionChristoph Wurst2020-08-282-1/+8
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #22432 from nextcloud/enh/phpdocRoeland Jago Douma2020-08-2624-24/+0
|\ | | | | Add php docs build script
| * Remove @package annotations from public namespaceJulius Härtl2020-08-2623-23/+0
| | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
| * Remove wrongly annotated package namesJulius Härtl2020-08-261-1/+0
| | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Update the license headers for Nextcloud 20Christoph Wurst2020-08-2412-11/+30
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix CSJoas Schilling2020-08-191-0/+1
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Send "429 Too Many Requests" in case of brute force protectionJoas Schilling2020-08-191-0/+51
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Refactor API to match the widget wordingJulius Härtl2020-08-051-2/+2
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Merge pull request #22097 from nextcloud/enh/noid/empty-templateMorris Jobke2020-08-051-0/+5
|\ | | | | Add empty renderAs template
| * Add base renderAs templateJulius Härtl2020-08-041-0/+5
| | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Move NotFoundResponse to a proper TemplateResponseJulius Härtl2020-07-241-13/+2
|/ | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Use the proper IAppContainer and IServerContainer type hints to know which ↵Morris Jobke2020-07-212-6/+4
| | | | | | code runs with which container Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Make the bootstrap context return ContainerInterface instancesChristoph Wurst2020-07-212-4/+5
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #21850 from ↵Morris Jobke2020-07-201-0/+13
|\ | | | | | | | | nextcloud/techdebt/noid/register-alternative-logins Allow to register AlternativeLogin on RegistrationContext
| * Allow to register AlternativeLogin on RegistrationContextJoas Schilling2020-07-161-0/+13
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Undeprecate IAppContainer and IServerContainerChristoph Wurst2020-07-171-5/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With 4152216bd8cf9d49e6749d26bb8b491dd49b089b these two interfaces got deprecated with the reasoning that we only need the base PSR interface. However, there are cases where in Nextcloud you still want to have a specific container (the one for the app vs the one for the server) when you either have a container injected or query one from a container. With a single interface that would not be possible. So it's probably better if we leave the two interfaces, but only have them extend the PSR interface. IContainer – with the custom methods – shall still be phased out, but the two other sub interfaces can stay for tagging purposes. Tagging means that no methods shall be added. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Add constants for the magic strings of template renderingJoas Schilling2020-07-161-3/+34
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Use PSR container interface and deprecate our own abstractionChristoph Wurst2020-07-163-4/+17
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Better event description for BeforeTemplateRenderedEvent in files and ↵Morris Jobke2020-07-151-2/+2
| | | | | | files_sharing Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Add real events to load additionalscriptsRoeland Jago Douma2020-07-152-0/+62
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Move to lazy panel registration during registration contextJulius Härtl2020-07-151-0/+9
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Deprecate registerRoutesRoeland Jago Douma2020-07-061-0/+1
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Callable parameter injectionChristoph Wurst2020-07-031-0/+22
| | | | | | | | | | | | | | This is like what we have to DI and classes, but for callables. The motivating factor is to get rid of *service locators* in the `boot` method of apps as a new pattern is about to emerge where we have lots of `query` calls on the app or server container in order to fetch some services. With this little helper it's possible to call another (public) method and magically have everything injected. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix robots "noindex, nofollow" signalsJoas Schilling2020-06-252-0/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Add unified search APIChristoph Wurst2020-06-241-0/+15
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Allow to specify the cookie type for appframework responsesRoeland Jago Douma2020-06-222-3/+5
| | | | | | | | | In general it is good to set them to Lax. But also to give devs more control over them is not a bad thing. Helps with #21474 Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Allow crash reporters registration during app bootstrapChristoph Wurst2020-06-191-0/+10
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Load the app.php before running apps' boot methodChristoph Wurst2020-06-171-0/+7
| | | | | | | | Some apps require the composer autoloader from app.php. If we run boot before including that file, classes and functions from dependencies won't be found. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>