Browse Source

Restrict the running of reports via API to POST requests

Jeremy Stretch 7 years ago
parent
commit
21485ca6e2
2 changed files with 1 additions and 1 deletions
  1. 0 0
      docs/miscellaneous/reports.md
  2. 1 1
      netbox/extras/api/views.py

+ 0 - 0
docs/miscellaneous/reports.md


+ 1 - 1
netbox/extras/api/views.py

@@ -143,7 +143,7 @@ class ReportViewSet(ViewSet):
 
         return Response(serializer.data)
 
-    @detail_route()
+    @detail_route(methods=['post'])
     def run(self, request, pk):
         """
         Run a Report and create a new ReportResult, overwriting any previous result for the Report.