From ba7f2e850d83ca5ca7668ffc77b410c5f97c9456 Mon Sep 17 00:00:00 2001 From: Aaron McConnell Date: Mon, 15 Mar 2021 16:18:55 -0400 Subject: [PATCH] Adjust javadocs so they build correctly --- README.md | 4 ++-- duo-example/pom.xml | 4 ++-- duo-universal-sdk/pom.xml | 2 +- .../src/main/java/com/duosecurity/Client.java | 24 ++++++++++++++++--- pom.xml | 2 +- 5 files changed, 27 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 9af6afd..61716e0 100644 --- a/README.md +++ b/README.md @@ -26,10 +26,10 @@ The Duo Universal Client for Java is available from Duo Security on Maven. Incl com.duosecurity duo-universal-sdk - 1.1.0 + 1.1.1 ``` -See https://mvnrepository.com/artifact/com.duosecurity/duo-universal-sdk/1.1.0 for more details. +See https://mvnrepository.com/artifact/com.duosecurity/duo-universal-sdk/1.1.1 for more details. # Demo diff --git a/duo-example/pom.xml b/duo-example/pom.xml index 72487ee..43466ba 100644 --- a/duo-example/pom.xml +++ b/duo-example/pom.xml @@ -10,7 +10,7 @@ 4.0.0 duo-example - 1.1.0 + 1.1.1 Duo Universal Java https://github.com/duosecurity/duo_universal_java/ Duo Web SDK for two-factor authentication @@ -38,7 +38,7 @@ com.duosecurity duo-universal-sdk - 1.1.0 + 1.1.1 org.springframework diff --git a/duo-universal-sdk/pom.xml b/duo-universal-sdk/pom.xml index a1f657a..0859242 100644 --- a/duo-universal-sdk/pom.xml +++ b/duo-universal-sdk/pom.xml @@ -6,7 +6,7 @@ duo-universal-sdk com.duosecurity - 1.1.0 + 1.1.1 Duo Universal Java https://github.com/duosecurity/duo_universal_java/ Duo Web SDK for two-factor authentication diff --git a/duo-universal-sdk/src/main/java/com/duosecurity/Client.java b/duo-universal-sdk/src/main/java/com/duosecurity/Client.java index b23db18..26aded3 100644 --- a/duo-universal-sdk/src/main/java/com/duosecurity/Client.java +++ b/duo-universal-sdk/src/main/java/com/duosecurity/Client.java @@ -38,7 +38,7 @@ public class Client { private static final String USER_AGENT_LIB = "duo_universal_java"; - private static final String USER_AGENT_VERSION = "1.1.0"; + private static final String USER_AGENT_VERSION = "1.1.1"; // ************************************************** // Fields @@ -68,6 +68,12 @@ private Client() { /** * Legacy simple constructor. + * @param clientId This value is the client id provided by Duo in the admin panel. + * @param clientSecret This value is the client secret provided by Duo in the admin panel. + * @param apiHost This value is the api host provided by Duo in the admin panel. + * @param redirectUri This value is the uri which Duo should redirect to after 2FA is completed. + * + * @throws DuoException For problems building the client * @deprecated The constructors are deprecated. * Prefer the {@link Client.Builder} for instantiating Clients */ @@ -79,6 +85,14 @@ public Client(String clientId, String clientSecret, String apiHost, String redir /** * Legacy constructor which allows specifying custom CaCerts. + * @param clientId This value is the client id provided by Duo in the admin panel. + * @param clientSecret This value is the client secret provided by Duo in the admin panel. + * @param apiHost This value is the api host provided by Duo in the admin panel. + * @param redirectUri This value is the uri which Duo should redirect to after 2FA is completed. + * @param userCaCerts This value is a list of CA Certificates used to validate connections to Duo + * + * @throws DuoException For problems building the client + * * @deprecated The constructors are deprecated. * Prefer the {@link Client.Builder} for instantiating Clients */ @@ -136,8 +150,6 @@ public static class Builder { * @param clientSecret This value is the client secret provided by Duo in the admin panel. * @param apiHost This value is the api host provided by Duo in the admin panel. * @param redirectUri This value is the uri which Duo should redirect to after 2FA is completed. - * - * @throws DuoException For problems validating the client parameters */ public Builder(String clientId, String clientSecret, String apiHost, String redirectUri) { @@ -176,6 +188,8 @@ public Client build() throws DuoException { * Optionally use custom CA Certificates when validating connections to Duo. * * @param userCaCerts List of CA Certificates to use + * + * @return the Builder */ public Builder setCACerts(String[] userCaCerts) { if (validateCaCert(userCaCerts)) { @@ -189,6 +203,8 @@ public Builder setCACerts(String[] userCaCerts) { * Defaults true to use duo_code. * * @param useDuoCodeAttribute true/false toggle + * + * @return the Builder */ public Builder setUseDuoCodeAttribute(boolean useDuoCodeAttribute) { this.useDuoCodeAttribute = useDuoCodeAttribute; @@ -199,6 +215,8 @@ public Builder setUseDuoCodeAttribute(boolean useDuoCodeAttribute) { * Optionally appends string to userAgent. * * @param newUserAgent Additional info that will be added to the end of the user agent string + * + * @return the Builder */ public Builder appendUserAgentInfo(String newUserAgent) { userAgent = format("%s %s", userAgent, newUserAgent); diff --git a/pom.xml b/pom.xml index 45e1614..15cdc5f 100644 --- a/pom.xml +++ b/pom.xml @@ -7,7 +7,7 @@ com.duosecurity duo-universal-java pom - 1.1.0 + 1.1.1 Duo Universal Java https://github.com/duosecurity/duo_universal_java/