473,799 Members | 3,001 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to post a SSL web-form from code without losing session?

1 New Member
Hello,

I've been trying for some time now, to post some information to a SSL web page, when the first step is getting the page, and the second step is filling the form and posting to the same page.

I've tried to do this using HttpWebRequest and HttpWebResponse ,
Passing the CookieContainer from one to another in order to maintain session consistency.

Unfortunately, the page re-renderes at the second step, as if i just loaded it for the first time (the response does not redirect me to the result page, but to the form page itself. actually, i get the same response for both my requests.)

This is probably because the second request is not included in the same session as the initial request.

When i used a sniffer to check the difference between the code performance and a regular browser performance, i noticed some cookies (with the word 'session' in its names) were missing when i post from code. my only guess is that the web page is using Javascript to add the session cookie.

How can i simulate a web browser good enough, so this page would recognize me the second time i request it?

Is there any workaround to use the Windows.Forms.W ebBrowser ActiveX control? (I am writing an asp.net service)

Note that the POST string (key=value&key= value...) is computed perfectly by my code.

Any answers would be very appreciated.
Thanks ahead,
YAT.
Jul 16 '09 #1
0 1354

Sign in to post your reply or Sign up for a free account.

Similar topics

49
2660
by: Lauren Wilson | last post by:
Hi folks, Just wondered if, for the sake of clarity, it is permissible to post small image files of an error box along with a text message about a problem with Access?
2
3713
by: Salim Afþar | last post by:
Hi, Can I post a XML file or data to a site with .NET? Thanks in advance, Salim
2
3690
by: Taishi | last post by:
New user of SQL Everything is on the same machine My error is close to the bottom After reading it today, I can see there is a problem with 2 dbases 'PUBS' and 'Master' There are also some comments from the group: ---microsoft.public.sqlserver.odbc-- subject: Permission Denied -- Thanks for help guys I was able to find a trial version of the Enterprise Manager.
3
1420
by: Jon Maz | last post by:
Hi All, I'm at the "Hello World" stage of learning about web services (just to warn you), and have what is I think a simple question. I have created a basic HelloWorld.asmx, which has the following Web Method: public string HelloWorldDemo(string stuff) {
0
3810
by: CFloyd | last post by:
I have a web service client that sends an XML string to the web service for processing. I alos have to add some headers to the post. I first establish the baseuri as === baseuri = new Uri("http://192.168.100.67/mimservice/mimosawebservice.asmx/MWS32Service === Then I pass the uri and the xml string along to another method the includes: === HttpWebRequest req = (HttpWebRequest)HttpWebRequest.Create( url);
9
3101
by: c676228 | last post by:
Hi, I am new to this discussion forum. I started to post questions on this forum since this Jan. and got many good responses and I am very appreciated to those who are willing to help with their expertise. That save me a lot of time and stress. I want to rate the post, but I only see questions "is this post helpful" and " why should I rate a post" link. I didn't see any thing "rate the post" link. I already sign into the community...
1
2498
by: arfeengodil | last post by:
Hi, I need to have a web application such that other applications should be able to do send data to it using HTTP Post. So I created a ASP.NET web service and defined a web method for other people to POST data to. But the string returned back to the person who sent the POST message is embedded in XML Tags. for example http://mydomain.com/webserver.asmx/SendData?parameter=Hello World
0
1334
by: phaniva | last post by:
Hi, I have a ASP .Net 2.0 web service on Win 2k SP4. One of the web methods expects a string as input like public string mymethod(string inp); I am trying to invoke this web method through HTTP post (I have to do this as I have an old java client). When I post large string as input, my input gets truncated and the web service always sees about 56k only. I was posting something like 112k string.
3
12595
by: Jason Zhou | last post by:
I understand how to consume a web service by registering it as a web reference in my project, but how to use HTTP Post to call a web service? For example I have a web service called TestService, and have a WebMethod called TestMethod, it has a string type parameter A, anybody can explain a little bit on how to call it from http post? Thanks! Jason
2
5442
by: =?Utf-8?B?cGhlbmdsYWk=?= | last post by:
I am not sure really how to explain this but here goes. I am creating some new web services and I want to be able to post data like the following: <Data> <some value>1</some value> <more info>2</more info> </Data>
0
10491
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10268
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9079
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7571
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5467
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5593
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4146
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3762
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2941
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.