File tree Expand file tree Collapse file tree 4 files changed +15
-8
lines changed
Expand file tree Collapse file tree 4 files changed +15
-8
lines changed Original file line number Diff line number Diff line change @@ -198,7 +198,8 @@ func TestDeltaECDSWasmConversion(t *testing.T) {
198198 t .Fatalf ("wasm config conversion output %v failed to unmarshal" , gotResp .Resources [0 ])
199199 }
200200 httpDenyAll := & httprbac.RBAC {
201- Rules : & rbacv3.RBAC {},
201+ Rules : & rbacv3.RBAC {},
202+ RulesStatPrefix : "wasm-default-deny" ,
202203 }
203204 wantEcdsConfig = & core.TypedExtensionConfig {
204205 Name : "extension-config" ,
Original file line number Diff line number Diff line change @@ -538,7 +538,8 @@ func TestECDSWasmConversion(t *testing.T) {
538538 t .Fatalf ("wasm config conversion output %v failed to unmarshal" , gotResp .Resources [0 ])
539539 }
540540 httpDenyAll := & httprbac.RBAC {
541- Rules : & rbacv3.RBAC {},
541+ Rules : & rbacv3.RBAC {},
542+ RulesStatPrefix : "wasm-default-deny" ,
542543 }
543544 wantEcdsConfig = & core.TypedExtensionConfig {
544545 Name : "extension-config" ,
Original file line number Diff line number Diff line change @@ -38,13 +38,15 @@ import (
3838)
3939
4040var (
41- allowHTTPTypedConfig = & anypb.Any {
42- TypeUrl : "type.googleapis.com/envoy.extensions.filters.http.rbac.v3.RBAC" ,
41+ allowHTTPTypedConfig , _ = anypb .New (& httprbac.RBAC {
4342 // no rules mean allow all.
44- }
43+ RulesStatPrefix : "wasm-default-allow" ,
44+ })
45+
4546 denyHTTPTypedConfig , _ = anypb .New (& httprbac.RBAC {
4647 // empty rule means deny all.
47- Rules : & rbacv3.RBAC {},
48+ Rules : & rbacv3.RBAC {},
49+ RulesStatPrefix : "wasm-default-deny" ,
4850 })
4951
5052 allowNetworkTypeConfig , _ = anypb .New (& networkrbac.RBAC {
Original file line number Diff line number Diff line change @@ -479,9 +479,12 @@ var extensionConfigMap = map[string]*core.TypedExtensionConfig{
479479 FailOpen : true ,
480480 },
481481 }),
482- "remote-load-allow" : buildAnyExtensionConfig ("remote-load-fail" , & rbac.RBAC {}),
482+ "remote-load-allow" : buildAnyExtensionConfig ("remote-load-fail" , & rbac.RBAC {
483+ RulesStatPrefix : "wasm-default-allow" ,
484+ }),
483485 "remote-load-deny" : buildAnyExtensionConfig ("remote-load-fail" , & rbac.RBAC {
484- Rules : & rbacv3.RBAC {},
486+ Rules : & rbacv3.RBAC {},
487+ RulesStatPrefix : "wasm-default-deny" ,
485488 }),
486489 "remote-load-secret" : buildTypedStructExtensionConfig ("remote-load-success" , & wasm.Wasm {
487490 Config : & v3.PluginConfig {
You can’t perform that action at this time.
0 commit comments