Skip to content

Commit

Permalink
Update RemoveCAServlet to use @WebServlet
Browse files Browse the repository at this point in the history
  • Loading branch information
edewata committed Sep 9, 2023
1 parent 4ff5ab7 commit 0ee1361
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 29 deletions.
27 changes: 0 additions & 27 deletions base/ocsp/shared/webapps/ocsp/WEB-INF/web.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,28 +56,6 @@
<init-param><param-name> AuthMgr </param-name>
<param-value> certUserDBAuthMgr </param-value> </init-param>
</servlet>

<servlet>
<servlet-name> ocspRemoveCA </servlet-name>
<servlet-class> com.netscape.cms.servlet.ocsp.RemoveCAServlet </servlet-class>
<init-param><param-name> GetClientCert </param-name>
<param-value> true </param-value> </init-param>
<init-param><param-name> AuthzMgr </param-name>
<param-value> BasicAclAuthz </param-value> </init-param>
<init-param><param-name> interface </param-name>
<param-value> agent </param-value> </init-param>
<init-param><param-name> authority </param-name>
<param-value> ocsp </param-value> </init-param>
<init-param><param-name> ID </param-name>
<param-value> ocspRemoveCA </param-value> </init-param>
<init-param><param-name> AuthMgr </param-name>
<param-value> certUserDBAuthMgr </param-value> </init-param>
<init-param><param-name> resourceID </param-name>
<param-value> certServer.ocsp.ca </param-value> </init-param>
<init-param><param-name> templatePath </param-name>
<param-value> /agent/ocsp/removeCA.template </param-value> </init-param>
</servlet>


<servlet>
<servlet-name> ocspReadAddCAPage </servlet-name>
Expand Down Expand Up @@ -265,11 +243,6 @@
<url-pattern> /agent/ocsp/addCRL.html </url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name> ocspRemoveCA </servlet-name>
<url-pattern> /agent/ocsp/removeCA </url-pattern>
</servlet-mapping>

<servlet-mapping>
<servlet-name> ocspReadAddCAPage </servlet-name>
<url-pattern> /agent/ocsp/addCA.html </url-pattern>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@
import javax.servlet.ServletConfig;
import javax.servlet.ServletException;
import javax.servlet.ServletOutputStream;
import javax.servlet.annotation.WebInitParam;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

Expand All @@ -48,9 +50,21 @@

/**
* Configure the CA to no longer respond to OCSP requests for a CA
*
* @version $Revision: 1274 $ $Date: 2010-09-07 22:14:41 -0700 (Tue, 07 Sep 2010) $
*/
@WebServlet(
name = "ocspRemoveCA",
urlPatterns = "/agent/ocsp/removeCA",
initParams = {
@WebInitParam(name="GetClientCert", value="true"),
@WebInitParam(name="AuthzMgr", value="BasicAclAuthz"),
@WebInitParam(name="interface", value="agent"),
@WebInitParam(name="authority", value="ocsp"),
@WebInitParam(name="ID", value="ocspRemoveCA"),
@WebInitParam(name="AuthMgr", value="certUserDBAuthMgr"),
@WebInitParam(name="resourceID", value="certServer.ocsp.ca"),
@WebInitParam(name="templatePath", value="/agent/ocsp/removeCA.template")
}
)
public class RemoveCAServlet extends CMSServlet {

public static org.slf4j.Logger logger = org.slf4j.LoggerFactory.getLogger(RemoveCAServlet.class);
Expand Down

0 comments on commit 0ee1361

Please sign in to comment.