feat(m0.6-r2): complete-name plugin exports and capability broker
- register every plugin export by its complete dotted name; reject conflicting loads atomically instead of overwriting the first namespace - route plugin calls by full export name and expose loaded descriptors to the runtime - add CapabilityBroker for core grants and vendor policy, with audit records - accept syntactically valid vendor capability requests in manifests while still denying them until a trusted policy exists - add check --plugin static signature validation without dlopen - test multi-export C plugin routing, conflict rollback, broker decisions and static arity rejection
This commit is contained in:
1 parent
21c1e50617
commit
d940013f35
13 files changed
+826
-94
No files matched your search
@@ -664,8 +664,8 @@ fn plugin_inspect_and_explicit_trusted_invocation() {
|
||||
assert_exit(&unknown, 1, "unknown plugin namespace");
|
||||
assert!(stderr_text(&unknown).contains("symbol.unknown"));
|
||||
|
||||
// The export signature requires both named arguments: a missing argument
|
||||
// becomes a structured plugin failure, never a panic.
|
||||
// The export signature requires both named arguments: with a declared
|
||||
// plugin manifest this is rejected statically, before any library load.
|
||||
dir.write("args.mq.md", "## main\n\n**结果 = solver.add(a=1)**\n");
|
||||
let bad_args = cli(
|
||||
dir.path(),
|
||||
@@ -680,5 +680,6 @@ fn plugin_inspect_and_explicit_trusted_invocation() {
|
||||
],
|
||||
);
|
||||
assert_exit(&bad_args, 1, "plugin argument failure");
|
||||
assert!(stderr_text(&bad_args).contains("plugin.failure"));
|
||||
assert!(stderr_text(&bad_args).contains("call.arity"));
|
||||
assert!(stderr_text(&bad_args).contains("missing required argument `b`"));
|
||||
}
|
||||
Reference in new issue
Block a user