mirror of
https://github.com/wallabag/wallabag.git
synced 2025-06-27 16:36:00 +00:00
Use 400 Bad Request errors for invalid CSRF everywhere
This commit is contained in:
parent
5ea5115a72
commit
677b2986bc
4 changed files with 11 additions and 10 deletions
|
@ -105,7 +105,7 @@ class DeveloperControllerTest extends WallabagCoreTestCase
|
|||
|
||||
$this->logInAs('bob');
|
||||
$client->request('POST', '/developer/client/delete/' . $adminApiClient->getId());
|
||||
$this->assertSame(403, $client->getResponse()->getStatusCode());
|
||||
$this->assertSame(400, $client->getResponse()->getStatusCode());
|
||||
|
||||
// Try to remove the admin's client with the good user
|
||||
$this->logInAs('admin');
|
||||
|
|
|
@ -794,7 +794,7 @@ class ConfigControllerTest extends WallabagCoreTestCase
|
|||
$this->assertStringNotContainsString('config.form_user.delete.button', $body[0]);
|
||||
|
||||
$client->request('POST', '/account/delete');
|
||||
$this->assertSame(403, $client->getResponse()->getStatusCode());
|
||||
$this->assertSame(400, $client->getResponse()->getStatusCode());
|
||||
|
||||
$user = $em
|
||||
->getRepository(User::class)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue