0

I have an application running on 192.168.1.100. This application serves a page in which an iframe is embedded which is basically another application running on totally different ip e.g. 10.0.0.1.

The issue is whenever user performs a login inside iframe a cookie is set but it is not sent back to 10.0.0.1 for subsequent requests.

What i am trying to achieve is this even possible?

Any help in this regard is appreciated.

Dakait
  • 2,531
  • 1
  • 25
  • 43
  • 1
    Perhaps this is relevant: [Set cookie on IP based URL](https://stackoverflow.com/questions/25989201/set-cookie-on-ip-based-url) – KIKO Software May 01 '19 at 19:39
  • You cannot share cookies between different domains. See: https://stackoverflow.com/questions/3342140/cross-domain-cookies – really_operator May 01 '19 at 19:40
  • @really_operator its not about cross domain cookies :) – Dakait May 02 '19 at 20:53
  • @KIKOSoftware thanks for your time, link which you shared was helped in understanding the problem. – Dakait May 02 '19 at 20:54
  • @dakait sure it is. You have one domain (192.168.1.100) loading an iframe from another domain (10.0.0.1). They are just IP addresses in this case instead of named domains. – really_operator May 02 '19 at 21:43
  • @really_operator correct, but each domain (IP) is handling its own cookie(s) they are not sent cross-domain(IP) – Dakait May 02 '19 at 22:17
  • An iframe on a domain does not count as the same domain if it originates from a different domain. You cannot read cookies across domains, and this includes iframes embedded on the page that are from a different domain. – really_operator May 03 '19 at 05:36
  • @really_operator totally agree what you said. My question was not related to reading cross domain cookies :) – Dakait May 03 '19 at 10:15

0 Answers0