summaryrefslogtreecommitdiff
path: root/internal/stupidgcm/stupidgcm.go
diff options
context:
space:
mode:
authorJakob Unterwurzacher2016-10-04 09:51:14 +0200
committerJakob Unterwurzacher2016-10-04 09:51:14 +0200
commit56c0b19612dd25b84474211c1a84897fe89ce7d4 (patch)
tree7eeaa30a90f9cbcc75b7c91853b759f4eb7c034a /internal/stupidgcm/stupidgcm.go
parenta00402cc47d245355c6556a17a1cacaf5102a31c (diff)
without_openssl: support compiling completely without openssl
Build helper script: build-without-openssl.bash
Diffstat (limited to 'internal/stupidgcm/stupidgcm.go')
-rw-r--r--internal/stupidgcm/stupidgcm.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/internal/stupidgcm/stupidgcm.go b/internal/stupidgcm/stupidgcm.go
index 0f4e25d..db9e6ef 100644
--- a/internal/stupidgcm/stupidgcm.go
+++ b/internal/stupidgcm/stupidgcm.go
@@ -1,3 +1,5 @@
+// +build !without_openssl
+
// Package stupidgcm is a thin wrapper for OpenSSL's GCM encryption and
// decryption functions. It only support 32-byte keys and 16-bit IVs.
package stupidgcm
@@ -13,6 +15,9 @@ import (
)
const (
+ // Has openssl been disabled at compile-time?
+ BuiltWithoutOpenssl = false
+
keyLen = 32
ivLen = 16
tagLen = 16