#pftools
Note that these instructions are out of date for the moment, until i get some free time to fix them
pftools is a simple suite of tools to do things like
retrieve your external ip address from the router
make port forwardings
getip relies on two things:
- that your router supports UPnP
- that you have a CLR (Common Language Runtime) installed, such as the .NET Framework for Windows, or Mono for Linux/Mac OS X/Windows.
on linux, you can just install the package mono-runtime
to install mono
$ sudo apt-get install mono-runtime
mono is also downloadable from their website:
to download and run the pftools utilities:
open a terminal
$ cd Downloads
$ wget https://github.com/asjadsyed/pftools/archive/master.zip -O pftools.zip
$ unzip pftools.zip
$ rm pftools.zip
$ cd pftools-master/Linux/
$ mono getip
getip will now search for routers until it finds one
if it doesn't, you either:
- can't access the internet, or
- your router doesn't support the UPnP Protocol
to install the pftools programs so that you can run them from any folder:
sudo cp getip /usr/bin/
to download and compile getip:
- first, make sure you have the
mono-devel
package
$ sudo apt-get install mono-devel
* then download and prepare to compile
$ cd Downloads
$ wget https://github.com/asjadsyed/getip/archive/master.zip -O getip.zip
$ unzip getip.zip
$ rm getip.zip
$ cd getip-master/Source/
$ mcs GetIP.cs -r:Mono.Nat.dll -out:getip
getip relies on Mono.Nat, a UPnP library, to communicate with your router
you do not need to install anything for this
for the linux binary, Mono.Nat has been combined into the original binary using ILRepack
on windows, you need to make sure the Mono.Nat.dll file stays in the same folder as GetIP.exe