Commits

Ben Bangert committed 1ef5539

Secure doc deletion

Comments (0)

Files changed (1)

kai/controllers/docs.py

     
     @jsonify
     def delete_revision(self, project, version):
+        dockey = config['doc.security_key']
+        if request.environ['HTTP_AUTHKEY'] != dockey:
+            abort(401)
+        
         Documentation.delete_revision(project, version)
         return dict(status='ok')