Joas Schilling
f6b6776c93
fix(API): Use a distinct exception so apps can react to it and customize the return
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-11-28 06:11:57 +07:00
Joas Schilling
aa5f037af7
chore: apply changes from Nextcloud coding standards 1.1.1
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
2023-11-23 10:36:13 +07:00
Ferdinand Thiessen
ecf9f0a872
fix(CSP): Only add `strict-dynamic` when using nonces
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2023-11-17 22:01:02 +07:00
Ferdinand Thiessen
e231abd9bf
fix!(ContentSecurityPolicy): Make `strict-dynamic` enabled by default on `script-src-elem`
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2023-11-17 14:42:36 +07:00
Ferdinand Thiessen
7df9eb3351
feat(ContentSecurityPolicy): Allow to set `strict-dynamic` on `script-src-elem` only
...
This adds the possibility to set `strict-dynamic` on `script-src-elem` only while keep the default rules for `script-src`.
The idea is to allow loading module js which imports other files and thus does not allow nonces on import but on the initial script tag.
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2023-11-17 11:12:57 +07:00
Joas Schilling
ffc1bb774b
feat(openapi): Add OpenAPI attribute to allow multiple scopes and overwriting tags
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-11-03 09:25:11 +07:00
Joas Schilling
2b7f78fc2e
Merge pull request #40326 from nextcloud/enh/text-to-image-api
...
Implement TextToImage OCP API
2023-10-26 15:53:30 +07:00
Marcel Klehr
8339b5b128
fix: Minor copypasta
...
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2023-10-23 15:00:40 +07:00
Marcel Klehr
cee5aa84f0
fix(Text2Image): Fix psalm errors
...
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2023-10-20 14:56:24 +07:00
Côme Chilliet
1202171b32
Fix docblock and types for new public API
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-10-19 11:43:59 +07:00
Carl Schwan
eb1d612d96
Add api to register setup checks
...
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2023-10-19 11:43:58 +07:00
Ferdinand Thiessen
154a9989a7
Merge pull request #39852 from nextcloud/pragmaHeader
...
Stop sending deprecated Pragma header
2023-10-18 03:30:21 +07:00
Côme Chilliet
8212feefb9
Merge pull request #40367 from nextcloud/fix/user_ldap-update-groups-on-login
...
Fire group membership events from LDAP at login
2023-10-16 10:01:55 +07:00
Côme Chilliet
500374a8e7
Fix registerEventListener signature
...
It seems now psalm correctly supports this.
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-10-12 10:13:43 +07:00
Joas Schilling
0a4fbaddc7
Fix version number in ITimeFactory after it was delayed
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-10-11 12:14:41 +07:00
Git'Fellow
066f6ef16c
Stop sending deprecated Pragma header
...
Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
2023-08-28 15:11:22 +07:00
Anna Larch
66c1aa4a3c
fix(utility): De- deprecate getDateTime as now() only returns immutable objects
...
This will mean lots of code like
```$dateTime = (new DateTime())->setTimestamp(ITimeFactory::now()->getTimestamp()```
if a regular DateTime object is needed
Signed-off-by: Anna Larch <anna@nextcloud.com>
2023-08-25 08:55:44 +07:00
Robin Appelman
ccf57e0715
add separate event for rendering login page template
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-08-17 10:57:56 +07:00
Daniel Calviño Sánchez
41f2d912d2
Allow "wasm-unsafe-eval" in CSP
...
If a page has a Content Security Policy header and the `script-src` (or
`default-src`) directive does not contain neither `wasm-unsafe-eval` nor
`unsafe-eval` loading and executing WebAssembly is blocked in the page
(although it is still possible to load and execute WebAssembly in a
worker thread).
Although the Nextcloud classes to manage the CSP already supported
allowing `unsafe-eval` this affects not only WebAssembly, but also the
`eval` operation in JavaScript.
To make possible to allow WebAssembly execution without allowing
JavaScript `eval` this commit adds support for allowing
`wasm-unsafe-eval`.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2023-08-10 02:38:41 +07:00
Joas Schilling
1b387bb341
fix!: Remove legacy event dispatching Symfony's GenericEvent from AdditionalScripts
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-07-27 09:57:52 +07:00
Marcel Klehr
7c80d66ee5
Merge pull request #38854 from nextcloud/enh/llm-api
2023-07-21 11:20:31 +07:00
Marcel Klehr
ffe27ce14c
Massive refactoring: Turn LanguageModel OCP API into TextProcessing API
...
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2023-07-14 16:00:31 +07:00
jld3103
2d6a62ccee
Add IgnoreOpenAPI attribute
...
Signed-off-by: jld3103 <jld3103yt@gmail.com>
2023-07-10 14:25:22 +07:00
Marcel Klehr
069962d04f
Since 27.1.0
...
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2023-07-07 13:46:34 +07:00
Marcel Klehr
fb55afc9ff
Update lib/public/AppFramework/Bootstrap/IRegistrationContext.php
...
Co-authored-by: Daniel <mail@danielkesselberg.de>
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2023-07-07 13:39:10 +07:00
Marcel Klehr
795b097122
LLM OCP API: Implement ocs API
...
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2023-07-07 13:39:10 +07:00
Christoph Wurst
14719110b9
chore: Replace \OC::$server->query with \OCP\Server::get in /lib
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2023-07-06 15:21:22 +07:00
Louis Chemineau
407c361b91
Add OCSPreconditionFailedException
...
Signed-off-by: Louis Chemineau <louis@chmn.me>
2023-07-05 20:01:45 +07:00
jld3103
b0001c6010
Add template types to responses
...
Signed-off-by: jld3103 <jld3103yt@gmail.com>
2023-06-30 09:33:29 +07:00
Christoph Wurst
08a3f37695
chore(appframework)!: Drop \OCP\AppFramework\Http\EmptyContentSecurityPolicy::allowInlineScript
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2023-06-12 10:03:59 +07:00
Git'Fellow
5b5895a130
Drop meta robots tag
...
Revert mistake
Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
2023-06-09 18:06:37 +07:00
Faraz Samapoor
bf38c0a3d1
Refactors "strpos" calls in lib/public to improve code readability.
...
Signed-off-by: Faraz Samapoor <fsamapoor@gmail.com>
2023-06-05 11:14:52 +07:00
Joas Schilling
5b2d5767e1
fix(docs): Fix language and copy-paste class name in docs of CSP
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-05-30 13:39:33 +07:00
Julius Härtl
050c6d53b3
enh: Provide atomicRetry method to retry transactions if possible
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-05-16 08:13:20 +07:00
Simon L
d55a7c619d
Fix typos in lib/public subdirectory
...
Found via `codespell -q 3 -S l10n -L jus ./lib/public`
Signed-off-by: luz paz <luzpaz@github.com>
Update lib/public/Accounts/IAccount.php
Signed-off-by: luz paz <luzpaz@github.com>
Signed-off-by: Simon L <szaimen@e.mail.de>
Co-Authored-By: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
2023-05-10 11:56:34 +07:00
Daniel Kesselberg
eecdb62e92
fix: add workaround for oci and limit queries
...
DBAL uses a helper column "doctrine_rownum" for top-n queries
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2023-05-02 14:26:28 +07:00
Joas Schilling
ecb8b55c5c
feat(security): Add PHP \Attribute for remaining security annotations
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-04-25 14:50:32 +07:00
Joas Schilling
89c3c31402
feat(ratelimit): Add Attributes support to rate limit middleware
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-04-24 12:24:48 +07:00
Joas Schilling
fd473f89e8
Merge pull request #37674 from nextcloud/feature/speech-to-text
...
feat(SpeechToText): Add SpeechToText OCP provider API
2023-04-19 16:29:44 +07:00
Christoph Wurst
2c0cfd3772
feat(app-framework): Add native argument types for middleware
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2023-04-18 17:15:05 +07:00
Ferdinand Thiessen
bdbff2181e
fix: Allow to catch `IMapperException` by implementing `Throwable`
...
Signed-off-by: Ferdinand Thiessen <rpm@fthiessen.de>
2023-04-17 16:05:10 +07:00
Marcel Klehr
317521b607
feat(SpeechToText): Add SpeechToText provider API
...
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2023-04-11 14:59:57 +07:00
jld3103
b153340b62
Add type hints for mappers
...
Signed-off-by: jld3103 <jld3103yt@gmail.com>
2023-04-07 09:49:42 +07:00
Joas Schilling
e839eb9b5c
feat(middleware): Migrate BruteForceProtection annotation to PHP Attribute and allow multiple
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-03-08 12:09:22 +07:00
Joas Schilling
c297f8ee96
feat(appframework): ⌚ Make ITimeFactory extend \PSR\Clock\ClockInterface
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-03-03 15:37:13 +07:00
Julius Härtl
3e63298381
feat(translations): Add translation provider API
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-02-27 16:52:03 +07:00
MichaIng
5f90b8eb11
Change X-Robots-Tag header from "none" to "noindex, nofollow"
...
While "none" is indeed equivalent to "noindex, nofollow" for Google, but seems to be not supported by Bing and probably other search engines.
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta/name#other_metadata_names
https://developers.google.com/search/docs/crawling-indexing/robots-meta-tag?hl=de#comma-separated-list
https://www.bing.com/webmasters/help/which-robots-metatags-does-bing-support-5198d240
Signed-off-by: MichaIng <micha@dietpi.com>
2023-02-15 20:16:51 +07:00
Joas Schilling
6f3ce5c319
Also copy bruteforce meta data when converting DataResponse to JSONResponse
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-02-14 16:00:10 +07:00
Ferdinand Thiessen
ba8a50c059
fix: Throw `NotFoundExceptionInterface` to fulfill PSR container interface if class not found
...
Signed-off-by: Ferdinand Thiessen <rpm@fthiessen.de>
2023-02-06 14:16:35 +07:00
Louis Chemineau
4ab3c16403
Pluggable share provider
...
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
Signed-off-by: Louis Chemineau <louis@chmn.me>
2023-02-02 15:41:26 +07:00