diff --git a/cmd/cli/kubectl-kyverno/jp/jp_command.go b/cmd/cli/kubectl-kyverno/jp/jp_command.go index 5d9b5c7a0d..b3f71cc9c9 100644 --- a/cmd/cli/kubectl-kyverno/jp/jp_command.go +++ b/cmd/cli/kubectl-kyverno/jp/jp_command.go @@ -59,7 +59,7 @@ func Command() *cobra.Command { } var input interface{} if filename != "" { - f, err := ioutil.ReadFile(filename) + f, err := ioutil.ReadFile(filepath.Clean(filename)) if err != nil { return fmt.Errorf("error opening input file: %w", err) }