Remove CSRF check from code integrity rescan

Did not find a way to get a valid token from SetupCheck

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
pull/41312/head
Côme Chilliet 5 months ago
parent 8766a90cff
commit 24f8b04908
No known key found for this signature in database
GPG Key ID: A3E2F658B28C760A

@ -234,6 +234,7 @@ class CheckSetupController extends Controller {
}
/**
* @NoCSRFRequired
* @return RedirectResponse
* @AuthorizedAdminSetting(settings=OCA\Settings\Settings\Admin\Overview)
*/

@ -53,7 +53,6 @@ class CodeIntegrity implements ISetupCheck {
} elseif ($this->checker->hasPassedCheck()) {
return SetupResult::success($this->l10n->t('No altered files'));
} else {
// FIXME: If setup check can link to settings pages this should link to /settings/integrity/failed and /settings/integrity/rescan?requesttoken=TOKEN
return SetupResult::error(
$this->l10n->t('Some files have not passed the integrity check. {link1} {link2}'),
$this->urlGenerator->linkToDocs('admin-code-integrity'),
@ -68,7 +67,6 @@ class CodeIntegrity implements ISetupCheck {
'type' => 'highlight',
'id' => 'rescanFailedIntegrityCheck',
'name' => 'Rescan…',
//, ['requesttoken' => '']?
'link' => $this->urlGenerator->linkToRoute('settings.CheckSetup.rescanFailedIntegrityCheck'),
],
],

Loading…
Cancel
Save