Results 1 to 4 of 4

Thread: Help Winsock Filter

  1. #1

    Thread Starter
    Member
    Join Date
    Jun 2006
    Posts
    35

    Help Winsock Filter

    hI ive made a proxy and i wanted to make a filter how do I it?

    Code:
     Public Sub Winsock1_DataArrival()
            Dim Data As Object
            Dim rByte As Byte
    
            Winsock1.GetData(Data)
    
            If Data = ?? Then 'Filter Here
              Msgbox(??.ToString)
            End If
    
        End Sub
    the code above doesnt work I need some help..

  2. #2
    "Digital Revolution"
    Join Date
    Mar 2005
    Posts
    4,471

    Re: Help Winsock Filter

    What are you trying to filter...?

    And why are you declaring Data as an object?

    Code:
    Private Sub Winsock1_DataArrival()
        Dim bytData() As Byte, strData As String
        
        winsock1.GetData bytData()
        'Convert data to string.
        strData = StrConv(bytData(), vbUnicode)
        
        If LCase$(Left$(strData, 4)) = "post" Then
            'Ignore HTTP post...
        End If
        
    End Sub

  3. #3

    Thread Starter
    Member
    Join Date
    Jun 2006
    Posts
    35

    Re: Help Winsock Filter

    this is written in VB.NEt..need .Net code

  4. #4
    Frenzied Member the182guy's Avatar
    Join Date
    Nov 2005
    Location
    Cheshire, UK
    Posts
    1,473

    Re: Help Winsock Filter

    the Winsock Control does not exist in vb.NET, you have to use the TCPClient and TCPListener calsses
    Chris

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width