79301759

Date: 2024-12-22 21:29:57
Score: 4.5
Natty:
Report link

Yes I am also facing this issue

This issue is showing up when I expose my local host to the public through some tunneling.I am using Rear Application Front End and Back End Server through Node JS. Front End Server is working properly.But the cookies created on the back-end server are not being received correctly through the public tunnel.This is because the tunnel is only exposing the front end properly.This problem is occurring because the backend server is hosted on the same system.This is not a correct origin error.This is a tunneling issue. There is no way to publish cookies outside the local host, i.e., the cookie in the cookie. If it can be done, it may be possible.In my system, the cookies are repeatedly being stored on the local host. Because the cookies are not being transferred through the tunnel and the system is experiencing the cookies as local host.

res.cookie("token", token, {
  httpOnly: true,  // Prevents JavaScript access
  secure: true,    // Ensures cookies are sent over HTTPS
  sameSite: "None",// Required for cross-origin requests
  domain: ".example.com", // Replace with your domain (e.g., example.com)
});

Here I have tried using two tunnels. One for the back end and another for the front end, but it is not working properly. Here is an .example.com Used as a subdomain where it is targeted or located to a main domain stream but despite that it is not sending the token anywhere other than the local host.This means that there is no way to pass the token through the tunnel. It is stored only on the local host. This is a major issue.If anyone has an answer, please help.

Question

How to pass cookies cross-origin to a public URL through a tunnel

cross origin error in react js using cloudflear tunnel and also my server hosted in local host port 4000 and my react application host in

cloudflared tunnel --url http://localhost:4000

Remember the proxy is localhost:4000 And this is a local host back end server only. The front end server is created through a cloud fair tunnel, the back end server is being used directly.But even though everything is working properly, when receiving cookies, it is receiving a localhost token. I need the token to be generated in my Cloud Fair public domain.Additionally, using any other medium is showing a cross-origin error.

Reasons:
  • Blacklisted phrase (0.5): I need
  • Blacklisted phrase (1): also facing this
  • Blacklisted phrase (0.5): not working properly
  • RegEx Blacklisted phrase (3): please help
  • Long answer (-1):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: D. D. I. STUDIO