You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Can overwrite `NEWDEV` or plugin-owned sources (if plugin has SET_ALWAYS enabled)
197
+
- Will update plugin-owned sources if value the same
197
198
198
199
**Example in config.json:**
200
+
199
201
```json
200
202
{
201
-
"setKey": "NEWDEV_devName",
202
-
"displayName": "Device Name",
203
-
"SET_ALWAYS": "1"
203
+
"SET_ALWAYS": ["devName", "devLastIP"]
204
204
}
205
205
```
206
206
@@ -210,50 +210,18 @@ Controls whether a plugin field is enabled:
210
210
211
211
Restricts when a plugin can update a field:
212
212
213
-
-`"1"` - Overwrite only if current value is empty OR source is NEWDEV (conservative mode)
214
-
-`"0"` - No extra restriction; respect authorization logic (default)
213
+
-`"SET_EMPTY": ["devName", "devLastIP"]` - Overwrite these fields only if current value is empty OR source is `NEWDEV`
215
214
216
-
**Use case:** Some plugins discover optional enrichment data (like vendor/hostname) that shouldn't override user-set or existing values. Use `SET_EMPTY: "1"` to be less aggressive.
215
+
**Use case:** Some plugins discover optional enrichment data (like vendor/hostname) that shouldn't override user-set or existing values. Use `SET_EMPTY` to be less aggressive.
217
216
218
-
**Example in config.json:**
219
-
```json
220
-
{
221
-
"setKey": "NEWDEV_devVendor",
222
-
"displayName": "Device Vendor",
223
-
"SET_ALWAYS": "1",
224
-
"SET_EMPTY": "1"
225
-
}
226
-
```
227
217
228
218
### Authorization Decision Flow
229
219
230
220
1.**Source check:** Is field LOCKED or USER? → REJECT (protected)
231
-
2.**SET_ALWAYS check:** Is SET_ALWAYS enabled for this plugin+field? → YES: ALLOW (can overwrite empty values, NEWDEV, plugin sources, etc.) | NO: Continue to step 3
232
-
3.**SET_EMPTY check:** Is SET_EMPTY enabled AND field non-empty+non-NEWDEV? → REJECT
221
+
2.**Field in SET_ALWAYS check:** Is SET_ALWAYS enabled for this plugin+field? → YES: ALLOW (can overwrite empty values, NEWDEV, plugin sources, etc.) | NO: Continue to step 3
222
+
3.**Field in SET_EMPTY check:** Is SET_EMPTY enabled AND field non-empty+non-NEWDEV? → REJECT
233
223
4.**Default behavior:** Allow overwrite if field empty or NEWDEV source
234
224
235
-
### Plugin Field Mappings Reference
236
-
237
-
This table shows all device discovery and enrichment plugins and their tracked field configuration:
238
-
239
-
| Plugin | Tracked Fields | Behavior |
240
-
|--------|---|---|
241
-
| ARPSCAN | devMac, devLastIP | SET_ALWAYS for both |
242
-
| IPNEIGH | devMac, devLastIP | SET_ALWAYS for both |
243
-
| DHCPLSS | devMac, devLastIP | SET_ALWAYS for both |
244
-
| ASUSWRT | devMac, devLastIP | SET_ALWAYS for both |
245
-
| LUCIRPC | devMac, devLastIP | SET_ALWAYS for both |
0 commit comments