Jump to content

UPnP Port Forwarding


BillH
 Share

Recommended Posts

I found Ibrahim Ghorabah's thread re UPnP Port Forwarding very interesting, and decided to have a try at creating a similar project, leaving out the third party application UPnP Port Works. Instead, I was hoping to use UPnP and AutoIt as the only resources. I'm not new to AutoIt, but this is my first venture with TCP/UDP and UPnP. I had intended to use UPnP for discovery, and then connect to the router's control point with the TCP/IP protocol. After making this connection I would use UPnP to send a soap message to the router to forward the port to the host IP address.

At this point I realized the complexity of it all. Has anyone successfully used UPnP and AutoIt exclusively, to automate router port forwarding? If so, would they have a code sample demonstrating the process that could be posted? Or, could they post a link to information that would be helpful to me. I’m starting with limited knowledge, and any help pointing me in the right direction would be greatly appreciated. This is a learning project for me, so a big thank you for any interest that is shown.

Link to comment
Share on other sites

I found Ibrahim Ghorabah's thread re UPnP Port Forwarding very interesting, and decided to have a try at creating a similar project, leaving out the third party application UPnP Port Works. Instead, I was hoping to use UPnP and AutoIt as the only resources. I'm not new to AutoIt, but this is my first venture with TCP/UDP and UPnP. I had intended to use UPnP for discovery, and then connect to the router's control point with the TCP/IP protocol. After making this connection I would use UPnP to send a soap message to the router to forward the port to the host IP address.

At this point I realized the complexity of it all. Has anyone successfully used UPnP and AutoIt exclusively, to automate router port forwarding? If so, would they have a code sample demonstrating the process that could be posted? Or, could they post a link to information that would be helpful to me. I’m starting with limited knowledge, and any help pointing me in the right direction would be greatly appreciated. This is a learning project for me, so a big thank you for any interest that is shown.

Good luck, there are countless threads out and about in the wild asking the same thing, none of them with a golden answer and they all usually end with people speculating the individual who asked the question is bent on creating a botnet kind of application, I needed the same functionality for an app that would control sprinkler systems in my ranch and found it easier to just pre-program the damn things to listen in on a web page I'm hosting for execution times which is not nearly as cool as just launching an app that will send them the activation code, the best clue I could find was studying open source apps like chromium but I don't know C++ at all in order to make use of any of its cryptic code and being able to know how it works, problem is people tend to keep these things on the down-low as soon as they learn how to do it because it can very easily be used to make hideously vicious shit programs that would make your users want to find and kill you with a spoon, and those who do figure out how to do it also keep it secret because they feel like they have some super secret watch the world burn code on their hands, just like people who make keyloggers in autoit, they think they have some topnotch ultra secret source usually reserved for google employees and the likes.

Link to comment
Share on other sites

@THAT1ANONYMOUSEDUDE

WOW – only one lonely response, and we're both thirsty for the same knowledge. There are a number of very knowledgeable members participating in this forum, and I thought that this topic would be a piece of cake for many of them. But, no go.

As for your comments re the misuse of UPnP in malware, I think this has been overblown. Should anyone feel that enabling UPnP on their router exposes them to nefarious traffic, they can make the choice to leave it disabled. There are those of us that might find this feature very useful at times. The project I am working on will serve no immediate purpose, other than to educate me in the use of UPnP in AutoIT. I’ve already written whatever code was straightforward in AutoIT. I’m now stalled while trying to formulate the syntax for the soap messages to the router. This is where I need to see some sample code.

You may be interested in a project I have found that has source posted in my area of interest. This is a Visual Studio Project written in Visual C++. The source code can be view in the SciTE script editor. Other than that, Visual C++ 2010 Express is a free download from Microsoft that you may find useful. I know you have stated that you don’t know C++, but this is not a huge project, and the explanation of how UPnP works is excellent. I’m studying this project to see if I can pick out their work with soap statements from the source, with a view to doing the same in AutoIT. Time will tell.

This is the web address to that project should you be interested:

http://www.codeproject.com/KB/IP/port-forwarding.aspx

Thanks for taking the time to comment. I hope the little bit of info above is helpful to you.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...