From 553790d182a10ef6de00ed4a44c1cc5e95b58783 Mon Sep 17 00:00:00 2001 From: geauxvirtual Date: Mon, 26 Oct 2015 14:17:35 -0700 Subject: [PATCH] Add check to only continue with loading a plugin if only two files were passed to control.Load --- control/control.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/control/control.go b/control/control.go index 84aab9e65..eb77eea0e 100644 --- a/control/control.go +++ b/control/control.go @@ -254,6 +254,9 @@ func (p *pluginControl) Load(files ...string) (core.CatalogedPlugin, perror.Puls f := map[string]interface{}{ "_block": "load", } + if len(files) > 2 { + return nil, perror.New(errors.New("Load plugin limited to a single plugin plus signature file if plugin is signed")) + } //Check plugin signing var signed bool