We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now

x

WSE1.0 to WSE3.0

rocky050371
rocky050371 asked
on
Medium Priority
562 Views
Last Modified: 2012-06-27
I am upgrading a project from WSE 1 TO 3, I have the following code on the client

        Dim proxy As New TestWS.DataServiceWse
        proxy.Url = WSLocation
        Dim reqCtx As SoapContext = proxy.RequestSoapContext
        Dim tok As New UsernameToken(EmailAddress, Password, PasswordOption.SendHashed)
        reqCtx.Security.Tokens.Add(tok)
        reqCtx.Security.Elements.Add(New Signature(tok))
        Return proxy


And on the web service

 Private Function Authenticater() As Boolean

        Dim requestContext As SoapContext = HttpSoapContext.RequestContext
        Dim userToken As UsernameToken
   
        If requestContext Is Nothing Then
            Throw New SoapException("Only SOAP requests are accepted", _
                            SoapException.ClientFaultCode)
        End If

        For Each userToken In requestContext.Security.Tokens
            If TypeOf userToken Is UsernameToken Then
                If userToken.PasswordOption = PasswordOption.SendHashed Then
                    Return True
                    Exit For
                Else
                    Throw New SoapException("The password must be hashed", SoapException.ClientFaultCode)
                End If
            End If
        Next
    End Function

does anyone before I upgrade whether this will work with 3?
Comment
Watch Question

CERTIFIED EXPERT
Commented:
make a copy and try it doesnt hurt.

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts

Author

Commented:
This is no quite what I was after
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.