Compare commits
8 Commits
master
...
github-act
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
68e4aeb9d6 | ||
|
|
3782f912d2 | ||
|
|
47e4b6670c | ||
|
|
e6e7db4f37 | ||
|
|
b9777a8848 | ||
|
|
8cbbca6107 | ||
|
|
e72031e4ee | ||
|
|
7a466392bb |
29
.github/workflows/test.yml
vendored
Normal file
29
.github/workflows/test.yml
vendored
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
name: Build/test
|
||||||
|
|
||||||
|
on: [push]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
test:
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [ubuntu-20.04]
|
||||||
|
java: [8, 11, 13, 15]
|
||||||
|
fail-fast: false
|
||||||
|
name: JDK ${{ matrix.java }}
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v1
|
||||||
|
- name: Set up JDK
|
||||||
|
uses: actions/setup-java@v1
|
||||||
|
with:
|
||||||
|
java-version: ${{ matrix.java }}
|
||||||
|
- name: Cache local Maven repository
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: ~/.m2/repository
|
||||||
|
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-maven-
|
||||||
|
- name: Test with Maven
|
||||||
|
run: mvn verify -B --file pom.xml
|
||||||
2
.gitignore
vendored
2
.gitignore
vendored
@ -4,3 +4,5 @@ target
|
|||||||
.project
|
.project
|
||||||
doc
|
doc
|
||||||
*.class
|
*.class
|
||||||
|
*.iml
|
||||||
|
.idea/
|
||||||
|
|||||||
14
README.md
14
README.md
@ -1,3 +1,15 @@
|
|||||||
|
This project is a fork of https://github.com/rweather/noise-java. The goal of
|
||||||
|
this fork is to make Noise-Java available via common artifact repositories like
|
||||||
|
[Maven Central](https://search.maven.org/). Substantive changes will be offered
|
||||||
|
as pull requests upstream wherever possible.
|
||||||
|
|
||||||
|
To avoid namespace collisions, the group identifier in this project's POM has
|
||||||
|
been changed to `org.signal`, though package names within the artifact have not
|
||||||
|
changed.
|
||||||
|
|
||||||
|
The original README continues below.
|
||||||
|
|
||||||
|
----
|
||||||
|
|
||||||
Noise-Java Library
|
Noise-Java Library
|
||||||
==================
|
==================
|
||||||
@ -28,7 +40,7 @@ If you have better implementations of the cryptographic primitives
|
|||||||
available, you can modify the createDH(), createCipher(), and
|
available, you can modify the createDH(), createCipher(), and
|
||||||
createHash() functions in the "Noise" class to integrate your versions.
|
createHash() functions in the "Noise" class to integrate your versions.
|
||||||
|
|
||||||
The [package documentation](http://rweather.github.io/noise-java/index.html)
|
The [package documentation](https://rweather.github.io/noise-java/index.html)
|
||||||
contains more information on the classes in the Noise-Java library.
|
contains more information on the classes in the Noise-Java library.
|
||||||
|
|
||||||
For more information on this library, to report bugs, to contribute,
|
For more information on this library, to report bugs, to contribute,
|
||||||
|
|||||||
@ -1,8 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
rm -rf doc/html
|
|
||||||
mkdir -p doc/html
|
|
||||||
exec javadoc -sourcepath NoiseJava/src \
|
|
||||||
-subpackages com.southernstorm.noise.protocol \
|
|
||||||
-d doc/html \
|
|
||||||
-windowtitle "Noise-Java" \
|
|
||||||
com.southernstorm.noise.protocol
|
|
||||||
31
pom.xml
31
pom.xml
@ -3,8 +3,8 @@
|
|||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
<artifactId>noise-java</artifactId>
|
<artifactId>noise-java</artifactId>
|
||||||
<groupId>com.southerstorm</groupId>
|
<groupId>org.signal</groupId>
|
||||||
<version>1.0-SNAPSHOT</version>
|
<version>0.1-SNAPSHOT</version>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
@ -22,9 +22,26 @@
|
|||||||
<groupId>javax.xml.bind</groupId>
|
<groupId>javax.xml.bind</groupId>
|
||||||
<artifactId>jaxb-api</artifactId>
|
<artifactId>jaxb-api</artifactId>
|
||||||
<version>2.3.0</version>
|
<version>2.3.0</version>
|
||||||
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
<build>
|
<build>
|
||||||
|
<pluginManagement>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<version>3.3.0</version>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-surefire-plugin</artifactId>
|
||||||
|
<version>3.0.0-M5</version>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</pluginManagement>
|
||||||
|
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
<plugin>
|
||||||
<artifactId>maven-compiler-plugin</artifactId>
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
@ -34,6 +51,16 @@
|
|||||||
<target>1.8</target>
|
<target>1.8</target>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<source>8</source>
|
||||||
|
<excludePackageNames>com.southernstorm.noise.crypto</excludePackageNames>
|
||||||
|
<windowtitle>Noise-Java</windowtitle>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@ -1,19 +1,14 @@
|
|||||||
package com.southernstorm.noise.tests;
|
package com.southernstorm.noise.tests;
|
||||||
|
|
||||||
import java.io.InputStream;
|
import java.io.InputStream;
|
||||||
import java.net.URL;
|
|
||||||
import org.junit.Assert;
|
import org.junit.Assert;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.Test;
|
||||||
|
|
||||||
public class UnitVectorTests {
|
public class UnitVectorTests {
|
||||||
|
|
||||||
private static final String testVectorsCommit = "5d0a74760320e5486ced302e36ccad91606aac43";
|
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
void testBasicVector() throws Exception {
|
public void testBasicVector() throws Exception {
|
||||||
try (InputStream stream = new URL(
|
try (final InputStream stream = getClass().getResourceAsStream("test-vectors.json")) {
|
||||||
"https://raw.githubusercontent.com/rweather/noise-c/" + testVectorsCommit
|
|
||||||
+ "/tests/vector/noise-c-basic.txt").openStream()) {
|
|
||||||
VectorTests vectorTests = new VectorTests();
|
VectorTests vectorTests = new VectorTests();
|
||||||
vectorTests.processInputStream(stream);
|
vectorTests.processInputStream(stream);
|
||||||
Assert.assertEquals(vectorTests.getFailed(), 0);
|
Assert.assertEquals(vectorTests.getFailed(), 0);
|
||||||
|
|||||||
19684
src/test/resources/com/southernstorm/noise/tests/test-vectors.json
Normal file
19684
src/test/resources/com/southernstorm/noise/tests/test-vectors.json
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user