From ce5ce803015d98d2996725cee511a4edee76bf8a Mon Sep 17 00:00:00 2001 From: Komu Wairagu Date: Thu, 1 Jun 2023 14:37:32 +0300 Subject: [PATCH] Change attest import path (#265) --- CHANGELOG.md | 5 ++++- automax/automaxcpu_test.go | 2 +- automax/automaxmem_test.go | 2 +- client/client_test.go | 2 +- cookie/cookie_test.go | 2 +- cry/enc_test.go | 2 +- cry/hash_test.go | 2 +- errors/errors_test.go | 2 +- example/integration_test.go | 2 +- go.mod | 2 +- go.sum | 4 ++-- id/id_test.go | 2 +- internal/clientip/client_ip_test.go | 2 +- log/log_test.go | 2 +- middleware/auth_test.go | 2 +- middleware/client_ip_test.go | 2 +- middleware/cors_test.go | 2 +- middleware/csrf_test.go | 2 +- middleware/gzip_test.go | 2 +- middleware/loadshed_test.go | 2 +- middleware/log_test.go | 2 +- middleware/middleware_test.go | 2 +- middleware/ratelimiter_test.go | 2 +- middleware/recoverer_test.go | 2 +- middleware/redirect_test.go | 2 +- middleware/reload_protect_test.go | 2 +- middleware/security_test.go | 2 +- middleware/session_test.go | 2 +- middleware/trace_test.go | 2 +- mux/mux_test.go | 2 +- mux/route_test.go | 2 +- server/cert_test.go | 2 +- server/pprof_test.go | 2 +- server/server_test.go | 2 +- server/tls_conf_test.go | 2 +- sess/sess_test.go | 2 +- 36 files changed, 40 insertions(+), 37 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5b5f4fb2..abfe48d4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,9 @@ Most recent version is listed first. +## v0.0.48 +- Change attest import path: https://github.com/komuw/ong/pull/265 + ## v0.0.47 - Leave http.server.DisableGeneralOptionsHandler at its default value: https://github.com/komuw/ong/pull/255 - Validate expiry of csrf tokens: https://github.com/komuw/ong/pull/257 @@ -220,7 +223,7 @@ ClientIP, use remoteAddress if IP is local adress: https://github.com/komuw/ong/ - pass logger as an arg to the middlewares: https://github.com/komuw/ong/pull/84 - disable gzip: https://github.com/komuw/ong/pull/86 - a more efficient error stack trace: https://github.com/komuw/ong/pull/87 -- update github.com/akshayjshah/attest: https://github.com/komuw/ong/pull/93 +- update go.akshayshah.org/attest: https://github.com/komuw/ong/pull/93 - update to Go 1.19: https://github.com/komuw/ong/pull/102 - remove rlimit code, go1.19 does automatically: https://github.com/komuw/ong/pull/104 - automatically set GOMEMLIMIT in container environments: https://github.com/komuw/ong/pull/105 diff --git a/automax/automaxcpu_test.go b/automax/automaxcpu_test.go index b463fea6..33c19f5c 100644 --- a/automax/automaxcpu_test.go +++ b/automax/automaxcpu_test.go @@ -5,7 +5,7 @@ import ( "os" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func TestSetCpu(t *testing.T) { diff --git a/automax/automaxmem_test.go b/automax/automaxmem_test.go index 9169581a..609db23d 100644 --- a/automax/automaxmem_test.go +++ b/automax/automaxmem_test.go @@ -6,7 +6,7 @@ import ( "os" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" ) diff --git a/client/client_test.go b/client/client_test.go index db52e0b9..f823d40c 100644 --- a/client/client_test.go +++ b/client/client_test.go @@ -9,7 +9,7 @@ import ( "github.com/komuw/ong/log" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" "golang.org/x/exp/slog" ) diff --git a/cookie/cookie_test.go b/cookie/cookie_test.go index 4a1b5c6d..455523b4 100644 --- a/cookie/cookie_test.go +++ b/cookie/cookie_test.go @@ -7,7 +7,7 @@ import ( "testing" "time" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" ) diff --git a/cry/enc_test.go b/cry/enc_test.go index 6086827c..2fd87854 100644 --- a/cry/enc_test.go +++ b/cry/enc_test.go @@ -4,7 +4,7 @@ import ( "sync" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" "golang.org/x/exp/slices" ) diff --git a/cry/hash_test.go b/cry/hash_test.go index 5ad11dc9..3b8270d6 100644 --- a/cry/hash_test.go +++ b/cry/hash_test.go @@ -4,7 +4,7 @@ import ( "strings" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func TestHash(t *testing.T) { diff --git a/errors/errors_test.go b/errors/errors_test.go index 0e983a0e..e5d3361a 100644 --- a/errors/errors_test.go +++ b/errors/errors_test.go @@ -7,7 +7,7 @@ import ( "os" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" ) diff --git a/example/integration_test.go b/example/integration_test.go index 007584b3..c0002766 100644 --- a/example/integration_test.go +++ b/example/integration_test.go @@ -10,8 +10,8 @@ import ( "testing" "time" - "github.com/akshayjshah/attest" vegeta "github.com/tsenart/vegeta/v12/lib" + "go.akshayshah.org/attest" ) // This tests depend on the functionality in the /example folder. diff --git a/go.mod b/go.mod index ef1b2c85..b389b09d 100644 --- a/go.mod +++ b/go.mod @@ -25,12 +25,12 @@ require ( require ( github.com/NYTimes/gziphandler v1.1.1 // test - github.com/akshayjshah/attest v0.4.0 // test github.com/klauspost/compress v1.16.5 // test github.com/rs/zerolog v1.29.1 // test github.com/sirupsen/logrus v1.9.2 // test github.com/tmthrgd/gziphandler v0.0.0-20210130054451-9e3dc377f14f // test github.com/tsenart/vegeta/v12 v12.8.4 // test + go.akshayshah.org/attest v1.0.2 // test go.uber.org/goleak v1.2.1 // test go.uber.org/zap v1.24.0 // test ) diff --git a/go.sum b/go.sum index dfed2786..4120966b 100644 --- a/go.sum +++ b/go.sum @@ -1,7 +1,5 @@ github.com/NYTimes/gziphandler v1.1.1 h1:ZUDjpQae29j0ryrS0u/B8HZfJBtBQHjqw2rQ2cqUQ3I= github.com/NYTimes/gziphandler v1.1.1/go.mod h1:n/CVRwUEOgIxrgPvAQhUUr9oeUtvrhMomdKFjzJNB0c= -github.com/akshayjshah/attest v0.4.0 h1:WsUC9HOLWNx+enIGN1Zb3HDx0d6v9K2ZSRdwZkWsN+I= -github.com/akshayjshah/attest v0.4.0/go.mod h1:xOHx7YBQ1aDFYNp9OpICMPKJrI+YidFSmHx412ptvsc= github.com/alecthomas/jsonschema v0.0.0-20180308105923-f2c93856175a/go.mod h1:qpebaTNSsyUn5rPSJMsfqEtDw71TTggXM6stUDI16HA= github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8= github.com/bmizerany/perks v0.0.0-20141205001514-d9a9656a3a4b h1:AP/Y7sqYicnjGDfD5VcY4CIfh1hRXBUavxrvELjTiOE= @@ -67,6 +65,8 @@ github.com/tmthrgd/httputils v0.0.0-20190904060602-27fdf7d93acd/go.mod h1:8/hVmI github.com/tsenart/go-tsz v0.0.0-20180814232043-cdeb9e1e981e/go.mod h1:SWZznP1z5Ki7hDT2ioqiFKEse8K9tU2OUvaRI0NeGQo= github.com/tsenart/vegeta/v12 v12.8.4 h1:UQ7tG7WkDorKj0wjx78Z4/vsMBP8RJQMGJqRVrkvngg= github.com/tsenart/vegeta/v12 v12.8.4/go.mod h1:ZiJtwLn/9M4fTPdMY7bdbIeyNeFVE8/AHbWFqCsUuho= +go.akshayshah.org/attest v1.0.2 h1:qOv9PXCG2mwnph3g0I3yZj0rLAwLyUITs8nhxP+wS44= +go.akshayshah.org/attest v1.0.2/go.mod h1:PnWzcW5j9dkyGwTlBmUsYpPnHG0AUPrs1RQ+HrldWO0= go.uber.org/atomic v1.11.0 h1:ZvwS0R+56ePWxUNi+Atn9dWONBPp/AUETXlHW0DxSjE= go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0= go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A= diff --git a/id/id_test.go b/id/id_test.go index 50997d82..64c1110a 100644 --- a/id/id_test.go +++ b/id/id_test.go @@ -4,7 +4,7 @@ import ( "math" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" "golang.org/x/exp/slices" ) diff --git a/internal/clientip/client_ip_test.go b/internal/clientip/client_ip_test.go index 328deab3..37c668f8 100644 --- a/internal/clientip/client_ip_test.go +++ b/internal/clientip/client_ip_test.go @@ -6,7 +6,7 @@ import ( "net/http/httptest" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" ) diff --git a/log/log_test.go b/log/log_test.go index 38285612..6548f2c9 100644 --- a/log/log_test.go +++ b/log/log_test.go @@ -13,7 +13,7 @@ import ( ongErrors "github.com/komuw/ong/errors" "github.com/komuw/ong/internal/octx" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" "golang.org/x/exp/slog" ) diff --git a/middleware/auth_test.go b/middleware/auth_test.go index 57b48c0c..d0f01e4d 100644 --- a/middleware/auth_test.go +++ b/middleware/auth_test.go @@ -9,7 +9,7 @@ import ( "sync" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func protectedHandler(msg string) http.HandlerFunc { diff --git a/middleware/client_ip_test.go b/middleware/client_ip_test.go index bdfbb4cc..5339b655 100644 --- a/middleware/client_ip_test.go +++ b/middleware/client_ip_test.go @@ -8,7 +8,7 @@ import ( "sync" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) const ( diff --git a/middleware/cors_test.go b/middleware/cors_test.go index ed25ecac..e61dc4e8 100644 --- a/middleware/cors_test.go +++ b/middleware/cors_test.go @@ -8,7 +8,7 @@ import ( "sync" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func someCorsHandler(msg string) http.HandlerFunc { diff --git a/middleware/csrf_test.go b/middleware/csrf_test.go index 068e01dd..8033f01b 100644 --- a/middleware/csrf_test.go +++ b/middleware/csrf_test.go @@ -14,7 +14,7 @@ import ( "github.com/komuw/ong/cry" "github.com/komuw/ong/id" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func getSecretKey() string { diff --git a/middleware/gzip_test.go b/middleware/gzip_test.go index e7080029..93805d3f 100644 --- a/middleware/gzip_test.go +++ b/middleware/gzip_test.go @@ -12,7 +12,7 @@ import ( "sync" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" nytimes "github.com/NYTimes/gziphandler" klauspost "github.com/klauspost/compress/gzhttp" diff --git a/middleware/loadshed_test.go b/middleware/loadshed_test.go index c4a070de..9fb1af6f 100644 --- a/middleware/loadshed_test.go +++ b/middleware/loadshed_test.go @@ -11,7 +11,7 @@ import ( "testing" "time" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) const loadShedderTestHeader = "LoadShedderTestHeader" diff --git a/middleware/log_test.go b/middleware/log_test.go index 07cdf1c3..e8213bdc 100644 --- a/middleware/log_test.go +++ b/middleware/log_test.go @@ -14,7 +14,7 @@ import ( "github.com/komuw/ong/id" "github.com/komuw/ong/log" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "golang.org/x/exp/slog" ) diff --git a/middleware/middleware_test.go b/middleware/middleware_test.go index c6e63d10..5d76a0d6 100644 --- a/middleware/middleware_test.go +++ b/middleware/middleware_test.go @@ -16,7 +16,7 @@ import ( "github.com/komuw/ong/log" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" ) diff --git a/middleware/ratelimiter_test.go b/middleware/ratelimiter_test.go index 30d6e2a5..588228c6 100644 --- a/middleware/ratelimiter_test.go +++ b/middleware/ratelimiter_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "golang.org/x/exp/slices" ) diff --git a/middleware/recoverer_test.go b/middleware/recoverer_test.go index fc9effa8..028c09ad 100644 --- a/middleware/recoverer_test.go +++ b/middleware/recoverer_test.go @@ -15,7 +15,7 @@ import ( "github.com/komuw/ong/errors" "github.com/komuw/ong/log" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "golang.org/x/exp/slog" ) diff --git a/middleware/redirect_test.go b/middleware/redirect_test.go index c669145a..0e89b1aa 100644 --- a/middleware/redirect_test.go +++ b/middleware/redirect_test.go @@ -10,7 +10,7 @@ import ( "sync" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func someHttpsRedirectorHandler(msg string) http.HandlerFunc { diff --git a/middleware/reload_protect_test.go b/middleware/reload_protect_test.go index d455dcb8..bef3918f 100644 --- a/middleware/reload_protect_test.go +++ b/middleware/reload_protect_test.go @@ -8,7 +8,7 @@ import ( "sync" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func someReloadProtectorHandler(msg, expectedFormName, expectedFormValue string) http.HandlerFunc { diff --git a/middleware/security_test.go b/middleware/security_test.go index b95c6a43..6bad00a3 100644 --- a/middleware/security_test.go +++ b/middleware/security_test.go @@ -10,7 +10,7 @@ import ( "testing" "time" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) const nonceHeader = "CUSTOM-CSP-NONCE-TEST-HEADER" diff --git a/middleware/session_test.go b/middleware/session_test.go index eaffd16a..b444e728 100644 --- a/middleware/session_test.go +++ b/middleware/session_test.go @@ -12,7 +12,7 @@ import ( "github.com/komuw/ong/cookie" "github.com/komuw/ong/sess" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func bigMap() map[string]string { diff --git a/middleware/trace_test.go b/middleware/trace_test.go index 8b69272a..9c919b80 100644 --- a/middleware/trace_test.go +++ b/middleware/trace_test.go @@ -13,7 +13,7 @@ import ( "github.com/komuw/ong/id" "github.com/komuw/ong/internal/octx" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) const someTraceHandlerHeader = "someTraceHandlerHeader" diff --git a/mux/mux_test.go b/mux/mux_test.go index 8cbae99e..0e9902d6 100644 --- a/mux/mux_test.go +++ b/mux/mux_test.go @@ -13,7 +13,7 @@ import ( "github.com/komuw/ong/log" "github.com/komuw/ong/middleware" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" ) diff --git a/mux/route_test.go b/mux/route_test.go index 360e8691..ae4379fb 100644 --- a/mux/route_test.go +++ b/mux/route_test.go @@ -8,7 +8,7 @@ import ( "net/http/httptest" "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func TestRouter(t *testing.T) { diff --git a/server/cert_test.go b/server/cert_test.go index d38996ab..5b93fd84 100644 --- a/server/cert_test.go +++ b/server/cert_test.go @@ -8,7 +8,7 @@ import ( "github.com/komuw/ong/log" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func TestCreateDevCertKey(t *testing.T) { diff --git a/server/pprof_test.go b/server/pprof_test.go index 5c0ab317..d289d857 100644 --- a/server/pprof_test.go +++ b/server/pprof_test.go @@ -11,7 +11,7 @@ import ( "github.com/komuw/ong/log" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func TestPprofServer(t *testing.T) { diff --git a/server/server_test.go b/server/server_test.go index 7eb7d572..aafc08ee 100644 --- a/server/server_test.go +++ b/server/server_test.go @@ -19,7 +19,7 @@ import ( "github.com/komuw/ong/middleware" "github.com/komuw/ong/mux" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) func getSecretKey() string { diff --git a/server/tls_conf_test.go b/server/tls_conf_test.go index d829e0c0..a9b06c29 100644 --- a/server/tls_conf_test.go +++ b/server/tls_conf_test.go @@ -3,7 +3,7 @@ package server import ( "testing" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" ) // taken from https://github.com/golang/crypto/blob/05595931fe9d3f8894ab063e1981d28e9873e2cb/acme/autocert/autocert_test.go#L672 diff --git a/sess/sess_test.go b/sess/sess_test.go index 5b5e3438..8c9cb7fa 100644 --- a/sess/sess_test.go +++ b/sess/sess_test.go @@ -6,7 +6,7 @@ import ( "testing" "time" - "github.com/akshayjshah/attest" + "go.akshayshah.org/attest" "go.uber.org/goleak" )