Bug 28305 - Application with WCF that works on Framework .Net don't works with Mono (on Windows 7)
Summary: Application with WCF that works on Framework .Net don't works with Mono (on W...
Status: RESOLVED NOT_ON_ROADMAP
Alias: None
Product: Runtime
Classification: Mono
Component: Interop ()
Version: 3.12.0
Hardware: PC Windows
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2015-03-22 09:27 UTC by Fabien Comte
Modified: 2015-03-23 16:14 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

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 on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED NOT_ON_ROADMAP

Description Fabien Comte 2015-03-22 09:27:05 UTC
When I start my application I get this Exception output on console:

Unhandled Exception:
System.NotSupportedException: Securirty token requirement 'System.ServiceModel.Security.Tokens.RecipientServiceModelSecurityTokenRequirement:
------------
URI: http://schemas.microsoft.com/ws/2006/05/identitymodel/securitytokenrequirement/KeyType
Value: SymmetricKey
------------
URI: http://schemas.microsoft.com/ws/2006/05/identitymodel/securitytokenrequirement/KeySize
Value: 0
------------
URI: http://schemas.microsoft.com/ws/2006/05/identitymodel/securitytokenrequirement/RequireCryptographicToken
Value: True
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/ListenUri
Value: net.tcp://localhost:8080/RemoteClientServer
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/MessageDirection
Value: Output
------------
URI: http://schemas.microsoft.com/ws/2006/05/identitymodel/securitytokenrequirement/KeyUsage
Value: Exchange
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/SecurityBindingElement
Value: System.ServiceModel.Channels.SymmetricSecurityBindingElement:
MessageProtectionOrder: SignBeforeEncryptAndEncryptSignature
ProtectionTokenParameters:
  System.ServiceModel.Security.Tokens.SecureConversationSecurityTokenParameters:
  RequireCancellation: True
  BootstrapSecurityBindingElement:
    System.ServiceModel.Channels.SymmetricSecurityBindingElement:
    MessageProtectionOrder: SignBeforeEncryptAndEncryptSignature
    ProtectionTokenParameters:
      System.ServiceModel.Security.Tokens.X509SecurityTokenParameters:
      X509ReferenceStyle: Thumbprint
      InclusionMode: AlwaysToRecipient
      ReferenceStyle: Internal
      RequireDerivedKeys: True
    RequireSignatureConfirmation: False
    IncludeTimestamp: True
    LocalClientSettings:
      System.ServiceModel.Channels.LocalClientSecuritySettings
    DefaultAlgorithmSuite:
      System.ServiceModel.Security.SecurityAlgorithmSuite+BasicSecurityAlgorithmSuite
    KeyEntropyMode: CombinedEntropy
    LocalServiceSettings:
      System.ServiceModel.Channels.LocalServiceSecuritySettings
    SecurityHeaderLayout: Strict
    MessageSecurityVersion:
      System.ServiceModel.MessageSecurityVersion+MessageSecurityVersionImpl
    EndpointSupportingTokenParameters:
      Endorsing[0]
        System.ServiceModel.Security.Tokens.X509SecurityTokenParameters:
        X509ReferenceStyle: Any
        InclusionMode: AlwaysToRecipient
        ReferenceStyle: Internal
        RequireDerivedKeys: True
      No signed tokens.
      No signed encrypted tokens.
      No signed endorsing tokens.
    OperationSupportingTokenParameters:
      System.Collections.Generic.Dictionary`2[System.String,System.ServiceModel.Security.Tokens.SupportingTokenParameters]
    OptionalEndpointSupportingTokenParameters:
      No endorsing tokens.
      No signed tokens.
      No signed encrypted tokens.
      No signed endorsing tokens.
    OptionalOperationSupportingTokenParameters:
      System.Collections.Generic.Dictionary`2[System.String,System.ServiceModel.Security.Tokens.SupportingTokenParameters]
  BootstrapProtectionRequirements:
    System.ServiceModel.Security.ChannelProtectionRequirements
  InclusionMode: AlwaysToRecipient
  ReferenceStyle: Internal
  RequireDerivedKeys: True
