What are the two main methods to enumerate existing servlets in a Jetty server for memory shell placement?

First, you can call `getServletRegistrations()` through the request's `ServletContext` to list registered servlets. Second, you can traverse threads to find the `WebAppClassLoader`, access the `_servletHandler`, and directly read the `_servlets` field via reflection. Both approaches are detailed in the enumeration section of the [Jetty Servlet memory shell article](/news/java-exploitation-techniques-jetty-servlet-type-memory-shell).