Giter Site home page Giter Site logo

go-nat's Introduction

go-nat

GoDoc status

go-nat's People

Contributors

dependabot-preview[bot] avatar dependabot-support avatar fd avatar ryanskidmore avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

go-nat's Issues

Don't limit operation to RFC1918 ranges

Currently, the code only runs NAT-PMP on local addresses in the ranges 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16.

However, NAT-PMP/PCP can also be used for simple control of a stateful firewall, even when using public IPv4 or IPv6. See https://tools.ietf.org/html/rfc6887

Additionally, some people are beginning to use other ranges as "private" ranges: either unallocated network ranges (which is a very bad idea, but some people still do that), or the 100.64.0.0/10 range allocated to CG-NAT by https://tools.ietf.org/html/rfc6598

Support for PCP?

Does this lib support Port Control Protocol? I feel like you may have commented on an issue in go-ipfs saying that it did (or someone else did) but i can't see in the code where/how that happens.

Support multiple local addresses on the same NAT

While not critical, it would be nice if this library supported multiple interfaces/addresses on the same NAT. This would mean:

  1. Passing a local address (and using it as the source address) when establishing a mapping.
  2. Changing GetInternalAddress() to GetInternalAddresses() (or adding a new function) that exposes all internal addresses on the NAT.

Use-cases:

  • Multiple "virtual" interfaces (e.g., for containers/VMs).
  • Multiple NICs on the same LAN.

I understand you probably don't have time to work on this, I just figured I'd leave this here in case anyone comes along and does.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.