From 2e989e6d7c539981727dd4b13da4e62de21fd195 Mon Sep 17 00:00:00 2001 From: MITSUNARI Shigeo Date: Fri, 24 Jul 2020 20:48:41 +0900 Subject: [PATCH] [C#] how to init for ETH --- ffi/cs/readme.md | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/ffi/cs/readme.md b/ffi/cs/readme.md index a9872a7..9fcae91 100644 --- a/ffi/cs/readme.md +++ b/ffi/cs/readme.md @@ -8,8 +8,17 @@ cd mcl mklib dll ``` -Open `ffi/cs/mcl.sln` and Set the directory of `mcl/bin` to `workingDirectory` at `Debug` of test project. +Open `mcl/ffi/cs/mcl.sln` and Set the directory of `mcl/bin` to `workingDirectory` at `Debug` of test project. # Remark - `bn256.cs` is an old code. It will be removed in the future. -- `mcl/mcl.cs` is a new version. It support `BN254`, `BN_SNARK` and `BLS12_381` curve, which requires `mclbn384_256.dll`. \ No newline at end of file +- `mcl/mcl.cs` is a new version. It support `BN254`, `BN_SNARK` and `BLS12_381` curve, which requires `mclbn384_256.dll`. + +# `ETHmode` with `BLS12_381` + +If you need the map-to-G1/G2 function defined in [Hashing to Elliptic Curves](https://www.ietf.org/id/draft-irtf-cfrg-hash-to-curve-09.html), +then initialize this library as the followings: +``` +MCL.Init(BLS12_381); +MCL.ETHmode(); +```