From 4e440e28cdf6d18fb91020f192536955ce3f305e Mon Sep 17 00:00:00 2001 From: Radoslav Dimitrov Date: Thu, 25 Jan 2024 13:50:56 +0200 Subject: [PATCH] Move from rdimitov/go-tuf-metadata to github.com/theupdateframework/go-tuf/v2 Signed-off-by: Radoslav Dimitrov --- examples/cli/tuf-client/cmd/get.go | 6 +++--- examples/cli/tuf-client/cmd/init.go | 4 ++-- examples/cli/tuf-client/main.go | 2 +- examples/cli/tuf/cmd/init.go | 2 +- examples/cli/tuf/main.go | 2 +- examples/client/client_example.go | 6 +++--- examples/multirepo/client/client_example.go | 8 ++++---- examples/multirepo/repository/generate_metadata.go | 4 ++-- examples/repository/basic_repository.go | 4 ++-- go.mod | 2 +- metadata/config/config.go | 2 +- metadata/config/config_test.go | 2 +- metadata/fetcher/fetcher.go | 2 +- metadata/fetcher/fetcher_test.go | 2 +- metadata/metadata_api_test.go | 2 +- metadata/multirepo/multirepo.go | 6 +++--- metadata/repository/repository.go | 2 +- metadata/repository/repository_test.go | 2 +- metadata/trustedmetadata/trustedmetadata.go | 2 +- metadata/trustedmetadata/trustedmetadata_test.go | 4 ++-- metadata/updater/updater.go | 6 +++--- metadata/updater/updater_consistent_snapshot_test.go | 4 ++-- metadata/updater/updater_top_level_update_test.go | 8 ++++---- testutils/simulator/repository_simulator.go | 4 ++-- 24 files changed, 44 insertions(+), 44 deletions(-) diff --git a/examples/cli/tuf-client/cmd/get.go b/examples/cli/tuf-client/cmd/get.go index 57f28927..84771c4d 100644 --- a/examples/cli/tuf-client/cmd/get.go +++ b/examples/cli/tuf-client/cmd/get.go @@ -18,10 +18,10 @@ import ( "path/filepath" "github.com/go-logr/stdr" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/config" - "github.com/rdimitrov/go-tuf-metadata/metadata/updater" "github.com/spf13/cobra" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/config" + "github.com/theupdateframework/go-tuf/v2/metadata/updater" ) var targetsURL string diff --git a/examples/cli/tuf-client/cmd/init.go b/examples/cli/tuf-client/cmd/init.go index 96e975a0..7dc2c101 100644 --- a/examples/cli/tuf-client/cmd/init.go +++ b/examples/cli/tuf-client/cmd/init.go @@ -21,9 +21,9 @@ import ( "path/filepath" "github.com/go-logr/stdr" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/trustedmetadata" "github.com/spf13/cobra" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/trustedmetadata" ) var rootPath string diff --git a/examples/cli/tuf-client/main.go b/examples/cli/tuf-client/main.go index c9bbe611..f38381b0 100644 --- a/examples/cli/tuf-client/main.go +++ b/examples/cli/tuf-client/main.go @@ -12,7 +12,7 @@ package main import ( - tufclient "github.com/rdimitrov/go-tuf-metadata/examples/cli/tuf-client/cmd" + tufclient "github.com/theupdateframework/go-tuf/v2/examples/cli/tuf-client/cmd" ) func main() { diff --git a/examples/cli/tuf/cmd/init.go b/examples/cli/tuf/cmd/init.go index a32dbdfe..4ab1979c 100644 --- a/examples/cli/tuf/cmd/init.go +++ b/examples/cli/tuf/cmd/init.go @@ -17,8 +17,8 @@ import ( "os" "github.com/go-logr/stdr" - "github.com/rdimitrov/go-tuf-metadata/metadata" "github.com/spf13/cobra" + "github.com/theupdateframework/go-tuf/v2/metadata" ) var initCmd = &cobra.Command{ diff --git a/examples/cli/tuf/main.go b/examples/cli/tuf/main.go index 4a61a98d..cec87d48 100644 --- a/examples/cli/tuf/main.go +++ b/examples/cli/tuf/main.go @@ -15,7 +15,7 @@ import ( "fmt" "os" - tuf "github.com/rdimitrov/go-tuf-metadata/examples/cli/tuf/cmd" + tuf "github.com/theupdateframework/go-tuf/v2/examples/cli/tuf/cmd" ) func main() { diff --git a/examples/client/client_example.go b/examples/client/client_example.go index 5652293b..01881ee3 100644 --- a/examples/client/client_example.go +++ b/examples/client/client_example.go @@ -22,9 +22,9 @@ import ( "github.com/go-logr/stdr" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/config" - "github.com/rdimitrov/go-tuf-metadata/metadata/updater" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/config" + "github.com/theupdateframework/go-tuf/v2/metadata/updater" ) // The following config is used to fetch a target from Jussi's GitHub repository example diff --git a/examples/multirepo/client/client_example.go b/examples/multirepo/client/client_example.go index c492c838..ea0f1b2c 100644 --- a/examples/multirepo/client/client_example.go +++ b/examples/multirepo/client/client_example.go @@ -20,10 +20,10 @@ import ( "github.com/go-logr/stdr" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/config" - "github.com/rdimitrov/go-tuf-metadata/metadata/multirepo" - "github.com/rdimitrov/go-tuf-metadata/metadata/updater" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/config" + "github.com/theupdateframework/go-tuf/v2/metadata/multirepo" + "github.com/theupdateframework/go-tuf/v2/metadata/updater" ) const ( diff --git a/examples/multirepo/repository/generate_metadata.go b/examples/multirepo/repository/generate_metadata.go index 1a1c82cb..45e19b53 100644 --- a/examples/multirepo/repository/generate_metadata.go +++ b/examples/multirepo/repository/generate_metadata.go @@ -19,9 +19,9 @@ import ( "strings" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/repository" "github.com/sigstore/sigstore/pkg/signature" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/repository" "golang.org/x/crypto/ed25519" ) diff --git a/examples/repository/basic_repository.go b/examples/repository/basic_repository.go index 39699e7d..bd73e247 100644 --- a/examples/repository/basic_repository.go +++ b/examples/repository/basic_repository.go @@ -22,9 +22,9 @@ import ( "path/filepath" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/repository" "github.com/sigstore/sigstore/pkg/signature" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/repository" "golang.org/x/crypto/ed25519" ) diff --git a/go.mod b/go.mod index f2ff01c6..2617d4af 100644 --- a/go.mod +++ b/go.mod @@ -1,4 +1,4 @@ -module github.com/rdimitrov/go-tuf-metadata +module github.com/theupdateframework/go-tuf/v2 go 1.21.5 diff --git a/metadata/config/config.go b/metadata/config/config.go index f134cc4b..3d04fc7c 100644 --- a/metadata/config/config.go +++ b/metadata/config/config.go @@ -15,7 +15,7 @@ import ( "net/url" "os" - "github.com/rdimitrov/go-tuf-metadata/metadata/fetcher" + "github.com/theupdateframework/go-tuf/v2/metadata/fetcher" ) type UpdaterConfig struct { diff --git a/metadata/config/config_test.go b/metadata/config/config_test.go index 79ea3070..81b85053 100644 --- a/metadata/config/config_test.go +++ b/metadata/config/config_test.go @@ -17,8 +17,8 @@ import ( "path/filepath" "testing" - "github.com/rdimitrov/go-tuf-metadata/metadata/fetcher" "github.com/stretchr/testify/assert" + "github.com/theupdateframework/go-tuf/v2/metadata/fetcher" ) func TestNewUpdaterConfig(t *testing.T) { diff --git a/metadata/fetcher/fetcher.go b/metadata/fetcher/fetcher.go index 635aa6c2..cf32f4c5 100644 --- a/metadata/fetcher/fetcher.go +++ b/metadata/fetcher/fetcher.go @@ -18,7 +18,7 @@ import ( "strconv" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata" ) // Fetcher interface diff --git a/metadata/fetcher/fetcher_test.go b/metadata/fetcher/fetcher_test.go index a7a37e7f..fddc3041 100644 --- a/metadata/fetcher/fetcher_test.go +++ b/metadata/fetcher/fetcher_test.go @@ -16,8 +16,8 @@ import ( "testing" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" "github.com/stretchr/testify/assert" + "github.com/theupdateframework/go-tuf/v2/metadata" ) func TestDownLoadFile(t *testing.T) { diff --git a/metadata/metadata_api_test.go b/metadata/metadata_api_test.go index 5a45c0ce..54682f19 100644 --- a/metadata/metadata_api_test.go +++ b/metadata/metadata_api_test.go @@ -24,10 +24,10 @@ import ( "testing" "time" - testutils "github.com/rdimitrov/go-tuf-metadata/testutils/testutils" "github.com/sigstore/sigstore/pkg/cryptoutils" "github.com/sigstore/sigstore/pkg/signature" "github.com/stretchr/testify/assert" + "github.com/theupdateframework/go-tuf/v2/testutils/testutils" "golang.org/x/sys/unix" ) diff --git a/metadata/multirepo/multirepo.go b/metadata/multirepo/multirepo.go index 019bfadd..03d8986c 100644 --- a/metadata/multirepo/multirepo.go +++ b/metadata/multirepo/multirepo.go @@ -17,9 +17,9 @@ import ( "os" "path/filepath" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/config" - "github.com/rdimitrov/go-tuf-metadata/metadata/updater" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/config" + "github.com/theupdateframework/go-tuf/v2/metadata/updater" "golang.org/x/exp/slices" ) diff --git a/metadata/repository/repository.go b/metadata/repository/repository.go index 85ef55f2..a00ff033 100644 --- a/metadata/repository/repository.go +++ b/metadata/repository/repository.go @@ -12,7 +12,7 @@ package repository import ( - "github.com/rdimitrov/go-tuf-metadata/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata" ) // repositoryType struct for storing metadata diff --git a/metadata/repository/repository_test.go b/metadata/repository/repository_test.go index 06f87a37..a13f222c 100644 --- a/metadata/repository/repository_test.go +++ b/metadata/repository/repository_test.go @@ -15,8 +15,8 @@ import ( "testing" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" "github.com/stretchr/testify/assert" + "github.com/theupdateframework/go-tuf/v2/metadata" ) func TestNewRepository(t *testing.T) { diff --git a/metadata/trustedmetadata/trustedmetadata.go b/metadata/trustedmetadata/trustedmetadata.go index 07924937..4202453a 100644 --- a/metadata/trustedmetadata/trustedmetadata.go +++ b/metadata/trustedmetadata/trustedmetadata.go @@ -15,7 +15,7 @@ import ( "fmt" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata" ) // TrustedMetadata struct for storing trusted metadata diff --git a/metadata/trustedmetadata/trustedmetadata_test.go b/metadata/trustedmetadata/trustedmetadata_test.go index cf5be5ca..3d9765f6 100644 --- a/metadata/trustedmetadata/trustedmetadata_test.go +++ b/metadata/trustedmetadata/trustedmetadata_test.go @@ -18,11 +18,11 @@ import ( "testing" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/testutils/testutils" "github.com/sigstore/sigstore/pkg/cryptoutils" "github.com/sigstore/sigstore/pkg/signature" "github.com/stretchr/testify/assert" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/testutils/testutils" "golang.org/x/exp/maps" ) diff --git a/metadata/updater/updater.go b/metadata/updater/updater.go index d38a049a..4eda9a30 100644 --- a/metadata/updater/updater.go +++ b/metadata/updater/updater.go @@ -24,9 +24,9 @@ import ( "strings" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/config" - "github.com/rdimitrov/go-tuf-metadata/metadata/trustedmetadata" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/config" + "github.com/theupdateframework/go-tuf/v2/metadata/trustedmetadata" ) // Client update workflow implementation diff --git a/metadata/updater/updater_consistent_snapshot_test.go b/metadata/updater/updater_consistent_snapshot_test.go index 67f34d41..cd742476 100644 --- a/metadata/updater/updater_consistent_snapshot_test.go +++ b/metadata/updater/updater_consistent_snapshot_test.go @@ -16,8 +16,8 @@ import ( "github.com/stretchr/testify/assert" - "github.com/rdimitrov/go-tuf-metadata/metadata" - simulator "github.com/rdimitrov/go-tuf-metadata/testutils/simulator" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/testutils/simulator" ) func TestTopLevelRolesUpdateWithConsistentSnapshotDisabled(t *testing.T) { diff --git a/metadata/updater/updater_top_level_update_test.go b/metadata/updater/updater_top_level_update_test.go index 91be6f6b..a14013ab 100644 --- a/metadata/updater/updater_top_level_update_test.go +++ b/metadata/updater/updater_top_level_update_test.go @@ -21,10 +21,10 @@ import ( log "github.com/sirupsen/logrus" "github.com/stretchr/testify/assert" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/config" - simulator "github.com/rdimitrov/go-tuf-metadata/testutils/simulator" - testutils "github.com/rdimitrov/go-tuf-metadata/testutils/testutils" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/config" + "github.com/theupdateframework/go-tuf/v2/testutils/simulator" + "github.com/theupdateframework/go-tuf/v2/testutils/testutils" ) func TestMain(m *testing.M) { diff --git a/testutils/simulator/repository_simulator.go b/testutils/simulator/repository_simulator.go index aa2195f2..3d45b68a 100644 --- a/testutils/simulator/repository_simulator.go +++ b/testutils/simulator/repository_simulator.go @@ -56,10 +56,10 @@ import ( "strings" "time" - "github.com/rdimitrov/go-tuf-metadata/metadata" - "github.com/rdimitrov/go-tuf-metadata/metadata/fetcher" "github.com/sigstore/sigstore/pkg/signature" log "github.com/sirupsen/logrus" + "github.com/theupdateframework/go-tuf/v2/metadata" + "github.com/theupdateframework/go-tuf/v2/metadata/fetcher" ) var SPEC_VER = "." + metadata.SPECIFICATION_VERSION