Page 1 of 1

Session Cookie in Simulator

Posted: Mon Oct 28, 2019 5:40 am
by abeggchr
Main question: How can I use a HTTP session on the server side in the simulator?

Context:
  • I am asking here, because you might have encountered this scenario already.
  • I am currently checking the feasibility of a migration of our Silverlight application with CSHTML5.
  • Our application is mainly server-side rendered but is has a lot of Silverlight widgets in popups (i.e. other browser windows).
  • Opening the application you create a HTTP session in the server-side rendered pages which is then used in the Silverlight widgets
  • While developing, I use the CSHTML5 simulator to use breakpoints. But on the same time I also need the application to use that HTTP session which is used for each HTTP request based on the value in the Cookie field of the request

Based on what I experienced so far, my approach would be:
  • Wire all calls from the simulator over a HTTP proxy
  • Program the HTTP proxy to add or replace the Set-Cookie header value in the HTTP request

Can you confirm, that this is a feasible way?
Do you know a simpler solution?