Bug 197 - WCF and SecurityMode.TransportWithMessageCredential;
Summary: WCF and SecurityMode.TransportWithMessageCredential;
Status: IN_PROGRESS
Alias: None
Product: Class Libraries
Classification: Mono
Component: WCF assemblies (show other bugs)
Version: unspecified
Hardware: All Linux
: Normal critical
Target Milestone: Untriaged
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2011-08-05 08:13 UTC by Antya Dev
Modified: 2017-05-09 18:18 UTC (History)
7 users (show)

Tags: WCF; NetTcpBinding; SecurityMode.TransportWithMessageCredential;
Is this bug a regression?: ---
Last known good build:


Attachments
source code for example (12.64 KB, application/octet-stream)
2011-08-05 08:13 UTC, Antya Dev
Details
source code (12.86 KB, application/zip)
2011-08-09 05:42 UTC, Antya Dev
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report for Bug 197 on GitHub or Developer Community if you have new information to add and do not yet see a matching new report.

If the latest results still closely match this report, you can use the original description:

  • Export the original title and description: GitHub Markdown or Developer Community HTML
  • Copy the title and description into the new report. Adjust them to be up-to-date if needed.
  • Add your new information.

In special cases on GitHub you might also want the comments: GitHub Markdown with public comments

Related Links:
Status:
IN_PROGRESS

Description Antya Dev 2011-08-05 08:13:41 UTC
Created attachment 73 [details]
source code for example

Description of Problem:

I have critical problem with WCF secure mode connection on client (used mono 2.10.3). When I try connect to server (server runtime is .NET) without any secure mode then it's working fine for me but for this my server also not used authentification.

So, when I added to server and client some code for authentificate, for example:

NetTcpBinding binding = new NetTcpBinding(SecurityMode.TransportWithMessageCredential);
binding.Security.Message.ClientCredentialType = MessageCredentialType.UserName;
binding.Security.Transport.ClientCredentialType = TcpClientCredentialType.Certificate;

serviceHost.Credentials.ServiceCertificate.SetCertificate(
                    StoreLocation.LocalMachine,
                    StoreName.My,
                    X509FindType.FindBySerialNumber,
                    Properties.Settings.Default.appCertSerialNumber);

                serviceHost.Credentials.UserNameAuthentication.UserNamePasswordValidationMode =
                    System.ServiceModel.Security.UserNamePasswordValidationMode.Custom;

                serviceHost.Credentials.UserNameAuthentication.CustomUserNamePasswordValidator =
                    new Platezhka.Common.AuthorizationManager.CustomUserNamePasswordValidator(Properties.Settings.Default.platezhkadbConnectionString,
                        Platezhka.Common.AuthorizationManager.CustomUserNamePasswordValidator.PasswordType.UserPasswordServiceMenu);

                serviceHost.Authorization.ServiceAuthorizationManager =
                    new Platezhka.Common.AuthorizationManager.CustomServiceAuthorizationManager(Properties.Settings.Default.platezhkadbConnectionString);


Then it's stoped work, becouse my client always crashed. 

Please Attention: When I tried switch a runtime on client from Mono to .NET then it's became working fine. On Mono I always see an exception message about System.IO.Exception. 



Steps to reproduce the problem:
1. Open attachment archive. Next, start WcfMonoServer on .NET 3.5 on Windows 7 or other Windows.
2. Open WcfTcpClient. Start it on Mono 2.10.3 and try open connect.


Actual Results:
Always crash with System.IO.Exception

Expected Results:
Must work as on .NET3.5

Regards.
Comment 1 Miguel de Icaza [MSFT] 2011-08-05 17:23:47 UTC
Please attach sample as a ZIP file.

Also, be warned that WCF support is partial, and only considered alpha-level, since there are many pieces not completed.
Comment 2 Antya Dev 2011-08-09 05:42:43 UTC
Created attachment 93 [details]
source code
Comment 3 Antya Dev 2011-08-09 05:52:58 UTC
Of course, I understand that WCF support is partial.

I already added attach sample as a ZIP file.

I noticed one detail:
  if insert the SecurityMode to not in "None" it's always throw exception.

Regards.
Comment 4 christophe 2017-05-09 18:18:32 UTC
Hi,

Any update on this issue since 6 years now ???
This problem still exists even though the status is in progress.

I believe nobody works on this issue. 
Please advise.

Can't wait anymore.