aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/github.com/dexon-foundation/mcl/ffi/java/elgamal.i
diff options
context:
space:
mode:
authorWei-Ning Huang <w@dexon.org>2019-04-11 18:32:33 +0800
committerWei-Ning Huang <w@byzantine-lab.io>2019-06-15 22:09:55 +0800
commit21ac6a5ed287112f685174b482d36392c594f0e8 (patch)
treef36d198fdee235aac353ae32b8d927890bcae060 /vendor/github.com/dexon-foundation/mcl/ffi/java/elgamal.i
parent67637a63cab266b30d2a634bb8039bd7ff1ae335 (diff)
downloadgo-tangerine-21ac6a5ed287112f685174b482d36392c594f0e8.tar.gz
go-tangerine-21ac6a5ed287112f685174b482d36392c594f0e8.tar.zst
go-tangerine-21ac6a5ed287112f685174b482d36392c594f0e8.zip
vendor: use BLS-12_384 curve and update dependencies (#356)
Diffstat (limited to 'vendor/github.com/dexon-foundation/mcl/ffi/java/elgamal.i')
-rw-r--r--vendor/github.com/dexon-foundation/mcl/ffi/java/elgamal.i28
1 files changed, 28 insertions, 0 deletions
diff --git a/vendor/github.com/dexon-foundation/mcl/ffi/java/elgamal.i b/vendor/github.com/dexon-foundation/mcl/ffi/java/elgamal.i
new file mode 100644
index 000000000..410723174
--- /dev/null
+++ b/vendor/github.com/dexon-foundation/mcl/ffi/java/elgamal.i
@@ -0,0 +1,28 @@
+%module Elgamal
+
+%include "std_string.i"
+%include "std_except.i"
+
+
+%{
+#include <cybozu/random_generator.hpp>
+#include <cybozu/crypto.hpp>
+#include <mcl/fp.hpp>
+#include <mcl/ecparam.hpp>
+struct Param {
+const mcl::EcParam *ecParam;
+cybozu::RandomGenerator rg;
+cybozu::crypto::Hash::Name hashName;
+static inline Param& getParam()
+{
+ static Param p;
+ return p;
+}
+};
+
+#include "elgamal_impl.hpp"
+%}
+%include cpointer.i
+%pointer_functions(bool, p_bool);
+
+%include "elgamal_impl.hpp"