473,326 Members | 2,099 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

WebException.TrustFailure from HttpwebRequest

Hello,
I am getting a WebException.TrustFailure when I call
HttpwebRequest.GetResponse. Anybody has an idea how to
resolve this issue? The code works correctly in other
sites. I noticed that, when I browse to the site using
IE, I am getting a security Alert messagebox prompting to
accept the certificate. Is there a relationship between
this two problems? How can I resolve it?

Thanks
-GJK
Nov 17 '05 #1
2 3956
"G Joseph" spoke:
Hello,
I am getting a WebException.TrustFailure when I call
HttpwebRequest.GetResponse. Anybody has an idea how to
resolve this issue? The code works correctly in other
sites. I noticed that, when I browse to the site using
IE, I am getting a security Alert messagebox prompting to
accept the certificate. Is there a relationship between
this two problems? How can I resolve it?


Yes, that's likely a problem for your code as well. It seems the
framework's default certificate policy rejects that particular
certificate. Check out

http://msdn.microsoft.com/library/de...l=/library/en-
us/cpref/html/frlrfSystemNetServicePointManagerClassCertificateP olicyTop
ic.asp

Cheers,
--
Joerg Jooss
jo*********@gmx.net
Nov 17 '05 #2
Hello Joseph,

Please post here if the problem is not resolved. Thanks.

Best regards,
Yanhong Huang
Microsoft Online Partner Support

Get Secure! - www.microsoft.com/security
This posting is provided "AS IS" with no warranties, and confers no rights.

--------------------
!Content-Class: urn:content-classes:message
!From: "G Joseph" <jo********@hotmail.com>
!Sender: "G Joseph" <jo********@hotmail.com>
!Subject: WebException.TrustFailure from HttpwebRequest
!Date: Sat, 19 Jul 2003 14:59:03 -0700
!Lines: 11
!Message-ID: <01****************************@phx.gbl>
!MIME-Version: 1.0
!Content-Type: text/plain;
! charset="iso-8859-1"
!Content-Transfer-Encoding: 7bit
!X-Newsreader: Microsoft CDO for Windows 2000
!X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300
!Thread-Index: AcNOQPfJEKecHaS1SeyTzhfQ2BoYsA==
!Newsgroups: microsoft.public.dotnet.framework.aspnet
!Path: cpmsftngxa06.phx.gbl
!Xref: cpmsftngxa06.phx.gbl microsoft.public.dotnet.framework.aspnet:160529
!NNTP-Posting-Host: TK2MSFTNGXA13 10.40.1.165
!X-Tomcat-NG: microsoft.public.dotnet.framework.aspnet
!
!Hello,
!I am getting a WebException.TrustFailure when I call
!HttpwebRequest.GetResponse. Anybody has an idea how to
!resolve this issue? The code works correctly in other
!sites. I noticed that, when I browse to the site using
!IE, I am getting a security Alert messagebox prompting to
!accept the certificate. Is there a relationship between
!this two problems? How can I resolve it?
!
!Thanks
!-GJK
!
Nov 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Jonathan Crowther | last post by:
On one PC the following test code results in an error on the GetResponse line while it works OK on another PC. The only difference that I am aware of is that the one that works is XP while the...
0
by: yariv | last post by:
Hello All, I am having a very strange problem. while trying to access http page on the web using HTTPWebRequest Class, I happen to have some problems at specific machines. The exception I...
0
by: Matt | last post by:
(can't find any of my previous post for same issue. please CC to my email address as well. Thanks!) Hi all, What is the possible reason that HttpWebRequest.GetRequestStream() may hang there...
1
by: Marcos Martínez | last post by:
I am trying to generate and to consume a file RSS dinamicamente. I generate it correctly, if I call from the explorer (http://localhost/Prueba/rss.aspx) or an application client RSS Bandit, for...
1
by: etantonio | last post by:
Good morning, I've a problem, in the past I translate my site from google or altavista with a code similar to this : <%@ Page Language="c#" Trace="true" Debug="true" %> <%@ import...
1
by: Tim Reynolds | last post by:
Team, From a windows service, we consume a web service on another server and occasionally receive System.Net.WebException: The underlying connection was closed:. For some clients we call, we do...
1
by: ibaldwinjr | last post by:
Hi, I am trying to get a response from a URL using the HttpWebRequest object. this is my code below. httpRequest = (HttpWebRequest) WebRequest.Create(myurl); httpRequest.Method = "GET";...
4
by: =?Utf-8?B?UGhpbGlwIEs=?= | last post by:
Simplifying the code a bit its like this: try { myRemotingObj.Myfunction(string, string,string,string,timeSpan) } catch(WebException) { commsUp = false; }
3
sid0404
by: sid0404 | last post by:
Hi I am new to the programming in c#, I have an application where I need to get data from a website now I am getting an error message if I give the input as two strings, say Sun Microsystems while...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.