WCF Exception at the server side ActionNotSupported - The message with Action '' cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher.

Hi,
I am developing on-premise Electronic Medical Records (EMR) app for a clinic.
I architected the solution using Domain Driven Design approach combined with the following architectural styles:
  • Layered architectural style: for structuring the solution and separation of concerns
  • 3-Tier architectural style: for deployment
     
  1. Database tier: Sql Server database
;
      [list=2]Application server tier[/list];
      [list=3]Presentation tier as a desktop app[/list].
  • SOA architectural style: for the communication between the desktop app and the application server; Where the application server exposes the business services.

I have the following error on the application server when I tried to access the WCF security service from the web browser:

"The message with Action '' cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher. This may be because of either a contract mismatch (mismatched Actions between sender and receiver) or a binding/security mismatch between the sender and the receiver.  Check that sender and receiver have the same contract and the same binding (including security requirements, e.g. Message, Transport, None)."

Attached the solution source code.
eCMS---Anas.zip
Anas TINAAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Anas TINAAuthor Commented:
I missed to pass baseAddresses argument to the constructor of ServiceHost.

var hostSecurityService = new ServiceHost(serviceType, baseAddresses);

Open in new window

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
WCF

From novice to tech pro — start learning today.