WCF: Wie ermittelt man den Hostnamen des Aufrufers?

Mit folgendem Statement kann der Hostname des Aufrufers ermittelt werden:

  1. string hostname = OperationContext.Current.RequestContext.RequestMessage.Properties.Via.Host;
Share and Enjoy:
  • Print
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
  • email
  • FriendFeed
  • PDF
  • RSS
  • Technorati
  • Twitthis
This entry was posted in .NET, Arbeit. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word