Skip to content
This repository has been archived by the owner on May 21, 2020. It is now read-only.

Dependency updates #3

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 17 additions & 9 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,23 @@
</license>
</licenses>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<junit.version>5.6.2</junit.version>
<bouncycastle.version>1.65</bouncycastle.version>
</properties>

<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.8.2</version>
<scope>test</scope>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.bouncycastle</groupId>
<artifactId>bcprov-jdk15on</artifactId>
<version>1.48</version>
<version>${bouncycastle.version}</version>
</dependency>
</dependencies>

Expand All @@ -57,10 +63,12 @@
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>4.2.1</version>
<extensions>true</extensions>
</plugin>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M4</version>
</plugin>
</plugins>
</build>
Expand All @@ -79,7 +87,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>2.2.1</version>
<version>3.2.1</version>
<executions>
<execution>
<id>attach-sources</id>
Expand All @@ -92,7 +100,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>2.9.1</version>
<version>3.2.0</version>
<executions>
<execution>
<id>attach-javadocs</id>
Expand All @@ -105,7 +113,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>1.5</version>
<version>1.6</version>
<executions>
<execution>
<id>sign-artifacts</id>
Expand All @@ -119,7 +127,7 @@
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.6.3</version>
<version>1.6.8</version>
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/org/jitsi/bccontrib/prng/FortunaGenerator.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import org.bouncycastle.crypto.Digest;
import org.bouncycastle.crypto.BlockCipher;
import org.bouncycastle.crypto.digests.SHA256Digest;
import org.bouncycastle.crypto.engines.AESFastEngine;
import org.bouncycastle.crypto.engines.AESEngine;
import org.bouncycastle.crypto.params.KeyParameter;
import org.bouncycastle.crypto.prng.RandomGenerator;

Expand Down Expand Up @@ -159,7 +159,7 @@ public FortunaGenerator() {
}

public FortunaGenerator(byte[] seed) {
generator = new Generator(new AESFastEngine(), new SHA256Digest());
generator = new Generator(new AESEngine(), new SHA256Digest());
pools = new Digest[NUM_POOLS];
for (int i = 0; i < NUM_POOLS; i++)
pools[i] = new SHA256Digest();
Expand Down
9 changes: 5 additions & 4 deletions src/test/java/org/jitsi/bccontrib/tests/SkeinTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@
package org.jitsi.bccontrib.tests;


import static org.junit.jupiter.api.Assertions.assertTrue;

import java.io.InputStream;
import java.util.Arrays;
import java.util.Scanner;
Expand All @@ -35,9 +37,8 @@
import org.jitsi.bccontrib.macs.SkeinMac;
import org.bouncycastle.crypto.params.KeyParameter;
import org.jitsi.bccontrib.params.ParametersForSkein;

import static org.junit.Assert.assertTrue;
import org.junit.*;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;

public class SkeinTest {

Expand Down Expand Up @@ -102,7 +103,7 @@ boolean checkKATVectors() {
return true;
}

@Before
@BeforeEach
public void setUp() {
InputStream file = getClass().getResourceAsStream("/skein_golden_kat.txt");
scanner = new KatScanner(file);
Expand Down
9 changes: 5 additions & 4 deletions src/test/java/org/jitsi/bccontrib/tests/ThreefishTest.java
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
package org.jitsi.bccontrib.tests;

import static org.junit.jupiter.api.Assertions.assertTrue;

import java.util.Arrays;

import org.jitsi.bccontrib.engines.ThreefishCipher;
import org.bouncycastle.crypto.params.*;
import org.jitsi.bccontrib.params.ParametersForThreefish;
import org.jitsi.bccontrib.util.ByteLong;

import static org.junit.Assert.assertTrue;
import org.junit.Test;
import org.junit.jupiter.api.Test;

public class ThreefishTest {

Expand Down Expand Up @@ -315,7 +315,8 @@ boolean basicTest1024() {
return true;
}

@Test public void vectorTest() {
@Test
public void vectorTest() {
try {
assertTrue(basicTest256());
assertTrue(basicTest512());
Expand Down