Java EE – domain level session cookies on multiple domains

If you want ColdFusion to create session cookies as domain level cookies, for example bar. Com instead of foo bar. Com then you can go to jrun web Configuration in XML: –

<session-config>    
   <cookie-config>
          <active>true</active>
          <cookie-domain>.bar.com</cookie-domain>
   </cookie-config>
  <persistence-config>
    <active>false</active>
  </persistence-config>
</session-config>

However, this is an instance wide setting, so if you want to run two applications on this instance, or if you really want to run on an application with one or more different top-level domains, one of them will have an invalid session

Is there any way to add multiple domains to jrun web XML and let it select the relevant domain?

thank you.

Solution

I managed to find the DTD for jrun web XML (link @ vertex points to an invalid Macromedia URL)

This specifies that there can only be one node in < cookie domain > XML I also tested a list of domain names, such as:

<cookie-domain>.domainA.com,.domainB.com</cookie-domain>

It doesn't work either

This is not an absolute answer, but I doubt it may be impossible (!), And certainly not through jrun web XML (I want to answer at least one of your questions)

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>