提交 9eb6cee1 编写于 作者: K kohsuke

Fixed a security issue. The security should be on by default. (#926)


git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@5364 71c3de6d-444a-0410-be80-ed276b4c234a
上级 7f2d4faf
......@@ -28,7 +28,7 @@ public final class BuildAuthorizationToken {
}
public static void startBuildIfAuthorized(BuildAuthorizationToken token, BuildableItem job, StaplerRequest req, StaplerResponse rsp) throws IOException, ServletException {
if(token==null || token.authorizedToStartBuild(req,rsp)) {
if(!Hudson.getInstance().isUseSecurity() || (token!=null && token.authorizedToStartBuild(req,rsp))) {
job.scheduleBuild();
rsp.forwardToPreviousPage(req);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册