mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-08 01:26:03 +00:00
don't let the image be cached (#1167)
git-svn-id: https://hudson.dev.java.net/svn/hudson/trunk/hudson/main@6593 71c3de6d-444a-0410-be80-ed276b4c234a
This commit is contained in:
1 parent
411958ed40
commit
fdc824ac5e
1 file changed
+1
@@ -120,6 +120,7 @@ public abstract class SecurityRealm implements Describable<SecurityRealm>, Exten
|
||||
public final void doCaptcha(StaplerRequest req, StaplerResponse rsp) throws IOException {
|
||||
String id = req.getSession().getId();
|
||||
rsp.setContentType("image/png");
|
||||
rsp.addHeader("Cache-Control","no-cache");
|
||||
ImageIO.write( CaptchaService.INSTANCE.getImageChallengeForID(id), "PNG", rsp.getOutputStream() );
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user