changeset 148:20c638fa8b07

new permissions for QIDO-RS & WADO-RS
author Alain Mazy <am@osimis.io>
date Thu, 15 Feb 2024 12:04:28 +0100
parents ad189440edcf
children 423531fb1200
files NEWS Plugin/DefaultAuthorizationParser.cpp Plugin/DefaultConfiguration.json
diffstat 3 files changed, 10 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/NEWS	Tue Feb 13 11:24:25 2024 +0100
+++ b/NEWS	Thu Feb 15 12:04:28 2024 +0100
@@ -1,7 +1,7 @@
 Pending changes in the mainline
 ===============================
 
-* Added 2 new default permissions for dicom-web (get and post on dicom-web/studies).
+* Added new default permissions for dicom-web STOW-RS, QIDO-RS and WADO-RS.
 
 
 2023-12-19 - v 0.6.2
--- a/Plugin/DefaultAuthorizationParser.cpp	Tue Feb 13 11:24:25 2024 +0100
+++ b/Plugin/DefaultAuthorizationParser.cpp	Thu Feb 15 12:04:28 2024 +0100
@@ -43,6 +43,7 @@
       tmp = tmp.substr(0, tmp.size() - 1);
     }
 
+    // note: if you add new DICOMWeb routes here, add them in the DefaultConfiguration.json too
     dicomWebStudies_ = boost::regex(
       "^" + tmp + "/studies/([.0-9]+)(|/series|/metadata)(|/)$");
       
--- a/Plugin/DefaultConfiguration.json	Tue Feb 13 11:24:25 2024 +0100
+++ b/Plugin/DefaultConfiguration.json	Thu Feb 15 12:04:28 2024 +0100
@@ -88,8 +88,14 @@
             ["post", "^/modalities/(.*)/move$", "all|q-r-remote-modalities"],
             ["get" , "^/DICOM_WEB_ROOT/servers$", "all|send|q-r-remote-modalities"],
             ["get" , "^/DICOM_WEB_ROOT/(servers)/(.*)/stow$", "all|send"],
-            ["get" , "^/DICOM_WEB_ROOT/studies$", "all|view"],
-            
+
+            // DICOMWeb QIDO-RS            
+            ["get" , "^/DICOM_WEB_ROOT/(studies|series|instances)(|/)$", "all|view"],
+            // DICOMWeb WADO-RS (a user must have access to the route + have an authorized label)
+            ["get" , "^/DICOM_WEB_ROOT/studies/([.0-9]+)(|/series|/metadata)(|/)$", "all|view"],
+            ["get" , "^/DICOM_WEB_ROOT/studies/([.0-9]+)/series/([.0-9]+)(|/instances|/rendered|/metadata)(|/)$", "all|view"],
+            ["get" , "^/DICOM_WEB_ROOT/studies/([.0-9]+)/series/([.0-9]+)/instances/([.0-9]+)(|/|/frames/.*|/rendered|/metadata|/bulk/.*)(|/)$", "all|view"],
+
             // modifications/anonymization
             ["post", "^/(patients|studies|series|instances)/([a-f0-9-]+)/(modify|merge)(.*)$", "all|modify"],
             ["post", "^/(patients|studies|series|instances)/([a-f0-9-]+)/anonymize(.*)$", "all|anonymize"],