Unix Permission
Synopsis
Extracts and decodes Unix file permission information.
Schema
- unix_permission:
field: <ident>
target_field: <string>
input_format: <string>
output_format: <string>
include_special: <boolean>
description: <text>
if: <script>
ignore_failure: <boolean>
ignore_missing: <boolean>
on_failure: <processor[]>
on_success: <processor[]>
tag: <string>
Configuration
The following fields are used to define the processor:
Field | Required | Default | Description |
---|---|---|---|
field | Y | - | Source field containing Unix permission data |
target_field | N | {field}_decoded | Target field to store decoded permission information |
input_format | N | auto | Input format: auto , octal , symbolic , decimal |
output_format | N | detailed | Output format: detailed , octal , symbolic , rwx |
include_special | N | true | Include special permission bits (setuid, setgid, sticky) |
description | N | - | Explanatory note |
if | N | - | Condition to run |
ignore_failure | N | false | Continue processing if decoding fails |
ignore_missing | N | false | Skip processing if referenced field doesn't exist |
on_failure | N | - | See Handling Failures |
on_success | N | - | See Handling Success |
tag | N | - | Identifier |
Details
Decodes Unix file permissions from various formats including octal notation (755), symbolic notation (rwxr-xr-x), and decimal values. The processor extracts owner, group, and other permissions along with special permission bits.
The processor can automatically detect the input format or work with explicitly specified formats, providing flexible parsing for different Unix permission representations.
Unix permissions consist of three sets of three bits each: owner (user), group, and other. Each set contains read (r), write (w), and execute (x) permissions. Special bits include setuid, setgid, and sticky bit.
When include_special
is enabled, the processor also decodes special permission bits that affect how files and directories behave in Unix systems.
If the input permission data is malformed or contains invalid permission values, the processor will fail unless ignore_failure
is set to true
.
Examples
Octal Permission Decoding
Decoding octal permission notation... |
|
extracts detailed permission breakdown: |
|
Symbolic Permission Input
Processing symbolic permission notation... |
|
converts to detailed format: |
|
Special Permissions
Including special permission bits... |
|
decodes setuid bit: |
|
Output Format Options
Converting to symbolic output only... |
|
outputs symbolic notation: |
|
Multiple Permission Values
Processing array of permission values... |
|
converts each to rwx format: |
|