added example directory for lib import exmples
sophuwu sophie@skisiel.com
Sat, 07 Sep 2024 12:56:00 +0200
2 files changed,
27 insertions(+),
0 deletions(-)
A
example/encrypt.go
@@ -0,0 +1,18 @@
+package main + +import ( + "sophuwu.site/seks" +) + +const pk = "public-key-158d1a9fe9c919964e516fdbd55a27961ee56c91598d3691ab380e3f49d49f75" +const sk = "SECRET-KEY-0D24C35A60E967F965D483C4D330975A2BABD0087B2938B9F2F07393F6CB8E53" + +func main() { + println(pk + "\n" + sk) + b := []byte("uwu") + println("message:\n" + string(b)) + b, _ = seks.EncryptArmour(b, pk, sk) + println("encryption:\n" + string(b)) + b, _ = seks.DecryptArmour(b, pk, sk) + println("decrypted message:\n" + string(b)) +}
A
example/keygen.go
@@ -0,0 +1,9 @@
+package main + +import "sophuwu.site/seks" + +func main() { + pub, priv := seks.KeyGen() + println(pub) + println(priv) +}