RequireSignatureConfirmation: False
IncludeTimestamp: True
LocalClientSettings:
  System.ServiceModel.Channels.LocalClientSecuritySettings
DefaultAlgorithmSuite:
  System.ServiceModel.Security.SecurityAlgorithmSuite+BasicSecurityAlgorithmSuite
KeyEntropyMode: CombinedEntropy
LocalServiceSettings:
  System.ServiceModel.Channels.LocalServiceSecuritySettings
SecurityHeaderLayout: Strict
MessageSecurityVersion:
  System.ServiceModel.MessageSecurityVersion+MessageSecurityVersionImpl
EndpointSupportingTokenParameters:
  No endorsing tokens.
  No signed tokens.
  No signed encrypted tokens.
  No signed endorsing tokens.
OperationSupportingTokenParameters:
  System.Collections.Generic.Dictionary`2[System.String,System.ServiceModel.Security.Tokens.SupportingTokenParameters]
OptionalEndpointSupportingTokenParameters:
  No endorsing tokens.
  No signed tokens.
  No signed encrypted tokens.
  No signed endorsing tokens.
OptionalOperationSupportingTokenParameters:
  System.Collections.Generic.Dictionary`2[System.String,System.ServiceModel.Security.Tokens.SupportingTokenParameters]
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/MessageSecurityVersion
Value: System.ServiceModel.MessageSecurityVersion+MessageSecurityTokenVersion
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/IssuerBindingContext
Value: System.ServiceModel.Channels.BindingContext
------------
URI: http://schemas.microsoft.com/ws/2006/05/identitymodel/securitytokenrequirement/TokenType
Value: http://schemas.microsoft.com/ws/2006/05/servicemodel/tokens/SecureConversation
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/SupportSecurityContextCancellation
Value: True
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/SecureConversationSecurityBindingElement
Value: System.ServiceModel.Channels.SymmetricSecurityBindingElement:
MessageProtectionOrder: SignBeforeEncryptAndEncryptSignature
ProtectionTokenParameters:
  System.ServiceModel.Security.Tokens.X509SecurityTokenParameters:
  X509ReferenceStyle: Thumbprint
  InclusionMode: AlwaysToRecipient
  ReferenceStyle: Internal
  RequireDerivedKeys: True
RequireSignatureConfirmation: False
IncludeTimestamp: True
LocalClientSettings:
  System.ServiceModel.Channels.LocalClientSecuritySettings
DefaultAlgorithmSuite:
  System.ServiceModel.Security.SecurityAlgorithmSuite+BasicSecurityAlgorithmSuite
KeyEntropyMode: CombinedEntropy
LocalServiceSettings:
  System.ServiceModel.Channels.LocalServiceSecuritySettings
SecurityHeaderLayout: Strict
MessageSecurityVersion:
  System.ServiceModel.MessageSecurityVersion+MessageSecurityVersionImpl
EndpointSupportingTokenParameters:
  Endorsing[0]
    System.ServiceModel.Security.Tokens.X509SecurityTokenParameters:
    X509ReferenceStyle: Any
    InclusionMode: AlwaysToRecipient
    ReferenceStyle: Internal
    RequireDerivedKeys: True
  No signed tokens.
  No signed encrypted tokens.
  No signed endorsing tokens.
