public void WhenInitialisationIsPerformed() { const CipherSuiteName cipherSuiteName = CipherSuiteName.Ristretto255_SHA512; PrimeOrderGroupFactory pogFactory = new(); HashFunctionFactory hfFactory = new(); CipherSuite cipherSuite = new CipherSuite(cipherSuiteName, ProtocolMode.Base, pogFactory, hfFactory); SodiumLibrary.InitialiseCryptography(); LogAssert.AreEqual("Sodium library version", "1.0.18", SodiumLibrary.GetSodiumLibraryVersion()); BaseModeClientContext clientContext = new(cipherSuite); BaseModeServerContext serverContext = new(cipherSuite); }
public void BeforeScenario() { SodiumLibrary.InitialiseCryptography(); _cipherSuiteName = CipherSuiteName.Ristretto255_SHA512; PrimeOrderGroupFactory pogFactory = new(); HashFunctionFactory hfFactory = new(); _cipherSuite = new CipherSuite(_cipherSuiteName, ProtocolMode.Base, pogFactory, hfFactory); _pog = _cipherSuite.PrimeOrderGroup; _clientContext = new(_cipherSuite); _serverContext = new(_cipherSuite); }