{"record":{"id":"e8292399a1f136ae","repo":"unicity-aos/aos-ce","slug":"unknown-capability-field-key","errorCode":null,"errorMessage":"Unknown capability field `{key}`.","messagePattern":"Unknown capability field `(.+?)`\\.","errorType":"validation","errorClass":"Finding","httpStatus":null,"severity":"warning","filePath":"capsules/capsule-forge/src/checks.rs","lineNumber":120,"sourceCode":"    const BOOL_FIELDS: &[&str] = &[\"uplink\", \"allow_persistent\", \"allow_prompt_injection\"];\n\n    for (key, value) in capabilities {\n        if LIST_FIELDS.contains(&key.as_str()) {\n            if !value.is_array() {\n                out.push(Finding::err(\n                    format!(\"Capability `{key}` must be a list.\"),\n                    format!(\"Use `{key} = [\\\"scope\\\"]`, or omit it when unused.\"),\n                ));\n            }\n        } else if BOOL_FIELDS.contains(&key.as_str()) {\n            if !value.is_bool() {\n                out.push(Finding::err(\n                    format!(\"Capability `{key}` must be a boolean.\"),\n                    format!(\"Use `{key} = true` or omit it (the default is false).\"),\n                ));\n            }\n        } else {\n            out.push(Finding::warn(\n                format!(\"Unknown capability field `{key}`.\"),\n                \"Use only the current fields documented by `forge_guide` topic `capabilities`.\",\n            ));\n        }\n    }\n\n    if capabilities\n        .get(\"kv\")\n        .and_then(Toml::as_array)\n        .is_some_and(|values| !values.is_empty())\n    {\n        out.push(Finding::info(\n            \"The `kv` capability field is reserved; ordinary capsule KV does not require it.\",\n            \"Omit `kv` unless the pinned runtime contract specifically requires it.\",\n        ));\n    }\n}\n","sourceCodeStart":102,"sourceCodeEnd":138,"githubUrl":"https://github.com/unicity-aos/aos-ce/blob/f6f22024fb1e8d122f28a1b4a9f75aee448ae839/capsules/capsule-forge/src/checks.rs#L102-L138","documentation":"During manifest validation, check_capabilities iterates the [capabilities] table and only recognizes documented capability keys. Any key that is not a known capability (and not a boolean-valued known field) produces this warning telling the author the field is ignored. Forge fails closed: unknown capabilities grant nothing, so a typo silently disables the intended capability.","triggerScenarios":"validate_manifest -> check_capabilities finds a key under [capabilities] that is not in the set of current capability names; typically a typo (e.g. capability = netwok) or a capability renamed in a newer forge version.","commonSituations":"Copying an example manifest from an outdated blog post or old template; misspelling a capability name; inventing a plausible capability that doesn't exist; upgrading forge where a capability was renamed.","solutions":["Run `forge_guide` topic `capabilities` to list valid capability fields and use one of those exact names.","Fix typos in the capability key (the warning names the offending key).","If migrating from an older capsule, check the forge changelog for renamed capabilities and update the manifest.","Remove the unknown key entirely if the capability is not actually needed."],"exampleFix":"# before\n[capabilities]\nnetwok = true\n# after\n[capabilities]\nnetwork = true","handlingStrategy":"validation","validationCode":"# check capability names against forge_guide before validating\nforge_guide topic capabilities  # list valid keys, then diff your [capabilities] table","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Copy capability names from forge_guide, never from memory","Run forge validate on every manifest change in CI","Re-validate manifests after forge upgrades (capabilities may be renamed)"],"tags":["manifest","capabilities","validation","config"],"backgroundTag":"invalid-config-value","analyzedSha":"f6f22024fb1e8d122f28a1b4a9f75aee448ae839","analyzedAt":"2026-09-13T03:04:44.565Z","contentChangedAt":"2026-09-13T03:04:44.565Z","schemaVersion":2},"datasetVersion":"2026-09-16T09:17:16.951Z"}