I learned from a video that NAT punching is one of the features of Tor. I run GNU/Linux Ubuntu 16.4. I have already installed Tor. It will be great if someone can instruct me how to perform this feature. My home connection does not receive a static IP. It will be great if I could access my home PC from anywhere in the world via Tor.
tor has it's "nat helpers" - but they must be enabled during compilation in
configure --enable-nat-pmp --enable-upnp script arguments and in
torrc it should be explicitly pointed to by using( a cite from official manual):
Attempt to automatically forward the DirPort and ORPort on a NAT router connecting this Tor server to the Internet. If set, Tor will try both NAT-PMP (common on Apple routers) and UPnP (common on routers from other manufacturers). (Default: 0)
If PortForwarding is set, use this executable to configure the forwarding. If set to a filename, the system path will be searched for the executable. If set to a path, only the specified path will be executed. (Default: tor-fw-helper)
The NAT punching properties described in the video, are those of onion services. These are a default property of onion services.
Normally if you've providing a service that you want to be accessible behind some NAT, you have to setup some kind of exception on the NAT device (e.g. a home router) to allow incoming connections to a certain port be forwarded to an address behind the NAT device. However, onion services consist purely of outbound connections so there is no requirement (or recommendation) to configure the NAT device to allow incoming connections.
If you can make outbound connections, then an onion service can receive "inbound" connections, and the NAT device doesn't come into play at all. There are no special configuration steps required, it is a useful side-effect of the architecture of onion services.
The onion service makes an outbound connection to ~3 Introduction Points, it holds those outbound connections open. The client speaks to those introduction points and through them provides a rendezvous point. The onion service makes an outbound connection to the rendezvous point. At no point does the onion service have to receive an inbound connection to operate.