diff --git a/base/java-tools/src/com/netscape/cmstools/cli/MainCLI.java b/base/java-tools/src/com/netscape/cmstools/cli/MainCLI.java index ac71b5b331a..ff107bdd0fd 100644 --- a/base/java-tools/src/com/netscape/cmstools/cli/MainCLI.java +++ b/base/java-tools/src/com/netscape/cmstools/cli/MainCLI.java @@ -63,7 +63,7 @@ import com.netscape.cmstools.system.SecurityDomainCLI; import com.netscape.cmstools.tks.TKSCLI; import com.netscape.cmstools.tps.TPSCLI; -import com.netscape.cmstools.user.UserCLI; +import com.netscape.cmstools.user.ProxyUserCLI; import com.netscape.cmsutil.crypto.CryptoUtil; import com.netscape.cmsutil.crypto.CryptoUtil.SSLVersion; @@ -106,7 +106,7 @@ public MainCLI() throws Exception { addModule(new ProxyCLI(new GroupCLI(this), "ca")); addModule(new ProxyCLI(new KeyCLI(this), "kra")); addModule(new ProxyCLI(new SecurityDomainCLI(this), "ca")); - addModule(new ProxyCLI(new UserCLI(this), "ca")); + addModule(new ProxyUserCLI(this)); addModule(new CACLI(this)); addModule(new KRACLI(this)); diff --git a/base/java-tools/src/com/netscape/cmstools/user/ProxyUserCLI.java b/base/java-tools/src/com/netscape/cmstools/user/ProxyUserCLI.java new file mode 100644 index 00000000000..a78f8815f00 --- /dev/null +++ b/base/java-tools/src/com/netscape/cmstools/user/ProxyUserCLI.java @@ -0,0 +1,38 @@ +// --- BEGIN COPYRIGHT BLOCK --- +// This program is free software; you can redistribute it and/or modify +// it under the terms of the GNU General Public License as published by +// the Free Software Foundation; version 2 of the License. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. +// +// You should have received a copy of the GNU General Public License along +// with this program; if not, write to the Free Software Foundation, Inc., +// 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. +// +// (C) 2018 Red Hat, Inc. +// All rights reserved. +// --- END COPYRIGHT BLOCK --- + +package com.netscape.cmstools.user; + +import com.netscape.cmstools.cli.CLI; +import com.netscape.cmstools.cli.ProxyCLI; + +/** + * @deprecated pki user has been deprecated. Use pki <subsystem>-user instead. + */ +@Deprecated +public class ProxyUserCLI extends ProxyCLI { + + public ProxyUserCLI(CLI parent) { + super(new UserCLI(parent), "ca"); + } + + public void execute(String[] args) throws Exception { + System.err.println("WARNING: pki user has been deprecated. Use pki -user instead."); + super.execute(args); + } +}