summaryrefslogtreecommitdiff
path: root/internal/speed
diff options
context:
space:
mode:
authorJakob Unterwurzacher2021-09-07 18:11:11 +0200
committerJakob Unterwurzacher2021-09-07 18:15:04 +0200
commit85c2beccaf674c69b3e30b0d646f5c11d91ecb9b (patch)
tree6e3efb67d7461b7df3e332c1ebe83691958a2dba /internal/speed
parentf47e287c202ba92e9b48e65bf95e0771c6c4997c (diff)
stupidgcm: normalize constructor naming
New() -> NewAES256GCM() Also add missing NewChacha20poly1305 constructor in without_openssl.go.
Diffstat (limited to 'internal/speed')
-rw-r--r--internal/speed/speed.go2
-rw-r--r--internal/speed/speed_test.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/internal/speed/speed.go b/internal/speed/speed.go
index a696703..2f818d0 100644
--- a/internal/speed/speed.go
+++ b/internal/speed/speed.go
@@ -116,7 +116,7 @@ func bStupidGCM(b *testing.B) {
if stupidgcm.BuiltWithoutOpenssl {
b.Skip("openssl has been disabled at compile-time")
}
- bEncrypt(b, stupidgcm.New(randBytes(32), false))
+ bEncrypt(b, stupidgcm.NewAES256GCM(randBytes(32), false))
}
// bGoGCM benchmarks Go stdlib GCM
diff --git a/internal/speed/speed_test.go b/internal/speed/speed_test.go
index e9bbc0d..11c68d0 100644
--- a/internal/speed/speed_test.go
+++ b/internal/speed/speed_test.go
@@ -31,7 +31,7 @@ func BenchmarkStupidGCMDecrypt(b *testing.B) {
if stupidgcm.BuiltWithoutOpenssl {
b.Skip("openssl has been disabled at compile-time")
}
- bDecrypt(b, stupidgcm.New(randBytes(32), false))
+ bDecrypt(b, stupidgcm.NewAES256GCM(randBytes(32), false))
}
func BenchmarkGoGCM(b *testing.B) {