views:

155

answers:

2

I would like to add an interceptor layer to my WCF service to send the Device ID to authenticate the device.

I am very very new to WCF Interceptors. Before I take all the time to figure them out, I would like to know if they even work with the Compact Framework.

So, do WCF Interceptors work with the Compact Framework and if so are there any special considerations I need to keep in mind as I research them. (Any C# examples of how to do this would be AWESOME!)

I am using Visual Studio 2008 SP1.

+1  A: 

I haven't used WCF myself, but a quick glance at this article shows me you need the IChannelFactory and/or IChannelListener classes which are supported on .NET CF 3.5.

The article also has a downloadable sample app, which you probably can modify to run on .NET CF.

So I can't give you any considerations or gotchas, but it looks to me you won't be on a dead end road here.

tomlog
A: 

Interceptors cannot be created on WCF for Compact Framework (NETCF). The IClientMessageInspector and similar constructs needed for interceptors are not present in NETCF.

You can add custom soap headers though. You just have to add them to each WCF Service Call.

Vaccano