WSE 2.0 - SoapHeaders, Signatures and DigestValue

Discussion in 'ASP .Net Web Services' started by nsyforce@aol.com, Oct 20, 2005.

  1. Guest

    I have a need to create a generic CCW that adds a username token to
    soap request to a web service. However, I have to do this generically
    for any web service. Thus, I'm not using a proxy at design time. This
    is to support legacy VB6 apps so we don't have to write a CCW for every
    single web service that we want to apply WS Security to.

    The solution I'm trying to use is to create my own HttpWebRequest and
    create my own header information to send to the Web Service. I'm having
    problems with creating the information that supports adding a user
    token through a MessageSignature to the
    requestContext.Security.Elements.

    I can see that the reference element has a URI that ties it back to
    another item in the soap header. Consider the following:
    <wsa:Action
    wsu:Id="Id-60fc6e83-9022-4965-99c9-670b249d3281">http://tempuri.org/HelloMsXmlEnc</wsa:Action>
    ....
    <Reference URI="#Id-60fc6e83-9022-4965-99c9-670b249d3281">
    <Transforms>
    <Transform
    Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" />
    </Transforms>
    <DigestMethod
    Algorithm="http://www.w3.org/2000/09/xmldsig#sha1" />
    <DigestValue>xBPdU+CihzhpR7eBBHL66KNdW/4=</DigestValue>
    </Reference>

    I've been searching everywhere, and I'm trying to find the answer to
    these 2 questions:

    1. What is the decrypted value of digestValue?
    2. I'm using the following code to try and generate this info, but
    can't figure out how to get the digestValue populated. Does anyone
    know how I do that?

    MessageSignature mesSig = new MessageSignature();
    SignatureReference soapRef = new
    SignatureReference("#Id:05d2518d-d6db-481f-846d-2e8872b6e56d");
    soapRef.AddTransform(new XmlDsigExcC14NTransform());
    mesSig.AddReference(soapRef);

    Thanks in advance for your help.
     
    , Oct 20, 2005
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    3
    Views:
    358
    Chris Uppal
    Feb 19, 2004
  2. MattM

    Typed Datasets and Delegate signatures

    MattM, Jun 8, 2007, in forum: ASP .Net Building Controls
    Replies:
    1
    Views:
    758
    MattM
    Jun 8, 2007
  3. More AXIS and c# - soapheaders galore

    , Dec 14, 2004, in forum: ASP .Net Web Services
    Replies:
    0
    Views:
    118
  4. More AXIS and c# - soapheaders galore

    , Dec 15, 2004, in forum: ASP .Net Web Services
    Replies:
    0
    Views:
    135
  5. Brian Mitchell

    [SOT]Signatures and one liners

    Brian Mitchell, Dec 6, 2004, in forum: Ruby
    Replies:
    20
    Views:
    272
    trans. (T. Onoma)
    Dec 9, 2004
Loading...

Share This Page