I\'m getting this error while attempting to make my WCF client and server talk to each other.
The X.509 certificate CN=localhost chain building faile
There is a problem with your certificate (I suppose you use self-signed cert) WCF tries to verify all the chain of issuers and expects, that finally chain would end on root trusted authority. To disable that check you could add such line to app.config branch. But this "crutch" shouldn't be used in production serviceBehaviors/behavior/serviceCredentials/clientCertificate