简体   繁体   中英

Cookie without the secure flag jboss 5.1

Hello there..

  I am trying to fixing Cookie without the secure flag in jboss 5.1

  <myJBossServerInstancePath>/deploy/jbossweb.sar/context.xml

 and also added 

     response.setHeader("SET-COOKIE", "JSESSIONID=" +  session.getId() + ";httpOnly");
response.setHeader("SET-COOKIE", "JSESSIONID=" + session.getId() + "; secure");

still secure flag missing. My project is Jboss 5.1 and java 1.6,Where is my mistake?

在此处输入图片说明

Open {JBOSS_HOME}/server/SERVER_NAME/deploy/jbossweb.sar/contex.xml

Add <SessionCookie secure="true" httpOnly="true" />

And restart the server

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM