Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Web Service Question

Web Service Question

Scheduled Pinned Locked Moved C#
sysadminxmltutorialquestion
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • P Offline
    P Offline
    patnsnaudy
    wrote on last edited by
    #1

    Does anyone know of a simple example of securing a webservice client and server. I need to pass a username and password from the winform client to the web service, but I don't want them sent in plain text xml. Thanks

    M H 2 Replies Last reply
    0
    • P patnsnaudy

      Does anyone know of a simple example of securing a webservice client and server. I need to pass a username and password from the winform client to the web service, but I don't want them sent in plain text xml. Thanks

      M Offline
      M Offline
      Mazdak
      wrote on last edited by
      #2

      Search for SoapHeader and Cryptography[^] to see how encrypt/decrypt datas and passing them to web service. Mazy
      "One who dives deep gets the pearls,the burning desire for realization brings the goal nearer." - Babuji

      1 Reply Last reply
      0
      • P patnsnaudy

        Does anyone know of a simple example of securing a webservice client and server. I need to pass a username and password from the winform client to the web service, but I don't want them sent in plain text xml. Thanks

        H Offline
        H Offline
        Heath Stewart
        wrote on last edited by
        #3

        Or even easier, just setup an SSL certificate on your web server and communicate with your web service via the SSL port (default is 443). This encrypts everything for you. Instead of the SOAP headers (which doesn't encrypt anything), see the System.Security.Cryptography.Xml namespace in the .NET Framework SDK. I also cover the signing portion of this (to see an example of that part of it, which is similar to what you need to do for encrypting the SOAP message) in my article, Using XML Digital Signatures for Application Licensing[^]. The WS-Security specs (of which WS-Signatures and WS-Encryption is part) are also an industry standard.

        Microsoft MVP, Visual C# My Articles

        P 1 Reply Last reply
        0
        • H Heath Stewart

          Or even easier, just setup an SSL certificate on your web server and communicate with your web service via the SSL port (default is 443). This encrypts everything for you. Instead of the SOAP headers (which doesn't encrypt anything), see the System.Security.Cryptography.Xml namespace in the .NET Framework SDK. I also cover the signing portion of this (to see an example of that part of it, which is similar to what you need to do for encrypting the SOAP message) in my article, Using XML Digital Signatures for Application Licensing[^]. The WS-Security specs (of which WS-Signatures and WS-Encryption is part) are also an industry standard.

          Microsoft MVP, Visual C# My Articles

          P Offline
          P Offline
          patnsnaudy
          wrote on last edited by
          #4

          Thanks. Is WS-Security a standard yet?

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups