summaryrefslogtreecommitdiffstats
path: root/base/silent
diff options
context:
space:
mode:
authorEndi Sukma Dewata <edewata@redhat.com>2012-04-09 13:56:59 -0500
committerEndi Sukma Dewata <edewata@redhat.com>2012-04-12 10:16:22 -0500
commit7d88f4ee050856b8fef5f260cfe1b3aeec201fda (patch)
tree9d0b80dcbcc63ccb83d32995376168dcd086bab9 /base/silent
parent3f24e55923fc986af4c6a08b2b8d45704a905627 (diff)
downloadpki-7d88f4ee050856b8fef5f260cfe1b3aeec201fda.tar.gz
pki-7d88f4ee050856b8fef5f260cfe1b3aeec201fda.tar.xz
pki-7d88f4ee050856b8fef5f260cfe1b3aeec201fda.zip
Removed unused private fields.
Most of unused private fields have been removed because they generate warnings in Eclipse. Some are kept because it might be useful later. Ticket #139
Diffstat (limited to 'base/silent')
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/CMSLDAP.java2
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/CMSTask.java1
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/ComCrypto.java6
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/Con2Agent.java7
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/DirEnroll.java9
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/Request.java32
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/ServerInfo.java1
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/TestClient.java2
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/UserEnroll.java2
-rw-r--r--base/silent/src/com/netscape/pkisilent/common/checkRequest.java5
10 files changed, 43 insertions, 24 deletions
diff --git a/base/silent/src/com/netscape/pkisilent/common/CMSLDAP.java b/base/silent/src/com/netscape/pkisilent/common/CMSLDAP.java
index c74cd94c6..cddb630da 100644
--- a/base/silent/src/com/netscape/pkisilent/common/CMSLDAP.java
+++ b/base/silent/src/com/netscape/pkisilent/common/CMSLDAP.java
@@ -41,7 +41,7 @@ import netscape.ldap.LDAPv2;
public class CMSLDAP {
- private String HOST, DN, BASEDN, PASSWORD;
+ private String HOST, DN, PASSWORD;
private int PORT;
private LDAPConnection conn = new LDAPConnection();
diff --git a/base/silent/src/com/netscape/pkisilent/common/CMSTask.java b/base/silent/src/com/netscape/pkisilent/common/CMSTask.java
index 948076fd6..953dcd25d 100644
--- a/base/silent/src/com/netscape/pkisilent/common/CMSTask.java
+++ b/base/silent/src/com/netscape/pkisilent/common/CMSTask.java
@@ -33,7 +33,6 @@ import com.netscape.pkisilent.argparser.StringHolder;
public class CMSTask {
private static String operation;
- private static String debug;
private static String serverRoot;
private Process p = null;
diff --git a/base/silent/src/com/netscape/pkisilent/common/ComCrypto.java b/base/silent/src/com/netscape/pkisilent/common/ComCrypto.java
index d1941ca30..e36966de1 100644
--- a/base/silent/src/com/netscape/pkisilent/common/ComCrypto.java
+++ b/base/silent/src/com/netscape/pkisilent/common/ComCrypto.java
@@ -57,6 +57,7 @@ import org.mozilla.jss.pkix.primitive.AlgorithmIdentifier;
import org.mozilla.jss.pkix.primitive.Name;
import org.mozilla.jss.pkix.primitive.SubjectPublicKeyInfo;
import org.mozilla.jss.util.Password;
+
import com.netscape.cmsutil.util.Utils;
/**
@@ -67,7 +68,9 @@ import com.netscape.cmsutil.util.Utils;
public class ComCrypto {
private String cdir, certnickname, keysize, keytype, tokenpwd;
- private String certpackage, pkcs10request;
+ @SuppressWarnings("unused")
+ private String certpackage;
+ private String pkcs10request;
private boolean debug = true;
private boolean DBlogin = false;
private boolean generaterequest = false;
@@ -82,7 +85,6 @@ public class ComCrypto {
public static CryptoManager manager;
public static CryptoToken token;
private CryptoStore store;
- private Password pass1 = null, pass2 = null;
private String bstr = "-----BEGIN NEW CERTIFICATE REQUEST-----";
private String blob, Blob1 = null;
diff --git a/base/silent/src/com/netscape/pkisilent/common/Con2Agent.java b/base/silent/src/com/netscape/pkisilent/common/Con2Agent.java
index bfaf1eb34..6d02fcd33 100644
--- a/base/silent/src/com/netscape/pkisilent/common/Con2Agent.java
+++ b/base/silent/src/com/netscape/pkisilent/common/Con2Agent.java
@@ -42,11 +42,12 @@ import org.mozilla.jss.util.Password;
public class Con2Agent implements SSLClientCertificateSelectionCallback,
SSLCertificateApprovalCallback {
- private int i, port;
- private String host, certdir, certnickname, tokenpwd, certname, query;
+ private int port;
+ @SuppressWarnings("unused")
+ private String certname;
+ private String host, certdir, certnickname, tokenpwd, query;
private String ACTIONURL;
- private BufferedReader stdin = null;
private StringBuffer stdout = new StringBuffer();
public Con2Agent() {
diff --git a/base/silent/src/com/netscape/pkisilent/common/DirEnroll.java b/base/silent/src/com/netscape/pkisilent/common/DirEnroll.java
index de331989b..809a65c5b 100644
--- a/base/silent/src/com/netscape/pkisilent/common/DirEnroll.java
+++ b/base/silent/src/com/netscape/pkisilent/common/DirEnroll.java
@@ -38,13 +38,12 @@ import org.mozilla.jss.ssl.SSLSocket;
public class DirEnroll extends TestClient {
- private int i;
private String Authenticator = "UserDir";
private int port;
+ @SuppressWarnings("unused")
private long elapsedTime;
private String importcert = "false";
- private boolean impStatus = false;
// Constructors
@@ -323,11 +322,7 @@ public class DirEnroll extends TestClient {
baseCert = baseCert.substring(n);
String tmp = baseCert.substring(0, baseCert.length() - 2);
- if (importCert(tmp)) {
- impStatus = true;
- }
- } else {
- impStatus = true;
+ importCert(tmp);
}
}
diff --git a/base/silent/src/com/netscape/pkisilent/common/Request.java b/base/silent/src/com/netscape/pkisilent/common/Request.java
index 7ee443f16..e0255ef59 100644
--- a/base/silent/src/com/netscape/pkisilent/common/Request.java
+++ b/base/silent/src/com/netscape/pkisilent/common/Request.java
@@ -52,9 +52,35 @@ public class Request extends TestClient {
// Cert Detail variables
- private String csrRequestorName, csrRequestorPhone, csrRequestorEmail, subject, subjectdn, reqStatus, certType;
- private String requestType, requestID, sslclient, clientcert, servercert, emailcert, objectsigningcert, sslcacert,
- objectsigningcacert, emailcacert, sigAlgo, totalRecord, validitylength, trustedManager;
+ private String csrRequestorName;
+ private String csrRequestorPhone;
+ private String csrRequestorEmail;
+ private String subject;
+ private String subjectdn;
+ private String reqStatus;
+ @SuppressWarnings("unused")
+ private String certType;
+ @SuppressWarnings("unused")
+ private String requestType;
+ private String requestID;
+ @SuppressWarnings("unused")
+ private String sslclient;
+ private String clientcert;
+ private String servercert;
+ private String emailcert;
+ private String objectsigningcert;
+ @SuppressWarnings("unused")
+ private String sslcacert;
+ @SuppressWarnings("unused")
+ private String objectsigningcacert;
+ @SuppressWarnings("unused")
+ private String emailcacert;
+ private String sigAlgo;
+ @SuppressWarnings("unused")
+ private String totalRecord;
+ @SuppressWarnings("unused")
+ private String validitylength;
+ private String trustedManager;
private int totalNumApproved = 0;
diff --git a/base/silent/src/com/netscape/pkisilent/common/ServerInfo.java b/base/silent/src/com/netscape/pkisilent/common/ServerInfo.java
index 5eccb1601..7ff761720 100644
--- a/base/silent/src/com/netscape/pkisilent/common/ServerInfo.java
+++ b/base/silent/src/com/netscape/pkisilent/common/ServerInfo.java
@@ -42,7 +42,6 @@ public class ServerInfo {
public static CMSProperties CMSprops = null;
// Private variables
- private int i;
public String CMSConfigFile, AdminConfigFile;
public ServerInfo() {
diff --git a/base/silent/src/com/netscape/pkisilent/common/TestClient.java b/base/silent/src/com/netscape/pkisilent/common/TestClient.java
index a58e88bd1..f3d96085d 100644
--- a/base/silent/src/com/netscape/pkisilent/common/TestClient.java
+++ b/base/silent/src/com/netscape/pkisilent/common/TestClient.java
@@ -48,7 +48,6 @@ public class TestClient implements SSLCertificateApprovalCallback {
public String query;
public boolean debug = false;
// Certificate nicknames to be used by Test Clients
- private int i;
private String testConfigFile;
public String caAgentCertName = "ca-agent";
@@ -62,6 +61,7 @@ public class TestClient implements SSLCertificateApprovalCallback {
private String admDN = "admin";
private String admDNPW = "admin";
private String TmpDir;
+ @SuppressWarnings("unused")
private String TestLogFile;
private String startupTests, cleanupTests;
diff --git a/base/silent/src/com/netscape/pkisilent/common/UserEnroll.java b/base/silent/src/com/netscape/pkisilent/common/UserEnroll.java
index 123054503..3f7f92791 100644
--- a/base/silent/src/com/netscape/pkisilent/common/UserEnroll.java
+++ b/base/silent/src/com/netscape/pkisilent/common/UserEnroll.java
@@ -38,9 +38,9 @@ import org.mozilla.jss.ssl.SSLSocket;
public class UserEnroll extends TestClient {
- private int i;
private String requestorName, requestorEmail, requestorPhone, requestorComments, requestId, certType, ssl_client;
private int port;
+ @SuppressWarnings("unused")
private long elapsedTime;
// Constructor
diff --git a/base/silent/src/com/netscape/pkisilent/common/checkRequest.java b/base/silent/src/com/netscape/pkisilent/common/checkRequest.java
index 8acbf1ca7..e785657c0 100644
--- a/base/silent/src/com/netscape/pkisilent/common/checkRequest.java
+++ b/base/silent/src/com/netscape/pkisilent/common/checkRequest.java
@@ -38,16 +38,15 @@ import org.mozilla.jss.ssl.SSLSocket;
public class checkRequest extends TestClient {
- private int i;
private String certfile, importcert = "false", certnickname, serialNumber, ldapformat;
private String requestId;
private String reqStatus = "false";
private String pkcsCert, baseCert, ACTION_STRING, issuer, subject, AUTH = "ca";
private int port;
- private boolean impStatus = false;
private int type = 1;
+ @SuppressWarnings("unused")
private long elapsedTime;
private String host;
@@ -438,8 +437,6 @@ public class checkRequest extends TestClient {
GregorianCalendar begin = new GregorianCalendar();
- impStatus = false;
-
// SSLSocket socket = new SSLSocket(host,port);
SSLSocket socket = new SSLSocket(host, port, null, 0, this, null);