OperationSupportingTokenParameters:
  System.Collections.Generic.Dictionary`2[System.String,System.ServiceModel.Security.Tokens.SupportingTokenParameters]
OptionalEndpointSupportingTokenParameters:
  No endorsing tokens.
  No signed tokens.
  No signed encrypted tokens.
  No signed endorsing tokens.
OptionalOperationSupportingTokenParameters:
  System.Collections.Generic.Dictionary`2[System.String,System.ServiceModel.Security.Tokens.SupportingTokenParameters]
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/IssuedSecurityTokenParameters
Value: System.ServiceModel.Security.Tokens.SecureConversationSecurityTokenParameters:
RequireCancellation: True
BootstrapSecurityBindingElement:
  System.ServiceModel.Channels.SymmetricSecurityBindingElement:
  MessageProtectionOrder: SignBeforeEncryptAndEncryptSignature
  ProtectionTokenParameters:
    System.ServiceModel.Security.Tokens.X509SecurityTokenParameters:
    X509ReferenceStyle: Thumbprint
    InclusionMode: AlwaysToRecipient
    ReferenceStyle: Internal
    RequireDerivedKeys: True
  RequireSignatureConfirmation: False
  IncludeTimestamp: True
  LocalClientSettings:
    System.ServiceModel.Channels.LocalClientSecuritySettings
  DefaultAlgorithmSuite:
    System.ServiceModel.Security.SecurityAlgorithmSuite+BasicSecurityAlgorithmSuite
  KeyEntropyMode: CombinedEntropy
  LocalServiceSettings:
    System.ServiceModel.Channels.LocalServiceSecuritySettings
  SecurityHeaderLayout: Strict
  MessageSecurityVersion:
    System.ServiceModel.MessageSecurityVersion+MessageSecurityVersionImpl
  EndpointSupportingTokenParameters:
    Endorsing[0]
      System.ServiceModel.Security.Tokens.X509SecurityTokenParameters:
      X509ReferenceStyle: Any
      InclusionMode: AlwaysToRecipient
      ReferenceStyle: Internal
      RequireDerivedKeys: True
    No signed tokens.
    No signed encrypted tokens.
    No signed endorsing tokens.
  OperationSupportingTokenParameters:
    System.Collections.Generic.Dictionary`2[System.String,System.ServiceModel.Security.Tokens.SupportingTokenParameters]
  OptionalEndpointSupportingTokenParameters:
    No endorsing tokens.
    No signed tokens.
    No signed encrypted tokens.
    No signed endorsing tokens.
  OptionalOperationSupportingTokenParameters:
    System.Collections.Generic.Dictionary`2[System.String,System.ServiceModel.Security.Tokens.SupportingTokenParameters]
BootstrapProtectionRequirements:
  System.ServiceModel.Security.ChannelProtectionRequirements
InclusionMode: AlwaysToRecipient
ReferenceStyle: Internal
RequireDerivedKeys: True
------------
URI: http://schemas.microsoft.com/ws/2006/05/servicemodel/securitytokenrequirement/SecurityAlgorithmSuite
Value: System.ServiceModel.Security.SecurityAlgorithmSuite+BasicSecurityAlgorithmSuite' is not supported
  at System.ServiceModel.Security.ServiceCredentialsSecurityTokenManager.CreateSecurityTokenProvider (System.IdentityModel.Selectors.SecurityTokenRequirement requirement) [0x00000] in <filename unknow
n>:0
  at System.ServiceModel.Channels.Security.MessageSecurityBindingSupport.CreateTokenProvider (System.IdentityModel.Selectors.SecurityTokenRequirement requirement) [0x00000] in <filename unknown>:0
  at System.ServiceModel.Channels.Security.MessageSecurityBindingSupport.GetToken (System.IdentityModel.Selectors.SecurityTokenRequirement requirement, System.ServiceModel.Security.Tokens.SecurityToke
nParameters targetParams, SecurityKeyUsage usage) [0x00000] in <filename unknown>:0
  at System.ServiceModel.Channels.Security.RecipientMessageSecurityBindingSupport.get_EncryptionToken () [0x00000] in <filename unknown>:0
  at System.ServiceModel.Channels.Security.SecureMessageDecryptor.ReadHeaders (System.ServiceModel.Channels.Message srcmsg) [0x00000] in <filename unknown>:0
  at System.ServiceModel.Channels.Security.SecureMessageDecryptor.DecryptMessage () [0x00000] in <filename unknown>:0
  at System.ServiceModel.Channels.Security.SecurityDuplexSessionChannel.DecryptMessage (System.ServiceModel.Channels.Message msg) [0x00000] in <filename unknown>:0
  at System.ServiceModel.Channels.Security.SecurityDuplexSessionChannel.TryReceive (TimeSpan timeout, System.ServiceModel.Channels.Message& message) [0x00000] in <filename unknown>:0
Comment 1 Zoltan Varga 2015-03-23 15:56:36 UTC
Mono doesn't support WCF.
Comment 2 Fabien Comte 2015-03-23 16:14:04 UTC
Ok I understand, thank you.

For thoses that have the same problem i found a solution moving on Halibut.