How to open a uPnP forwarded port

This is a discussion on How to open a uPnP forwarded port within the Networking/Device Communication forums, part of the General Programming Boards category; Our software will be installed behind a ifrewall, but we need it to accept incoming connections on a specific port. ...

  1. #1
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,189

    How to open a uPnP forwarded port

    Our software will be installed behind a ifrewall, but we need it to accept incoming connections on a specific port. I figure what I need to do is use port forwarding via uPnP. How do you do this in C/C++ for windows, using Visual Studio 6.0?

    Everythign I looked for on the net just wants to discuss the overall architecture fo port forarding, not how to do it in a program.
    Until you can build a working general purpose reprogrammable computer out of basic components from radio shack, you are not fit to call yourself a programmer in my presence. This is cwhizard, signing off.

  2. #2
    Woof, woof! zacs7's Avatar
    Join Date
    Mar 2007
    Location
    Australia
    Posts
    3,459
    You can't, unless you can tell the router what to do -- or you have a computer running as a gateway (and your program handles/forwards connections).

  3. #3
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,189
    Well gee, thats odd because uTorrent does it as well as several other software packages.
    Until you can build a working general purpose reprogrammable computer out of basic components from radio shack, you are not fit to call yourself a programmer in my presence. This is cwhizard, signing off.

  4. #4
    Registered User
    Join Date
    Feb 2006
    Posts
    54
    http://en.wikipedia.org/wiki/Internet_Gateway_Device

    The external links include protocol specifications and implementations.

  5. #5
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,189
    again, while that is interesting it does not actually give any meaningful examples. I already know what uPnP is, I need code that shows how to implement it in C/C++
    Until you can build a working general purpose reprogrammable computer out of basic components from radio shack, you are not fit to call yourself a programmer in my presence. This is cwhizard, signing off.

  6. #6
    Woof, woof! zacs7's Avatar
    Join Date
    Mar 2007
    Location
    Australia
    Posts
    3,459
    Oh but it does, down the bottom of the wiki page it links "Free ANSI C library to control a Universal Plug and Play Internet Gateway Device" @ http://miniupnp.free.fr/

  7. #7
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,189
    yes perhaps, but when i tried to DL it from that site I kept getting connect errors, so I figured the link was broken.
    Until you can build a working general purpose reprogrammable computer out of basic components from radio shack, you are not fit to call yourself a programmer in my presence. This is cwhizard, signing off.

  8. #8
    Woof, woof! zacs7's Avatar
    Join Date
    Mar 2007
    Location
    Australia
    Posts
    3,459
    Well they've also got a mirror... http://miniupnp.tuxfamily.org/

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Concurrent chat, Sockets
    By jakemott in forum Linux Programming
    Replies: 6
    Last Post: 11-29-2008, 04:41 PM
  2. need guidance to connect to serial port
    By gnychis in forum Linux Programming
    Replies: 1
    Last Post: 06-02-2005, 10:10 AM
  3. Using Sockets to post to port
    By WaterNut in forum Windows Programming
    Replies: 3
    Last Post: 04-15-2005, 04:10 PM
  4. Unknown Memory Leak in Init() Function
    By CodeHacker in forum Windows Programming
    Replies: 3
    Last Post: 07-09-2004, 09:54 AM
  5. Problems with open and save boxes
    By pinkcheese in forum Windows Programming
    Replies: 3
    Last Post: 05-21-2002, 06:03 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21