Skip to content

Commit

Permalink
[FIXED JENKINS-26382] Allow admin signup from /manage as well
Browse files Browse the repository at this point in the history
  • Loading branch information
daniel-beck committed Jan 12, 2015
1 parent 9309cd3 commit 8d1968f
Showing 1 changed file with 2 additions and 1 deletion.
Expand Up @@ -697,7 +697,8 @@ public void init(FilterConfig config) throws ServletException {
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException {
HttpServletRequest req = (HttpServletRequest) request;

if(req.getRequestURI().equals(req.getContextPath()+"/")) {
/* allow signup from the Jenkins home page, or /manage, which is where a /configureSecurity form redirects to */
if(req.getRequestURI().equals(req.getContextPath()+"/") || req.getRequestURI().equals(req.getContextPath() + "/manage")) {
if (needsToCreateFirstUser()) {
((HttpServletResponse)response).sendRedirect("securityRealm/firstUser");
} else {// the first user already created. the role of this filter is over.
Expand Down

0 comments on commit 8d1968f

Please sign in to comment.