From 7e362c86586ce34a1ad9782cb62865cb349c8d0e Mon Sep 17 00:00:00 2001 From: "Endi S. Dewata" Date: Tue, 12 Sep 2023 09:47:42 -0500 Subject: [PATCH] Update OCSPTokenAuthenticateAdmin to use @WebServlet --- base/ocsp/shared/webapps/ocsp/WEB-INF/web.xml | 18 ------------------ .../csadmin/OCSPTokenAuthenticateAdmin.java | 13 +++++++++++++ 2 files changed, 13 insertions(+), 18 deletions(-) diff --git a/base/ocsp/shared/webapps/ocsp/WEB-INF/web.xml b/base/ocsp/shared/webapps/ocsp/WEB-INF/web.xml index 9f995ae2c5f..4c34e7cb6a8 100644 --- a/base/ocsp/shared/webapps/ocsp/WEB-INF/web.xml +++ b/base/ocsp/shared/webapps/ocsp/WEB-INF/web.xml @@ -7,24 +7,6 @@ Online Certificate Status Protocol Manager - - ocspTokenAuthenticate-admin - com.netscape.cms.servlet.csadmin.OCSPTokenAuthenticateAdmin - GetClientCert - false - authority - ocsp - ID - ocspTokenAuthenticate - interface - admin - - - - ocspTokenAuthenticate-admin - /admin/ocsp/tokenAuthenticate - - Account Services diff --git a/base/ocsp/src/main/java/com/netscape/cms/servlet/csadmin/OCSPTokenAuthenticateAdmin.java b/base/ocsp/src/main/java/com/netscape/cms/servlet/csadmin/OCSPTokenAuthenticateAdmin.java index 5d7288075fe..bd636aac0bc 100644 --- a/base/ocsp/src/main/java/com/netscape/cms/servlet/csadmin/OCSPTokenAuthenticateAdmin.java +++ b/base/ocsp/src/main/java/com/netscape/cms/servlet/csadmin/OCSPTokenAuthenticateAdmin.java @@ -17,6 +17,19 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.cms.servlet.csadmin; +import javax.servlet.annotation.WebInitParam; +import javax.servlet.annotation.WebServlet; + +@WebServlet( + name = "ocspTokenAuthenticate-admin", + urlPatterns = "/admin/ocsp/tokenAuthenticate", + initParams = { + @WebInitParam(name="GetClientCert", value="false"), + @WebInitParam(name="authority", value="ocsp"), + @WebInitParam(name="ID", value="ocspTokenAuthenticate"), + @WebInitParam(name="interface", value="admin") + } +) public class OCSPTokenAuthenticateAdmin extends TokenAuthenticate { private static final long serialVersionUID = 1L; }