changeset 893:8b48d42665c4

auth 0.4.0
author Alain Mazy <am@osimis.io>
date Thu, 10 Nov 2022 11:31:36 +0100
parents 3982b4a4bdbc
children 08ea0a05acba 4ef1cfc56a0a
files Sphinx/source/plugins/authorization.rst
diffstat 1 files changed, 35 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/Sphinx/source/plugins/authorization.rst	Thu Nov 10 10:19:04 2022 +0100
+++ b/Sphinx/source/plugins/authorization.rst	Thu Nov 10 11:31:36 2022 +0100
@@ -285,6 +285,10 @@
       "WebServiceIdentifier": "my-id",          // new in v 0.3.0
       "TokenGetArguments" : [ "user" ],
       "TokenHttpHeaders" : [ "hello" ],
+      "StandardConfigurations": [               // new in v 0.4.0
+        "osimis-web-viewer",
+        "stone-webviewer"
+      ],
       "UncheckedResources" : [
         "/series",
         "/instances",
@@ -299,7 +303,12 @@
         "/web-viewer/libs/",
         "/wsi/app/"
       ],
-      "UncheckedLevels" : [ "study" ]
+      "CheckedLevel" : "studies",               // new in v 0.4.0
+      "UncheckedLevels" : [ 
+         "patients", 
+         "series",
+         "instances"
+      ]
     }
   }
 
@@ -307,6 +316,15 @@
 ``TokenGetArguments``, and ``TokenHttpHeaders``. Here are the
 remaining options:
 
+* ``StandardConfigurations`` is a helper configuration to pre-populate
+  ``UncheckedResources``, ``UncheckedFolders``, ``TokenGetArguments``,
+  and ``TokenHttpHeaders`` of well-known plugins.
+  Allowed values are ``osimis-web-viewer``, ``stone-webviewer``.
+
+* ``CheckedLevel`` may replace ``UncheckedLevels`` when authorization
+  is checked only at one level of the DICOM hierarchy.  This is the most
+  common use-case.
+
 * ``UncheckedResources`` specifies a list of resources for which the
   authentication plugin is not triggered, and to which access is
   always granted.
@@ -322,6 +340,22 @@
   the series and instance levels can be ignored.
 
 
+Here is a minimal configuration for the :ref:`Stone Web viewer <stone_webviewer>`::
+
+  {
+    // disable basic authentication since it is replaced by the authorization plugin
+    "AuthenticationEnabled": false,
+
+    "Authorization" : {
+      "WebService" : "http://localhost:8000/shares/validate",
+      "StandardConfigurations": [
+        "stone-webviewer"
+      ],
+      "CheckedLevel" : "studies"
+    }
+  }
+
+
 .. _orthanc-explorer-authorization:
 
 Integration with the Orthanc Explorer