Skip to content
This repository has been archived by the owner on Nov 8, 2022. It is now read-only.

Commit

Permalink
Add checking if signature file exists if plugin trust level is set to…
Browse files Browse the repository at this point in the history
… warn
  • Loading branch information
geauxvirtual committed Oct 27, 2015
1 parent 553790d commit 5fc3a87
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion control/control.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ package control
import (
"errors"
"fmt"
"os"
"strconv"
"strings"
"sync"
Expand Down Expand Up @@ -277,7 +278,7 @@ func (p *pluginControl) Load(files ...string) (core.CatalogedPlugin, perror.Puls
}
signed = true
case PluginTrustWarn:
if signatureFile == "" {
if _, err := os.Stat(signatureFile); err != nil {
signed = false
controlLogger.WithFields(f).Warn("Loading unsigned plugin ", pluginPath)
} else {
Expand Down

0 comments on commit 5fc3a87

Please sign in to comment.