I was trying to publish a .NET 3.5 WCF service to a network share e.g.

\\myserversharefolder\_to\_holdservice

and got the error “The specified file could not be encrypted” for all the files.

I changed to a publish to the local disk it published fine, so what caused that?

As part of some security impact modelling I have been doing development with my local source directories encrypted using standard Vista security (FYI does not seem to cause any significant performance impact)

So when I copied the published files to the network share manually I got an message ‘do I want to copy without encryption’ which I answered yes to and all was OK. Shame VS publish method does not have a away to answer this question