mirror of
https://github.com/project-zot/zot.git
synced 2026-06-16 04:17:55 +08:00
fix: add support for uploaded index when signing using notation (#1882)
ci(notation): update to latest notation version fix(sync): add layers info when syncing signatures Signed-off-by: Andreea-Lupu <andreealupu1470@yahoo.com>
This commit is contained in:
@@ -6,6 +6,7 @@ import (
|
||||
"fmt"
|
||||
"io/fs"
|
||||
"os"
|
||||
"regexp"
|
||||
"strings"
|
||||
"syscall"
|
||||
"time"
|
||||
@@ -119,3 +120,11 @@ func ContainsStringIgnoreCase(strSlice []string, str string) bool {
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// this function will check if tag is a referrers tag
|
||||
// (https://github.com/opencontainers/distribution-spec/blob/main/spec.md#referrers-tag-schema).
|
||||
func IsReferrersTag(tag string) bool {
|
||||
referrersTagRule := regexp.MustCompile(`sha256\-[A-Za-z0-9]*$`)
|
||||
|
||||
return referrersTagRule.MatchString(tag)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user