Skip to content

Commit

Permalink
Merge pull request #14 from LibreSign/fix/remove-csrf-check
Browse files Browse the repository at this point in the history
fix: remove csrf check
  • Loading branch information
vitormattos authored Dec 4, 2024
2 parents 4a18a34 + 663725f commit 3706153
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/Controller/AdminGroupController.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
use OCP\AppFramework\Http;
use OCP\AppFramework\Http\Attribute\ApiRoute;
use OCP\AppFramework\Http\Attribute\AuthorizedAdminSetting;
use OCP\AppFramework\Http\Attribute\NoCSRFRequired;
use OCP\AppFramework\Http\DataResponse;
use OCP\AppFramework\OCS\OCSException;
use OCP\BackgroundJob\IJobList;
Expand Down Expand Up @@ -66,6 +67,7 @@ public function __construct(
*/
#[ApiRoute(verb: 'POST', url: '/api/{apiVersion}/admin-group', requirements: ['apiVersion' => '(v1)'])]
#[AuthorizedAdminSetting(settings:Users::class)]
#[NoCSRFRequired]
#[RestrictIp]
public function createAdminGroup(
string $groupid,
Expand Down Expand Up @@ -98,6 +100,7 @@ public function createAdminGroup(
*/
#[ApiRoute(verb: 'POST', url: '/api/{apiVersion}/users-of-group/set-enabled', requirements: ['apiVersion' => '(v1)'])]
#[AuthorizedAdminSetting(settings:Users::class)]
#[NoCSRFRequired]
#[RestrictIp]
public function setEnabled(
string $groupid,
Expand Down

0 comments on commit 3706153

Please sign in to comment.