Skip to content

Commit e5e5c47

Browse files
committed
Add docs for variable security feature
1 parent 0ca4889 commit e5e5c47

File tree

4 files changed

+26
-1
lines changed

4 files changed

+26
-1
lines changed

README.md

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -396,4 +396,28 @@ You can display you file upload in a formio form by returning the base64 value i
396396

397397
Typical use case would be to upload the file as JSON/base64 as part of the form submission, and then handle transitive modifications of the file
398398
into other storage formats, and drop the base64 value from the submission / replace with other values pointing to a long term
399-
storage format (such as a blob/file storage container)
399+
storage format (such as a blob/file storage container)
400+
401+
## Get-Form-Variables Command Security Plugin
402+
403+
The plugin `GetFormVariablesSecurityProcessEnginePlugin.class` provides variable security using Camunda Extension
404+
Properties on a User Task.
405+
406+
Plugin full path: `com.github.stephenott.camunda.tasks.forms.command.GetFormVariablesSecurityProcessEnginePlugin`
407+
408+
The plugin provides two types of variable security:
409+
410+
1. `allowed-variables` : a comma separated list of variable names that can be accessed using the endpoint `GET /task/{id}/form-variables` or the java api (getFormVariables).
411+
1. `restricted-variables` : a comma separated list of variable names that cannot be accessed using the endpoint `GET /task/{id}/form-variables` or the java api (getFormVariables).
412+
413+
`allowed-variables` is used to control the exact list of variables that can be accessed. Any variables that are not part of this list will be removed from the result. No error will be thrown.
414+
415+
`restricted-variables` is used to control which variables cannot be accessed. Any variables that are part of this will be removed from the result. No error will be thrown.
416+
417+
Example:
418+
419+
![allowed-variables](./doc/ut-allowed-variables.png)
420+
421+
![restricted-variables](./doc/ut-restricted-variables.png)
422+
423+

doc/ut-allowed-variables.png

84.5 KB
Loading

doc/ut-restricted-variables.png

87.1 KB
Loading

docker/bpm-platform.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@
3838
<plugin>
3939
<class>com.github.stephenott.camunda.formio.FormioFormFieldValidatorProcessEnginePlugin</class>
4040
</plugin>
41+
4142
<plugin>
4243
<class>com.github.stephenott.camunda.tasks.forms.command.GetFormVariablesSecurityProcessEnginePlugin</class>
4344
</plugin>

0 commit comments

Comments
 (0)