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. Web Development
  3. ASP.NET
  4. Update dyndns

Update dyndns

Scheduled Pinned Locked Moved ASP.NET
helpcsharpsysadminagentic-aisecurity
2 Posts 1 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.
  • V Offline
    V Offline
    V 2
    wrote on last edited by
    #1

    I m writing code for updae the dyndns for my webcam I m using this code to implement this task Private Sub dyndnsupdate(ByVal ip As String) Try Dim data(1024) As Byte Dim response As String = "" Dim count As Integer Dim socket As New Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp) Dim host As IPHostEntry = System.Net.Dns.Resolve("professionalbkn.dyndns.org") Socket.Connect(DirectCast((New IPEndPoint(host.AddressList(0), 80)), EndPoint)) If Not Socket.Connected Then Throw New Exception("Can´t connect to dyndns service") End If Dim request As String = "GET /nic/update?" + "system=dyndns" + "&hostname=" + _ Me.hostName + "&myip=" + "&wildcard=" + "ON" + _ "&offline=NO " + "HTTP/1.1" & Chr(13) & "" & Chr(10) & "" + _ "Host: members.dyndns.org" & Chr(13) & "" & Chr(10) & "" + _ "Authorization: Basic " + Me.userID + _ ":" + Me.password + "" & Chr(13) & "" & Chr(10) & "" + _ "User-Agent: .net dyndns client" & Chr(13) & "" & Chr(10) & "" & Chr(13) & "" & Chr(10) & "" count = Socket.Send(System.Text.UnicodeEncoding.ASCII.GetBytes(Request)) count = Socket.Receive(Data) While Not count = 0 Response += System.Text.ASCIIEncoding.ASCII.GetString(Data, 0, count) count = Socket.Receive(Data) End While Socket.Shutdown(SocketShutdown.Both) Socket.Close() Response = Response.Substring(Response.IndexOf("\r\n\r\n") + 4) But it gives error that :

    HTTP/1.1 404 Not Found
    Server: Unknown/0.0 UPnP/1.0 Web Server
    Connection: close

    404 Not Found

    Hope some one can understand my problem & will help to solve this problem Thanks with anticipation

    The Great Pleasure In Doing That Things That Other People Say U Can't By Doing This U Can Shut Their Mouth

    V 1 Reply Last reply
    0
    • V V 2

      I m writing code for updae the dyndns for my webcam I m using this code to implement this task Private Sub dyndnsupdate(ByVal ip As String) Try Dim data(1024) As Byte Dim response As String = "" Dim count As Integer Dim socket As New Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp) Dim host As IPHostEntry = System.Net.Dns.Resolve("professionalbkn.dyndns.org") Socket.Connect(DirectCast((New IPEndPoint(host.AddressList(0), 80)), EndPoint)) If Not Socket.Connected Then Throw New Exception("Can´t connect to dyndns service") End If Dim request As String = "GET /nic/update?" + "system=dyndns" + "&hostname=" + _ Me.hostName + "&myip=" + "&wildcard=" + "ON" + _ "&offline=NO " + "HTTP/1.1" & Chr(13) & "" & Chr(10) & "" + _ "Host: members.dyndns.org" & Chr(13) & "" & Chr(10) & "" + _ "Authorization: Basic " + Me.userID + _ ":" + Me.password + "" & Chr(13) & "" & Chr(10) & "" + _ "User-Agent: .net dyndns client" & Chr(13) & "" & Chr(10) & "" & Chr(13) & "" & Chr(10) & "" count = Socket.Send(System.Text.UnicodeEncoding.ASCII.GetBytes(Request)) count = Socket.Receive(Data) While Not count = 0 Response += System.Text.ASCIIEncoding.ASCII.GetString(Data, 0, count) count = Socket.Receive(Data) End While Socket.Shutdown(SocketShutdown.Both) Socket.Close() Response = Response.Substring(Response.IndexOf("\r\n\r\n") + 4) But it gives error that :

      HTTP/1.1 404 Not Found
      Server: Unknown/0.0 UPnP/1.0 Web Server
      Connection: close

      404 Not Found

      Hope some one can understand my problem & will help to solve this problem Thanks with anticipation

      The Great Pleasure In Doing That Things That Other People Say U Can't By Doing This U Can Shut Their Mouth

      V Offline
      V Offline
      V 2
      wrote on last edited by
      #2

      Is anybody there who can give some idea,link,info anything????? Any idea would be appreciated

      The Great Pleasure In Doing That Things That Other People Say U Can't By Doing This U Can Shut Their Mouth

      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