• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NAT-PMP not honoring requested external port
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NAT-PMP not honoring requested external port


  • Subject: Re: NAT-PMP not honoring requested external port
  • From: Jens Alfke <email@hidden>
  • Date: Mon, 9 Jun 2008 17:43:34 -0700


On 9 Jun '08, at 12:22 PM, james woodyatt wrote:

AirPort's natpmpd tries to assign the requested public port unless that port is unavailable, in which case it assigns another one that *is* available.

Thanks. I was unsure whether this was the expected behavior, since the only data points I have show it assigning random numbers every time (which I was afraid might have been intentional, for security reasons or something.)


I reconfigured my network to use my ABS as the NAT (ordinarily the ABS only does bridging because it sits behind my main router) so I could test this out myself instead of relying on logs from 3rd parties. It looks like it _is_ assigning me the port number I asked for, which is good.

What I was seeing earlier may have been based on the port number for _outgoing_ connections. I attempt to make the outgoing port number the same as the listening port number by binding the outgoing socket to that port. (That way the peer on the other end can cache the originating address of the incoming connection and reconnect to it later.) It looks as though the ABS isn't using this port number, however.

To be specific, since that sounds confusing:
1. I open a listening TCP socket on port PRIV.
2. I request a NAT port mapping from port PRIV, with desired public port PUB.
3. I create a TCP socket, bind it to port PRIV on my end, and connect it to a peer's address outside the NAT.


What I expected to happen is that peer sees an incoming connection from [ABS public address], port PUB. I.e. the ABS does the same PRIV- >PUB port mapping for the outgoing connection.
Instead, the peer sees a random port number. Is that the expected behavior? (The NAT-PMP spec doesn't seem to address this.)


—Jens

Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: NAT-PMP not honoring requested external port
      • From: james woodyatt <email@hidden>
References: 
 >NAT-PMP not honoring requested external port (From: Jens Alfke <email@hidden>)
 >Re: NAT-PMP not honoring requested external port (From: james woodyatt <email@hidden>)

  • Prev by Date: Re: NAT-PMP not honoring requested external port
  • Next by Date: Re: NAT-PMP not honoring requested external port
  • Previous by thread: Re: NAT-PMP not honoring requested external port
  • Next by thread: Re: NAT-PMP not honoring requested external port
  • Index(es):
    • Date
    • Thread