You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by pe...@apache.org on 2022/03/28 22:13:01 UTC

[netbeans] branch master updated: Upgrade Commons-Net from 3.6 to 3.8.0 (#3775)

This is an automated email from the ASF dual-hosted git repository.

pepness pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/netbeans.git


The following commit(s) were added to refs/heads/master by this push:
     new d2f6617  Upgrade Commons-Net from 3.6 to 3.8.0 (#3775)
d2f6617 is described below

commit d2f661743f157b32c172994dce694e1a42319490
Author: José Contreras <pe...@apache.org>
AuthorDate: Mon Mar 28 22:12:31 2022 +0000

    Upgrade Commons-Net from 3.6 to 3.8.0 (#3775)
    
    
    - Remove usage of commons.net.util.Base64 in favor of JDK java.util.Base64 in module ide/hudson.ui
---
 ide/hudson.ui/nbproject/project.properties                       | 2 +-
 ide/hudson.ui/nbproject/project.xml                              | 9 ---------
 .../modules/hudson/ui/APITokenConnectionAuthenticator.java       | 4 ++--
 .../org/netbeans/modules/hudson/ui/actions/CreateJobTest.java    | 1 +
 ide/libs.commons_net/external/binaries-list                      | 2 +-
 ...commons-net-3.6-license.txt => commons-net-3.8.0-license.txt} | 4 ++--
 .../{commons-net-3.6-notice.txt => commons-net-3.8.0-notice.txt} | 0
 ide/libs.commons_net/nbproject/project.properties                | 4 +---
 ide/libs.commons_net/nbproject/project.xml                       | 4 ++--
 .../src/org/netbeans/libs/commons_net/Bundle.properties          | 2 +-
 .../src/org/netbeans/libs/commons_net/mf-layer.xml               | 2 +-
 11 files changed, 12 insertions(+), 22 deletions(-)

diff --git a/ide/hudson.ui/nbproject/project.properties b/ide/hudson.ui/nbproject/project.properties
index c0af75f..0f4ec98 100644
--- a/ide/hudson.ui/nbproject/project.properties
+++ b/ide/hudson.ui/nbproject/project.properties
@@ -14,5 +14,5 @@
 # KIND, either express or implied.  See the License for the
 # specific language governing permissions and limitations
 # under the License.
-javac.source=1.6
+javac.source=1.8
 javac.compilerargs=-Xlint -Xlint:-serial
diff --git a/ide/hudson.ui/nbproject/project.xml b/ide/hudson.ui/nbproject/project.xml
index d606d4b..7c2c259 100644
--- a/ide/hudson.ui/nbproject/project.xml
+++ b/ide/hudson.ui/nbproject/project.xml
@@ -70,15 +70,6 @@
                     </run-dependency>
                 </dependency>
                 <dependency>
-                    <code-name-base>org.netbeans.libs.commons_net</code-name-base>
-                    <build-prerequisite/>
-                    <compile-dependency/>
-                    <run-dependency>
-                        <release-version>2</release-version>
-                        <specification-version>2.11</specification-version>
-                    </run-dependency>
-                </dependency>
-                <dependency>
                     <code-name-base>org.netbeans.modules.diff</code-name-base>
                     <build-prerequisite/>
                     <compile-dependency/>
diff --git a/ide/hudson.ui/src/org/netbeans/modules/hudson/ui/APITokenConnectionAuthenticator.java b/ide/hudson.ui/src/org/netbeans/modules/hudson/ui/APITokenConnectionAuthenticator.java
index 71cf127..2eed744 100644
--- a/ide/hudson.ui/src/org/netbeans/modules/hudson/ui/APITokenConnectionAuthenticator.java
+++ b/ide/hudson.ui/src/org/netbeans/modules/hudson/ui/APITokenConnectionAuthenticator.java
@@ -23,12 +23,12 @@ import java.io.IOException;
 import java.net.MalformedURLException;
 import java.net.URL;
 import java.net.URLConnection;
+import java.util.Base64;
 import java.util.HashMap;
 import java.util.Map;
 import java.util.logging.Level;
 import java.util.logging.Logger;
 import javax.swing.JPanel;
-import org.apache.commons.net.util.Base64;
 import org.netbeans.api.keyring.Keyring;
 import org.netbeans.modules.hudson.api.HudsonManager;
 import org.netbeans.modules.hudson.api.HudsonVersion;
@@ -108,7 +108,7 @@ public class APITokenConnectionAuthenticator extends JPanel {
             String token = new String(panel.tokField.getPassword());
             panel.tokField.setText("");
             Keyring.save(key, token.toCharArray(), Bundle.APITokenConnectionAuthenticator_password_description(home, username));
-            BASIC_AUTH.put(home.toString(), new Base64(0).encodeToString((username + ':' + token).getBytes()).trim());
+            BASIC_AUTH.put(home.toString(), Base64.getEncoder().encodeToString((username + ':' + token).getBytes()).trim());
             try {
                 return conn.getURL().openConnection();
             } catch (IOException x) {
diff --git a/ide/hudson.ui/test/unit/src/org/netbeans/modules/hudson/ui/actions/CreateJobTest.java b/ide/hudson.ui/test/unit/src/org/netbeans/modules/hudson/ui/actions/CreateJobTest.java
index 4f1a8d1..379fe98 100644
--- a/ide/hudson.ui/test/unit/src/org/netbeans/modules/hudson/ui/actions/CreateJobTest.java
+++ b/ide/hudson.ui/test/unit/src/org/netbeans/modules/hudson/ui/actions/CreateJobTest.java
@@ -53,4 +53,5 @@ public class CreateJobTest {
         assertTrue(withCustomAction.runCustomActionIfAvailable(null));
         HudsonManager.removeInstance(hi);
     }
+    
 }
diff --git a/ide/libs.commons_net/external/binaries-list b/ide/libs.commons_net/external/binaries-list
index b044a5b..ee1a9c1 100644
--- a/ide/libs.commons_net/external/binaries-list
+++ b/ide/libs.commons_net/external/binaries-list
@@ -14,4 +14,4 @@
 # KIND, either express or implied.  See the License for the
 # specific language governing permissions and limitations
 # under the License.
-B71DE00508DCB078D2B24B5FA7E538636DE9B3DA commons-net:commons-net:3.6
+63EA56587C8AAF05ADAB5CB0397E056BAC8A2DB0 commons-net:commons-net:3.8.0
diff --git a/ide/libs.commons_net/external/commons-net-3.6-license.txt b/ide/libs.commons_net/external/commons-net-3.8.0-license.txt
similarity index 99%
rename from ide/libs.commons_net/external/commons-net-3.6-license.txt
rename to ide/libs.commons_net/external/commons-net-3.8.0-license.txt
index 67c14e5..e698d48 100644
--- a/ide/libs.commons_net/external/commons-net-3.6-license.txt
+++ b/ide/libs.commons_net/external/commons-net-3.8.0-license.txt
@@ -1,8 +1,8 @@
 Name: Commons Net
-Version: 3.6
+Version: 3.8.0
 OSR: 3487
 Description: Apache Commons Net implements the client side of many basic Internet protocols.
-Origin: http://commons.apache.org/net/
+Origin: https://commons.apache.org/proper/commons-net/index.html
 License: Apache-2.0
 
                                  Apache License
diff --git a/ide/libs.commons_net/external/commons-net-3.6-notice.txt b/ide/libs.commons_net/external/commons-net-3.8.0-notice.txt
similarity index 100%
rename from ide/libs.commons_net/external/commons-net-3.6-notice.txt
rename to ide/libs.commons_net/external/commons-net-3.8.0-notice.txt
diff --git a/ide/libs.commons_net/nbproject/project.properties b/ide/libs.commons_net/nbproject/project.properties
index e07ec56..0546658 100644
--- a/ide/libs.commons_net/nbproject/project.properties
+++ b/ide/libs.commons_net/nbproject/project.properties
@@ -16,7 +16,5 @@
 # under the License.
 
 is.autoload=true
-javac.compilerargs=-Xlint -Xlint:-serial
-javac.source=1.6
-release.external/commons-net-3.6.jar=modules/ext/commons-net-3.6.jar
+release.external/commons-net-3.8.0.jar=modules/ext/commons-net-3.8.0.jar
 spec.version.base=2.38.0
diff --git a/ide/libs.commons_net/nbproject/project.xml b/ide/libs.commons_net/nbproject/project.xml
index 66d0162..2fd2586 100644
--- a/ide/libs.commons_net/nbproject/project.xml
+++ b/ide/libs.commons_net/nbproject/project.xml
@@ -31,8 +31,8 @@
                 <package>org.apache.commons.net.util</package>
             </public-packages>
             <class-path-extension>
-                <runtime-relative-path>ext/commons-net-3.6.jar</runtime-relative-path>
-                <binary-origin>external/commons-net-3.6.jar</binary-origin>
+                <runtime-relative-path>ext/commons-net-3.8.0.jar</runtime-relative-path>
+                <binary-origin>external/commons-net-3.8.0.jar</binary-origin>
             </class-path-extension>
         </data>
     </configuration>
diff --git a/ide/libs.commons_net/src/org/netbeans/libs/commons_net/Bundle.properties b/ide/libs.commons_net/src/org/netbeans/libs/commons_net/Bundle.properties
index 0d17791..9b1d4ca9 100644
--- a/ide/libs.commons_net/src/org/netbeans/libs/commons_net/Bundle.properties
+++ b/ide/libs.commons_net/src/org/netbeans/libs/commons_net/Bundle.properties
@@ -20,4 +20,4 @@ OpenIDE-Module-Display-Category=Libraries
 OpenIDE-Module-Short-Description=This plugin bundles Commons Net.
 OpenIDE-Module-Long-Description=\
     The module bundles Apache Commons Net \
-    from http://commons.apache.org/net/.
+    from https://commons.apache.org/proper/commons-net/.
diff --git a/ide/libs.commons_net/src/org/netbeans/libs/commons_net/mf-layer.xml b/ide/libs.commons_net/src/org/netbeans/libs/commons_net/mf-layer.xml
index 409b232..7c72df8 100644
--- a/ide/libs.commons_net/src/org/netbeans/libs/commons_net/mf-layer.xml
+++ b/ide/libs.commons_net/src/org/netbeans/libs/commons_net/mf-layer.xml
@@ -27,7 +27,7 @@
             <file name="org-netbeans-lib-commons_net-antlibrary.instance">
                 <attr name="instanceCreate" methodvalue="org.apache.tools.ant.module.spi.AutomaticExtraClasspath.url"/>
                 <attr name="instanceOf" stringvalue="org.apache.tools.ant.module.spi.AutomaticExtraClasspathProvider"/>
-                <attr name="url" urlvalue="nbinst://org.netbeans.libs.commons_net/modules/ext/commons-net-3.6.jar"/>
+                <attr name="url" urlvalue="nbinst://org.netbeans.libs.commons_net/modules/ext/commons-net-3.8.0.jar"/>
             </file>
         </folder>
     </folder>

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists