.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

WCF client fails with The message received was unexpected or badly formatted and Decrypt failed with

Posted By:      Posted Date: December 04, 2010    Points: 0   Category :WCF

I have written a console mode WCF client that contacts an Apache based web service that uses OpenSSL  0.9.8 tls or ssl3.
The WCF client uses client certificates on Windows 2008 SP2 x64. The client had been running for months with no problem, and then I started getting the errors below around Nov 8 2010 (below).
I have done my best to include all the details. Please read carefully.
The relevant traces, exceptions, code and config are included in this post.

1.) Fix it.
2.) Find out what 0X80090326 means.
3.) Find out what policies/acl's apply to the situation

The only thing I can be sure of that did not change is the code.

Can anyone point me toward the next step?

- The program executes as a local user (non-domain) that is in the Local Administrators group.
- I can display the server url using IE and Firefox, provided I have the certs installed for personal use.
- The certificates are installed in the LocalMachine store in "TrustedPeople" - NOT the user's location, the machine location. The local user finds the proper key, as the trace below will show.

What I have googled for:
- 0X80090326
- Decrypt failed with error 0X800

View Complete Post

More Related Resource Links

Server 2008 R2 -> Failed to decrypt using provider 'RsaProtectedConfigurationProvider'. Error mess


So I am using the aspnet_regiis.exe tool to encrypt sections of the web.config in my asp.net applications and services.  I have done this for years successfully on Windows Server 2003 (IIS 6).  However I just moved some apps over to Windows Server 2008 R2 (with IIS 7.5) and I am now receiving the following error at runtime:

"Server was unable to process request. ---> Failed to decrypt using provider 'RsaProtectedConfigurationProvider'. Error message from the provider: Bad Data."

Now I am quite familiar with this process and am stumped at what I have missed this time around.  I have done ALL of the following which typically suffices for the process on the server. PLEASE READ ALL AND DO NOT PROVIDE RESPONSES OR LINKS FOR THINGS I HAVE ALREADY DONE Thanks!!  Wink

  1. Imported the keys to the server using aspnet_regiis -pi  Result: Success
  2. Given FULL permission (using -full switch) using aspnet_regiis -pa to ALL of the following accounts  Result: Success
    1. How to Get Error Message from Job History if SQLAgent Job Fails

      Hello, I am using "last_run_outcome" value = 0 (fail) or 1 (pass)  from sysjobsteps to identify if the job has failed. So if the job has failed, can I get the Error Message from SQL ? (which we can see in Job History). Thanks, Prabhat

SQL Server Express 2008 Setup fails. Support Rule "Restart Computer" Failed

Hi, I have been trying to install SQL Server Express for most of the day now without any luck.  Whatever I do setup fails at the stage of Setup Support Rules, Rule "Restart Computer" - Failed.  Needles to say I have restarted (several times!) and I have tried downloading  and installing the "Advanced", "Tools" and "Basic" versions, all give the same error.  Trying a repair does the same.  I have been searching the net for an answer without success, any help would be MUCH appreciated. Further info: I am trying to install a stand-alone installation on to a single PC running under XP SP 3 with .NET 3.5 SP1 installed.  The PC did have some earler versions of SQL server installed but I (?hopefully?) removed all of these through Control Panel.  Before trying the first SQL install I installed Windows installer 4.5 and PowerShell 1.0 as per the Microsoft Instructions. Running SQL Server Configuration Manager results in an error (MMC could not create the snap-in. The snap in might not have been installed correctly).  A directory structure for SQL server exists in "Program Files".  Services MSC shows SQL Server (SQLEXPRESS) as Automatic Statup (not running).  Trying to start this manually gives error 14001: "application configuration incorrect - re-install to fix" .......... Which is precisely what I'm trying to do.........:(

MessageSecurityException "Identity check failed for outgoing message" when using custom endpointaddr

