forked from openrs2/openrs2
parent
eae715231b
commit
177326221f
@ -1,10 +1,10 @@ |
||||
package dev.openrs2.bundler |
||||
|
||||
import com.google.inject.AbstractModule |
||||
import dev.openrs2.common.CommonModule |
||||
import dev.openrs2.crypto.CryptoModule |
||||
|
||||
class BundlerModule : AbstractModule() { |
||||
override fun configure() { |
||||
install(CommonModule()) |
||||
install(CryptoModule()) |
||||
} |
||||
} |
||||
|
@ -0,0 +1,30 @@ |
||||
plugins { |
||||
`maven-publish` |
||||
kotlin("jvm") |
||||
} |
||||
|
||||
dependencies { |
||||
api("com.google.inject:guice:${Versions.guice}") |
||||
api("io.netty:netty-buffer:${Versions.netty}") |
||||
api("org.bouncycastle:bcpkix-jdk15on:${Versions.bouncyCastle}") |
||||
api("org.bouncycastle:bcprov-jdk15on:${Versions.bouncyCastle}") |
||||
|
||||
testImplementation("com.google.jimfs:jimfs:${Versions.jimfs}") |
||||
} |
||||
|
||||
publishing { |
||||
publications.create<MavenPublication>("maven") { |
||||
from(components["java"]) |
||||
|
||||
pom { |
||||
packaging = "jar" |
||||
name.set("OpenRS2 Cryptography") |
||||
description.set( |
||||
""" |
||||
Provides implementations of cryptographic algorithms used by |
||||
the client, including RSA, ISAAC, XTEA and JAR signing. |
||||
""".trimIndent() |
||||
) |
||||
} |
||||
} |
||||
} |
@ -1,11 +1,10 @@ |
||||
package dev.openrs2.common |
||||
package dev.openrs2.crypto |
||||
|
||||
import com.google.inject.AbstractModule |
||||
import com.google.inject.Scopes |
||||
import dev.openrs2.common.crypto.RsaKeyProvider |
||||
import org.bouncycastle.crypto.params.RSAPrivateCrtKeyParameters |
||||
|
||||
class CommonModule : AbstractModule() { |
||||
class CryptoModule : AbstractModule() { |
||||
override fun configure() { |
||||
bind(RSAPrivateCrtKeyParameters::class.java) |
||||
.toProvider(RsaKeyProvider::class.java) |
@ -1,4 +1,4 @@ |
||||
package dev.openrs2.common.crypto |
||||
package dev.openrs2.crypto |
||||
|
||||
import jdk.security.jarsigner.JarSigner |
||||
import org.bouncycastle.asn1.nist.NISTObjectIdentifiers |
@ -1,4 +1,4 @@ |
||||
package dev.openrs2.common.crypto |
||||
package dev.openrs2.crypto |
||||
|
||||
import io.netty.buffer.ByteBuf |
||||
import io.netty.buffer.ByteBufUtil |
@ -1,4 +1,4 @@ |
||||
package dev.openrs2.common.crypto |
||||
package dev.openrs2.crypto |
||||
|
||||
import org.bouncycastle.crypto.params.RSAPrivateCrtKeyParameters |
||||
import java.nio.file.Files |
@ -1,4 +1,4 @@ |
||||
package dev.openrs2.common.crypto |
||||
package dev.openrs2.crypto |
||||
|
||||
import java.security.SecureRandom |
||||
|
@ -1,4 +1,4 @@ |
||||
package dev.openrs2.common.crypto |
||||
package dev.openrs2.crypto |
||||
|
||||
import com.google.common.jimfs.Configuration |
||||
import com.google.common.jimfs.Jimfs |
@ -1,10 +1,9 @@ |
||||
package dev.openrs2.game |
||||
|
||||
import com.google.inject.AbstractModule |
||||
import dev.openrs2.common.CommonModule |
||||
|
||||
class GameModule : AbstractModule() { |
||||
override fun configure() { |
||||
install(CommonModule()) |
||||
// empty |
||||
} |
||||
} |
||||
|
Loading…
Reference in new issue