+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import javax.crypto.Cipher;
|
||||
import javax.crypto.spec.IvParameterSpec;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import java.nio.charset.Charset;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import java.util.Arrays;
|
||||
import java.util.Objects;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import java.util.Objects;
|
||||
import java.util.function.BooleanSupplier;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import java.nio.charset.Charset;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import java.util.stream.IntStream;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
+1
-4
@@ -15,12 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import org.junit.jupiter.api.Assertions;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.nio.charset.StandardCharsets;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.devkit.utils;
|
||||
package com.onixbyte.common.util;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
@@ -64,13 +64,13 @@ tasks.test {
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("guid") {
|
||||
create<MavenPublication>("identityGenerator") {
|
||||
groupId = group.toString()
|
||||
artifactId = "guid"
|
||||
artifactId = "identity-generator"
|
||||
version = artefactVersion
|
||||
|
||||
pom {
|
||||
name = "DevKit - GUID"
|
||||
name = "OnixByte Identity Generator"
|
||||
description = "The module for generating GUIDs of JDevKit."
|
||||
url = projectUrl
|
||||
|
||||
@@ -107,7 +107,7 @@ publishing {
|
||||
from(components["java"])
|
||||
|
||||
signing {
|
||||
sign(publishing.publications["guid"])
|
||||
sign(publishing.publications["identityGenerator"])
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@ implementation 'cn.org.codecrafters:simple-jwt-authzero:${simple-jwt-authzero.ve
|
||||
|
||||
## Use the `AuthzeroTokenResolver`
|
||||
|
||||
We have implemented `TokenResolver` to make sure you can add JWT to your Java application as soon as possible. All you need to do is to create an instance of `com.onixbyte.simplejwt.authzero.AuthzeroTokenResolver` and other operations to JWT could follow our instruction in [`simple-jwt-facade`](../simple-jwt-facade/README.md).
|
||||
We have implemented `TokenResolver` to make sure you can add JWT to your Java application as soon as possible. All you need to do is to create an instance of `com.onixbyte.jwt.auth0.AuthzeroTokenResolver` and other operations to JWT could follow our instruction in [`simple-jwt-facade`](../simple-jwt-facade/README.md).
|
||||
|
||||
## Contact
|
||||
|
||||
|
||||
@@ -72,13 +72,13 @@ tasks.test {
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("simpleJwtAuthzero") {
|
||||
create<MavenPublication>("jwtToolboxAuth0") {
|
||||
groupId = group.toString()
|
||||
artifactId = "simple-jwt-authzero"
|
||||
artifactId = "jwt-toolbox-auth0"
|
||||
version = artefactVersion
|
||||
|
||||
pom {
|
||||
name = "Simple JWT :: Auth0"
|
||||
name = "OnixByte JWT Toolbox :: Auth0"
|
||||
description = "Simple JWT implemented with com.auth0:java-jwt."
|
||||
url = projectUrl
|
||||
|
||||
@@ -115,7 +115,7 @@ publishing {
|
||||
from(components["java"])
|
||||
|
||||
signing {
|
||||
sign(publishing.publications["simpleJwtAuthzero"])
|
||||
sign(publishing.publications["jwtToolboxAuth0"])
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+11
-11
@@ -15,17 +15,17 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.authzero;
|
||||
package com.onixbyte.jwt.auth0;
|
||||
|
||||
import com.onixbyte.common.util.Base64Util;
|
||||
import com.onixbyte.crypto.algorithm.ecdsa.ECPrivateKeyLoader;
|
||||
import com.onixbyte.devkit.utils.Base64Util;
|
||||
import com.onixbyte.identitygenerator.IdentityGenerator;
|
||||
import com.onixbyte.simplejwt.TokenPayload;
|
||||
import com.onixbyte.simplejwt.TokenResolver;
|
||||
import com.onixbyte.simplejwt.annotations.ExcludeFromPayload;
|
||||
import com.onixbyte.simplejwt.annotations.TokenEnum;
|
||||
import com.onixbyte.simplejwt.constants.PredefinedKeys;
|
||||
import com.onixbyte.simplejwt.constants.TokenAlgorithm;
|
||||
import com.onixbyte.jwt.TokenPayload;
|
||||
import com.onixbyte.jwt.TokenResolver;
|
||||
import com.onixbyte.jwt.annotations.ExcludeFromPayload;
|
||||
import com.onixbyte.jwt.annotations.TokenEnum;
|
||||
import com.onixbyte.jwt.constants.PredefinedKeys;
|
||||
import com.onixbyte.jwt.constants.TokenAlgorithm;
|
||||
import com.auth0.jwt.JWT;
|
||||
import com.auth0.jwt.JWTCreator;
|
||||
import com.auth0.jwt.algorithms.Algorithm;
|
||||
@@ -35,9 +35,9 @@ import com.fasterxml.jackson.core.JsonProcessingException;
|
||||
import com.fasterxml.jackson.core.type.TypeReference;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.fasterxml.jackson.databind.node.ObjectNode;
|
||||
import com.onixbyte.simplejwt.exceptions.IllegalKeyPairException;
|
||||
import com.onixbyte.simplejwt.exceptions.IllegalSecretException;
|
||||
import com.onixbyte.simplejwt.exceptions.UnsupportedAlgorithmException;
|
||||
import com.onixbyte.jwt.exceptions.IllegalKeyPairException;
|
||||
import com.onixbyte.jwt.exceptions.IllegalSecretException;
|
||||
import com.onixbyte.jwt.exceptions.UnsupportedAlgorithmException;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
+1
-7
@@ -15,13 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.authzero.test;
|
||||
|
||||
import com.onixbyte.simplejwt.authzero.AuthzeroTokenResolver;
|
||||
import com.onixbyte.simplejwt.constants.TokenAlgorithm;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
import java.time.Duration;
|
||||
package com.onixbyte.jwt.auth0.test;
|
||||
|
||||
/**
|
||||
* TestAuthzeroTokenResolver
|
||||
@@ -68,13 +68,13 @@ tasks.test {
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("simpleJwtFacade") {
|
||||
create<MavenPublication>("jwtToolboxFacade") {
|
||||
groupId = group.toString()
|
||||
artifactId = "simple-jwt-facade"
|
||||
artifactId = "jwt-toolbox-facade"
|
||||
version = artefactVersion
|
||||
|
||||
pom {
|
||||
name = "Simple JWT :: Facade"
|
||||
name = "OnixByte JWT Toolbox :: Facade"
|
||||
description = "Declaration of simple JWT module."
|
||||
url = projectUrl
|
||||
|
||||
@@ -111,7 +111,7 @@ publishing {
|
||||
from(components["java"])
|
||||
|
||||
signing {
|
||||
sign(publishing.publications["simpleJwtFacade"])
|
||||
sign(publishing.publications["jwtToolboxFacade"])
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt;
|
||||
package com.onixbyte.jwt;
|
||||
|
||||
import com.onixbyte.simplejwt.exceptions.WeakSecretException;
|
||||
import com.onixbyte.jwt.exceptions.WeakSecretException;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt;
|
||||
package com.onixbyte.jwt;
|
||||
|
||||
/**
|
||||
* {@code TokenPayload} interface is used to mark a data class as suitable
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt;
|
||||
package com.onixbyte.jwt;
|
||||
|
||||
import java.time.Duration;
|
||||
import java.util.Map;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.annotations;
|
||||
package com.onixbyte.jwt.annotations;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
+2
-2
@@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.annotations;
|
||||
package com.onixbyte.jwt.annotations;
|
||||
|
||||
import com.onixbyte.simplejwt.constants.TokenDataType;
|
||||
import com.onixbyte.jwt.constants.TokenDataType;
|
||||
|
||||
import java.lang.annotation.ElementType;
|
||||
import java.lang.annotation.Retention;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.constants;
|
||||
package com.onixbyte.jwt.constants;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.constants;
|
||||
package com.onixbyte.jwt.constants;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.constants;
|
||||
package com.onixbyte.jwt.constants;
|
||||
|
||||
/**
|
||||
* The base data types used to process enum data.
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.exceptions;
|
||||
package com.onixbyte.jwt.exceptions;
|
||||
|
||||
/**
|
||||
* {@link IllegalKeyPairException} indicates an exception that the key pair is invalid.
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.exceptions;
|
||||
package com.onixbyte.jwt.exceptions;
|
||||
|
||||
/**
|
||||
* {@link IllegalKeyPairException} indicates the secret to sign a JWT is illegal.
|
||||
+2
-2
@@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.exceptions;
|
||||
package com.onixbyte.jwt.exceptions;
|
||||
|
||||
import com.onixbyte.simplejwt.TokenResolver;
|
||||
import com.onixbyte.jwt.TokenResolver;
|
||||
|
||||
/**
|
||||
* This {@code UnsupportedAlgorithmException} represents the given
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.exceptions;
|
||||
package com.onixbyte.jwt.exceptions;
|
||||
|
||||
/**
|
||||
* {@code WeakSecretException} represents that your secret is too weak to be
|
||||
@@ -81,13 +81,13 @@ tasks.test {
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("simpleJwtSpringBootStarter") {
|
||||
create<MavenPublication>("jwtSpringBootStarter") {
|
||||
groupId = group.toString()
|
||||
artifactId = "simple-jwt-spring-boot-starter"
|
||||
artifactId = "jwt-spring-boot-starter"
|
||||
version = artefactVersion
|
||||
|
||||
pom {
|
||||
name = "Simple JWT :: Spring Boot Starter"
|
||||
name = "OnixByte JWT Toolbox :: Spring Boot Starter"
|
||||
description = "Simple JWT all-in-one package for Spring Boot."
|
||||
url = projectUrl
|
||||
|
||||
@@ -124,7 +124,7 @@ publishing {
|
||||
from(components["java"])
|
||||
|
||||
signing {
|
||||
sign(publishing.publications["simpleJwtSpringBootStarter"])
|
||||
sign(publishing.publications["jwtSpringBootStarter"])
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+5
-5
@@ -15,15 +15,15 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.autoconfiguration;
|
||||
package com.onixbyte.jwt.autoconfiguration;
|
||||
|
||||
import com.onixbyte.identitygenerator.IdentityGenerator;
|
||||
import com.onixbyte.simplejwt.TokenResolver;
|
||||
import com.onixbyte.simplejwt.authzero.AuthzeroTokenResolver;
|
||||
import com.onixbyte.simplejwt.autoconfiguration.properties.SimpleJwtProperties;
|
||||
import com.onixbyte.jwt.TokenResolver;
|
||||
import com.onixbyte.jwt.auth0.AuthzeroTokenResolver;
|
||||
import com.onixbyte.jwt.autoconfiguration.properties.SimpleJwtProperties;
|
||||
import com.auth0.jwt.interfaces.DecodedJWT;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.onixbyte.simplejwt.constants.TokenAlgorithm;
|
||||
import com.onixbyte.jwt.constants.TokenAlgorithm;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
+2
-2
@@ -15,10 +15,10 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.autoconfiguration;
|
||||
package com.onixbyte.jwt.autoconfiguration;
|
||||
|
||||
import com.onixbyte.identitygenerator.IdentityGenerator;
|
||||
import com.onixbyte.simplejwt.autoconfiguration.conditions.GuidCreatorCondition;
|
||||
import com.onixbyte.jwt.autoconfiguration.conditions.GuidCreatorCondition;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.boot.autoconfigure.AutoConfiguration;
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.autoconfiguration.conditions;
|
||||
package com.onixbyte.jwt.autoconfiguration.conditions;
|
||||
|
||||
import com.onixbyte.identitygenerator.IdentityGenerator;
|
||||
import org.slf4j.Logger;
|
||||
+4
-4
@@ -15,11 +15,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.simplejwt.autoconfiguration.properties;
|
||||
package com.onixbyte.jwt.autoconfiguration.properties;
|
||||
|
||||
import com.onixbyte.simplejwt.SecretCreator;
|
||||
import com.onixbyte.simplejwt.autoconfiguration.AuthzeroTokenResolverAutoConfiguration;
|
||||
import com.onixbyte.simplejwt.constants.TokenAlgorithm;
|
||||
import com.onixbyte.jwt.SecretCreator;
|
||||
import com.onixbyte.jwt.autoconfiguration.AuthzeroTokenResolverAutoConfiguration;
|
||||
import com.onixbyte.jwt.constants.TokenAlgorithm;
|
||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||
|
||||
/**
|
||||
+2
-2
@@ -1,2 +1,2 @@
|
||||
com.onixbyte.simplejwt.autoconfiguration.GuidAutoConfiguration
|
||||
com.onixbyte.simplejwt.autoconfiguration.AuthzeroTokenResolverAutoConfiguration
|
||||
com.onixbyte.jwt.autoconfiguration.GuidAutoConfiguration
|
||||
com.onixbyte.jwt.autoconfiguration.AuthzeroTokenResolverAutoConfiguration
|
||||
|
||||
@@ -64,13 +64,13 @@ tasks.test {
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("num4j") {
|
||||
create<MavenPublication>("mathToolbox") {
|
||||
groupId = group.toString()
|
||||
artifactId = "num4j"
|
||||
artifactId = "math-toolbox"
|
||||
version = artefactVersion
|
||||
|
||||
pom {
|
||||
name = "Num4j"
|
||||
name = "OnixByte Math Toolbox"
|
||||
description =
|
||||
"This module is an easy-to-use util for mathematical calculations in Java."
|
||||
url = projectUrl
|
||||
@@ -108,7 +108,7 @@ publishing {
|
||||
from(components["java"])
|
||||
|
||||
signing {
|
||||
sign(publishing.publications["num4j"])
|
||||
sign(publishing.publications["mathToolbox"])
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.nums;
|
||||
package com.onixbyte.math;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
+2
-2
@@ -15,9 +15,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.nums;
|
||||
package com.onixbyte.math;
|
||||
|
||||
import com.onixbyte.nums.model.QuartileBounds;
|
||||
import com.onixbyte.math.model.QuartileBounds;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package com.onixbyte.nums.model;
|
||||
package com.onixbyte.math.model;
|
||||
|
||||
/**
|
||||
* A record representing the quartile bounds of a dataset.
|
||||
@@ -49,9 +49,9 @@ dependencies {
|
||||
|
||||
publishing {
|
||||
publications {
|
||||
create<MavenPublication>("devkitBom") {
|
||||
create<MavenPublication>("versionCatalogue") {
|
||||
groupId = group.toString()
|
||||
artifactId = "devkit-bom"
|
||||
artifactId = "version-catalogue"
|
||||
version = artefactVersion
|
||||
|
||||
pom {
|
||||
@@ -92,7 +92,7 @@ publishing {
|
||||
from(components["javaPlatform"])
|
||||
|
||||
signing {
|
||||
sign(publishing.publications["devkitBom"])
|
||||
sign(publishing.publications["versionCatalogue"])
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user