Hi! I am currently developing a WCF service which will use ASP.NET Membership and RoleProvider as authentication/authorization. I followed the description in on this page http://msdn.microsoft.com/en-us/library/ff647294.aspx to do this, and everything works as expected when I try add a reference to my development service and uses that without any interaction. But, I want to be able to override the enpoint address in code since the server may be placed on other servers, but when I do this in my code (with the same enpointAddress stated in the client wcf file for testing purpose) I get a MessageSecurityException with this information: "Identity check failed for outgoing message. The expected DNS identity of the remote endpoint was 'localhost' but the remote endpoint provided DNS claim 'MyCert'. If this is a legitimate remote endpoint, you can fix the problem by explicitly specifying DNS identity 'MyCert' as the Identity property of EndpointAddress when creating channel proxy." I have search the net for information about this, and found that the only thing I had to do was to add a <dns value="MyCert" /> to my client wcf configuration, and everything should work. But it doesn't, I still get the same error. My server behavior configuration looks like this: <serviceCredentials> <serviceCertificate findValue="CN=MyCert" />

Failed to add relation(s) Unexpected error

I am getting the following error message when using the Data Source Configuration Wizard in Visual Studio 2008 to create a connection to a MySQL database.Failed to add relation(s) Unexpected error.I have found a KB article (KB954740) on the problem, but can not seem to find the fix.I have just started using Visual Studio but I am knowledgeable with VB from many years of work in Microsoft Access.Thanks in advance for any help you may provide,Ricky HicksMicrosoft Access MVP 2005, 2006, 2007, 2008, 2009 Ricky Hicks

Message: "Microsoft .NET Framework 3.5 Installation Has Failed"

On a Windows 2003 R2 x64 server, I have been unable to install SQL Server 2008 Enterprise Edition x64. When running setup.exe, I almost instantaneously receive the following Microsoft SQL Server Setup error:"Microsoft .NET Framework 3.5 installation has failed.SQL Server 2008 Setup requires .NET Framework to be installed."What does not make sense is that I successfully downloaded .NET Framework 3.5 from the Microsoft download site (published 8/11/2008) prior to the SQL Server 2008 installation attempt.http://www.microsoft.com/downloads/details.aspx?familyid=ab99342f-5d1a-413d-8319-81da479ab0d7&displaylang=enI do need to note that a few nights ago, prior to downloading the framework (3.5 SP1), I ran the SQL Server 2008 setup executable. I was prompted that in order to install SQL Server 2008, the setup program needed to first install .NET 3.5 SP1 and Windows Installer 4.5. I let the .NET 3.5 SP1 install run for about 1.5 to 2 hours and cancelled (now I wish I had just let it go).It is my understanding (correct me if I am wrong) that the SQL Server 2008 setup program initially checks for any pre-RTM versions of .NET 3.5 SP1 Framework. If one is found, it is then supposed to guide the user through both the installation of the .NET 3.5 SP1 Framework and Windows Installer 4.5. I have removed .NET 3.5 SP1 Framework (Add/Remove programs) and rebooted. However, upon runni

Crawling fails with 404 error message, but the IIS log tell a different story

In our clean SP2010 install, crawling stops immediately, just logging a single error message:   The object was not found. ( Error from SharePoint site: HttpStatusCode NotFound The request failed with HTTP status 404: Not Found. )   Looking at the IIS log does, surprisingly, not  confirm this. Here are all the log entries related to crawling:   #Fields: date time s-ip cs-method cs-uri-stem cs-uri-query s-port cs-username c-ip cs(User-Agent) sc-status sc-substatus sc-win32-status time-taken 2010-09-01 15:20:42 GET / - 80 - Mozilla/4.0+(compatible;+MSIE+4.01;+Windows+NT;+MS+Search+6.0+Robot) 401 1 2148074254 15 2010-09-01 15:20:42 GET / - 80 0#.w|global\cre-nhk Mozilla/4.0+(compatible;+MSIE+4.01;+Windows+NT;+MS+Search+6.0+Robot) 200 0 0 46 2010-09-01 15:20:42 GET /Pages/Forside.aspx - 80 0#.w|global\cre-nhk Mozilla/4.0+(compatible;+MSIE+4.01;+Windows+NT;+MS+Search+6.0+Robot) 200 0 995 937 2010-09-01 15:20:43 GET /_vti_bin/sitedata.asmx - 80 - Mozilla/4.0+(compatible;+MSIE+4.01;+Windows+NT;+MS+Search+6.0+Robot) 401 1 2148074254 0 2010-09-01 15:20:43 GET /_vti_bin/sitedata.asmx - 80 0#.w|global\cre-nhk Mozilla/4.0+(comp

