Commit 6d7e1035 authored by Nico's avatar Nico
Browse files

Use default random provider on Windows

parent 32686811
Pipeline #7508 failed with stages
in 58 seconds
package org.briarproject.bramble.system;
import javax.annotation.Nullable;
public class WindowsSecureRandomProvider extends AbstractSecureRandomProvider {
public Provider getProvider() {
return null;
......@@ -9,6 +9,7 @@ import dagger.Provides;
import static org.briarproject.bramble.util.OsUtils.isLinux;
import static org.briarproject.bramble.util.OsUtils.isMac;
import static org.briarproject.bramble.util.OsUtils.isWindows;
public class DesktopSecureRandomModule {
......@@ -18,7 +19,8 @@ public class DesktopSecureRandomModule {
SecureRandomProvider provideSecureRandomProvider() {
if (isLinux() || isMac())
return new UnixSecureRandomProvider();
// TODO: Create a secure random provider for Windows
if (isWindows())
return new WindowsSecureRandomProvider();
throw new UnsupportedOperationException();
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment