diff --git a/build.gradle b/build.gradle index d558178..248b0eb 100644 --- a/build.gradle +++ b/build.gradle @@ -15,6 +15,11 @@ subprojects { apply plugin: 'java-library' + java { + withJavadocJar() + withSourcesJar() + } + sourceCompatibility = JavaVersion.VERSION_1_8 targetCompatibility = JavaVersion.VERSION_1_8 diff --git a/java-spiffe-core/src/main/java/io/spiffe/internal/CertificateUtils.java b/java-spiffe-core/src/main/java/io/spiffe/internal/CertificateUtils.java index 86f3e76..459173e 100644 --- a/java-spiffe-core/src/main/java/io/spiffe/internal/CertificateUtils.java +++ b/java-spiffe-core/src/main/java/io/spiffe/internal/CertificateUtils.java @@ -106,8 +106,6 @@ public class CertificateUtils { * @param chain the certificate chain * @param trustedCerts to validate the certificate chain * @throws CertificateException - * @throws InvalidAlgorithmParameterException - * @throws NoSuchAlgorithmException * @throws CertPathValidatorException */ public static void validate(List chain, List trustedCerts) throws CertificateException, CertPathValidatorException { diff --git a/java-spiffe-helper/src/main/java/io/spiffe/helper/keystore/KeyStoreHelper.java b/java-spiffe-helper/src/main/java/io/spiffe/helper/keystore/KeyStoreHelper.java index 24bc276..ede6d37 100644 --- a/java-spiffe-helper/src/main/java/io/spiffe/helper/keystore/KeyStoreHelper.java +++ b/java-spiffe-helper/src/main/java/io/spiffe/helper/keystore/KeyStoreHelper.java @@ -57,6 +57,7 @@ public class KeyStoreHelper { *

* It blocks until the initial update has been received from the Workload API. * + * @param options an instance of {@link KeyStoreOptions} * @throws SocketEndpointAddressException is the socket endpoint address is not valid * @throws KeyStoreException is the entry cannot be stored in the KeyStore */ diff --git a/java-spiffe-provider/src/main/java/io/spiffe/provider/SpiffeProvider.java b/java-spiffe-provider/src/main/java/io/spiffe/provider/SpiffeProvider.java index faade22..3cbf9e8 100644 --- a/java-spiffe-provider/src/main/java/io/spiffe/provider/SpiffeProvider.java +++ b/java-spiffe-provider/src/main/java/io/spiffe/provider/SpiffeProvider.java @@ -15,14 +15,14 @@ import static io.spiffe.provider.SpiffeProviderConstants.PROVIDER_NAME; * that handles an X.509-SVID Certificate to probe identity. It also registers a {@link javax.net.ssl.TrustManagerFactory} * for creating a {@link javax.net.ssl.TrustManager} for trust chain and SPIFFE ID validation. *

- * To use this Provider, it is needed to add the following lines to the java.security file: + * To use this Provider, it is needed to add the following lines to the java.security file: *

- * security.provider.=SpiffeProvider
+ * security.provider.n=SpiffeProvider
  * ssl.KeyManagerFactory.algorithm=Spiffe
  * ssl.TrustManagerFactory.algorithm=Spiffe
  * 
*

- * Also, to configure the accepted SPIFFE IDs, add to the java.security the list of SPIFFE IDs + * Also, to configure the accepted SPIFFE IDs, add to the java.security the list of SPIFFE IDs * separated by commas: *

  * ssl.spiffe.accept=spiffe://example.org/workload1, spiffe://example.org/workload2, spiffe://other-domain.org/workload
diff --git a/java-spiffe-provider/src/main/java/io/spiffe/provider/SpiffeTrustManagerFactory.java b/java-spiffe-provider/src/main/java/io/spiffe/provider/SpiffeTrustManagerFactory.java
index 3c50f6b..317848a 100644
--- a/java-spiffe-provider/src/main/java/io/spiffe/provider/SpiffeTrustManagerFactory.java
+++ b/java-spiffe-provider/src/main/java/io/spiffe/provider/SpiffeTrustManagerFactory.java
@@ -81,6 +81,7 @@ public class SpiffeTrustManagerFactory extends TrustManagerFactorySpi {
      * If the System property 'ssl.spiffe.acceptAll' is defined as 'true', the TrustManager is configure to accept
      * any SPIFFE ID presented by a peer.
      *
+     * @param x509BundleSource a source of X.509 bundles
      * @return an instance of a {@link TrustManager} wrapped in an array. The actual type returned is {@link SpiffeTrustManager}
      */
     public TrustManager[] engineGetTrustManagers(@NonNull BundleSource x509BundleSource) {
@@ -99,6 +100,7 @@ public class SpiffeTrustManagerFactory extends TrustManagerFactorySpi {
      * Creates a {@link TrustManager} initialized with a {@link BundleSource} to provide the X.509 bundles.
      * The TrustManager is configured to accept any SPIFFE ID.
      *
+     * @param x509BundleSource a source of X.509 bundles
      * @return an instance of a {@link TrustManager} wrapped in an array. The actual type returned is {@link SpiffeTrustManager}
      */
     public TrustManager[] engineGetTrustManagersAcceptAnySpiffeId(@NonNull BundleSource x509BundleSource) {
diff --git a/java-spiffe-provider/src/main/java/io/spiffe/provider/X509SourceManager.java b/java-spiffe-provider/src/main/java/io/spiffe/provider/X509SourceManager.java
index 3911f7d..fd6941b 100644
--- a/java-spiffe-provider/src/main/java/io/spiffe/provider/X509SourceManager.java
+++ b/java-spiffe-provider/src/main/java/io/spiffe/provider/X509SourceManager.java
@@ -13,8 +13,7 @@ import io.spiffe.workloadapi.X509Source;
  * If the environment variable is not defined, it will throw an IllegalStateException.
  * If the X509Source cannot be initialized, it will throw a RuntimeException.
  * 

- * - * @implNote This Singleton needed to be able to handle a single {@link X509Source} instance + * This Singleton needed to be able to handle a single {@link X509Source} instance * to be used by the {@link SpiffeKeyManagerFactory} and {@link SpiffeTrustManagerFactory} to inject it * in the {@link SpiffeKeyManager} and {@link SpiffeTrustManager} instances. */