Why saving to SharePoint library fails from Office 2007 client?

I have test environment where I have successfully able to create Excel document with the client and publish it to the SharePoint 2010 sites. In the test environment I was using my personal Windows 7 workstations for Office 2007. When I repeat process in the customer environment, it fails. I'm using front-end Windows Server 2008 machine for Office 2007. I'm using admin account and machine is certaily in the domain. 1. Open Excel 2007 and modify it 2. Publish 3. Document Publish Server 4. Input http://intra I get error: This location cannot open with program Why the error? What do I miss? Is the Windows Server 2008 the problem?Kenny_I

Error: ASP.NET Ajax client-side framework failed to load.

Getting some errors after implementing the calendar control.  Error: ASP.NET Ajax client-side framework failed to load.  Here are some screenshots of the relevant info:   Here's the scenario...  I compile code locally, view the pages in a browser locally, and it all works fine.  Another developer sits down at my machine, logs in with AD account (which create a local profile for his account on my machine), and gets these errors when viewing my locally compiled code.  He then compiles the same code on my machine again just for a test, but still gets the same errors.  Can anyone come up with any good reasons for this behavior?  I put a call into MS and they suggested creating a new profile for the other developer with the errors since this appeared to be profile specific.  Tried doing that with the same results.  Help!        

ASP.NET Ajax client-side framework failed to load = No Ribbon :( JS errors on Default and at Central

Looking for suggestions to why my ribbon crashed, and I'm unable to edit or add pages to my SharePoint 2010 Site.  Machine is Win7 Ultimate, IE8, SP2010 beta, VS2010 RC. All 64 Bit.  Was working fine.  Tried repair on the frameworks, after googling.  Cannot find the Geneva bits.  Removed Norton completely to sucessfully go back a couple of restore points and removed KB980182.  Clicked throught the SP configuration manager and all went well.  Definitely logged on as administrator.  IIS settings look good.  Webpage error details User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; OfficeLiveConnector.1.4; OfficeLivePatch.1.3; InfoPath.3; .NET4.0C; .NET4.0E)Timestamp: Sun, 4 Apr 2010 22:21:30 UTC Message: Invalid characterLine: 1Char: 1Code: 0URI: http://starman/ScriptResource.axd?d=Zq0NPA5_FNMrMkj2gVMBkGEJYiejAr4xkOPFxcm9WpzwRnp65ubolTfztiSaY8z2QKXyoZQvaI_7A65C7OJf0Eii_VL61Hoi5B23lMNvWC01&t=ffffffffec2d9970 Message: Invalid characterLine: 1Char: 1Code: 0URI: http://starman/ScriptResource.axd?d=Zq0NPA5_FNMrMkj2gVMBkGEJYiejAr4xkOPFxcm9WpzwRnp65ubolTfztiSaY8z2u8yiDywNtvdUdmHr93TbWc4U0SHQq0pQ3M2FA3FoezpYhgSt6jFnafzRYmCIg8LW0&t=ffffffffec2d9970 Message: ASP.NET Ajax client-side framework failed t

SQL Error with Login: Login failed for user 'NT AUTHORITY\SYSTEM'. [CLIENT: ]

<!-- /* Font Definitions */ @font-face {font-family:"Cambria Math"; panose-1:2 4 5 3 5 4 6 3 2 4; mso-font-charset:0; mso-generic-font-family:roman; mso-font-pitch:variable; mso-font-signature:-1610611985 1107304683 0 0 159 0;} @font-face {font-family:Calibri; panose-1:2 15 5 2 2 2 4 3 2 4; mso-font-charset:0; mso-generic-font-family:swiss; mso-font-pitch:variable; mso-font-signature:-1610611985 1073750139 0 0 159 0;} /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-unhide:no; mso-style-qformat:yes; mso-style-parent:""; margin:0cm; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-fareast-font-family:Calibri; mso-fareast-theme-font:minor-latin; mso-bidi-font-family:"Times New Roman";} a:link, span.MsoHyperlink {mso-style-priority:99; color:blue; text-decoration:underline; text-underline:single;} a:visited, span.MsoHyperlinkFollowed {mso-style-noshow:yes; mso-style-priority:99; color:purple; mso-themecolor:followedhyperlink; text-decoration:underline; text-underline:single;} .MsoChpDefault {mso-style-type:export-only; mso-default-props:yes; font-size:10.0pt; mso-ansi-font-size:10.0pt; mso-bidi-font-size:10.0pt;} @page Section1 {size:612.0pt 792.0pt; margin:70.85pt 3.0cm 70.85pt 3.0cm; mso-header-m

Error Message: The attempt to connect to the report server failed. Check your connection informatio

I have a web page that contains a ReportViewer control.  I am trying to display a report, which is an .rdl file located on the SSRS server, in this ReportViewer control.  I have set the ReportPath and ReportServerUrl correctly.  I am getting an error message. Am I suppose to use an .rdlc file rather than a .rdl file?  Does the web server configuration need to use a certain account?  I am getting the following error message: The attempt to connect to the report server failed. Check your connection information and that the report server is a compatible version. The request failed with HTTP status 404: Not Found.

Media Web Part displays "Media failed to load" message.

I am unable to use the Media web part to play a wmv file.  The wmv file (112 KB) is loaded to an asset libray. When I browse to the library and click on Play, I get "Media failed to load" error message. Please help. Thank you, Reggie    

add a webreference that displays error An unexpected error occurred on a send. Received an unexpecte

this problem is driving me crazy..... i need to add this web reference to a webservice develeped using oracle jdeveloper, but it thows.. There was an error downloading 'https://farmpruebas1.sat.gob.gt/web/ConsultasPublicasSW?WSDL'.The underlying connection was closed: An unexpected error occurred on a send.Received an unexpected EOF or 0 bytes from the transport stream.There was an error downloading 'https://farmpruebas1.sat.go DO I HAVE TO CHANGE SOMETHING IN THE WEB.CONFIG  

.net 4.0 Client Profile installs, Extended fails

After uninstalling all .net versions, I tried to reinstall them. All available versions were installed including .net 4.0 Client Profile but .net 4.0 Extended did not install. Suggestions? The error log was VERY long so here's the summary: Final Result: Installation failed with error code: (0x80070643), "Fatal error during installation.

SQL Server Native Client install fails during prerequisites

Hi I'm trying to install sharepoint 2010 on a new windows 2k8r2 which is a member server on our domain. The server is fully updated. The SQL Server native client installation fails. This is the entry in the error log;   2010-09-15 08:57:26 - Beginning download of Microsoft SQL Server 2008 Native Client 2010-09-15 08:57:26 - http://go.microsoft.com/fwlink/?LinkID=160387 2010-09-15 08:57:28 - Size of download of "Microsoft SQL Server 2008 Native Client" in bytes is "8073728" 2010-09-15 08:57:28 - Download of "Microsoft SQL Server 2008 Native Client" completed successfully 2010-09-15 08:57:28 - Installing Microsoft SQL Server 2008 Native Client 2010-09-15 08:57:28 - "C:\Windows\system32\msiexec.exe" /i "C:\Users\myadmin\AppData\Local\Temp\SQLCF11.tmp.msi" /quiet /norestart 2010-09-15 08:57:28 - Install process returned (0X660=1632) 2010-09-15 08:57:28 - [In HRESULT format] (0X80070660=-2147023264)   If I run the SQL native client installer manually I get the following error; The installer has encountered an unexpected error. The error code is 2755. Server returned unexpected error 1632 attempting to install package.   Any ideas why this is happening? I've had a quick google and can't see anything for SQL Native Client for that error code. Thanks   Olly
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend