1 nat & rtp proxy date: 2009/7/2 speaker: ni-ya li advisor: quincy wu
Post on 03-Jan-2016
229 Views
Preview:
TRANSCRIPT
NAT What is NAT?
Network Address Translator, maps a private IP address to a public one
Why use NAT? Public IP addresses are almost exhausted
Four types Full cone Restricted cone Restricted port cone Symmetric
3
NAT – Simple architecture
7
Client AT Server
Mapping Table
192.168.0.191 : 1668 10.10.59.11 : 60255
NAT
Pu
blic N
IC
Private N
IC
Full cone NAT
9
ClientIP: 192.168.0.1
Port: 21
NAT
Port: 12345
Mapping Table
Computer AIP: 222.111.99.1
Port: 20202
Computer BIP: 222.111.88.2
Port: 10101
IP: 123.123.123.123
192.168.0.1:21 <-> 12345
Restricted cone NAT
10
ClientIP: 192.168.0.1
Port: 21
NAT
Port: 12345
Mapping Table
Computer AIP: 222.111.99.1
Port: 20202
Computer BIP: 222.111.88.2
Port: 10101
IP: 123.123.123.123
192.168.0.1:21 <-> 12345 (for A)
ClientIP: 192.168.0.1
Port: 21
NAT
IP: 123.123.123.123Port: 12345
Mapping Table192.168.0.1:21 <-> 12345 (for A)
Computer AIP: 222.111.99.1
Port: 20202
Computer BIP: 222.111.88.2
Port: 10101
192.168.0.1:21 <-> 12345 (for B)
Restricted port cone NAT
11
ClientIP: 192.168.0.1
Port: 21
NATIP: 123.123.123.123Port: 12345
Mapping Table192.168.0.1:21 <-> 12345 (for A : 20202)192.168.0.1:21 <-> 12345 (for A : 30303)
Computer AIP: 222.111.99.1
Port: 20202Port: 30303
Symmetric NAT
12
ClientIP: 192.168.0.1
Port: 21NAT
IP: 123.123.123.123Port: 12345
Mapping Table192.168.0.1:21 <-> 12345 (for A : 20202)192.168.0.1:21 <-> 45678 (for B : 10101)
Computer AIP: 222.111.99.1
Port: 20202
Computer BIP: 222.111.88.2
Port: 10101IP: 123.123.123.123Port: 45678
NAT–drawback & solution The drawback of using NAT?
Unfriendliness for end-to-end applications, such as transmission of RTP streams.
How to overcome the disadvantage? RTP Proxy
14
RTP Proxy RTP
The real-time transport protocol to carry data that has real-time properties.
RTP Proxy A software proxy for RTP streams, works with SIP server
Why use RTP Proxy? Originally created for handling NAT scenarios
16
RTP Proxy - Operation When SIP server receives INVITE request
INVITE request,
extracts call-id
Session of call-id exist?
Yes, returns UDP port number
No, Creates a new session,return UDP port number
Rewrite media ip:port
17
RTP Proxy - Operation When SIP server receives SIP response from
UA2 with SDP
Session of call-id exist?
extracts call-id
No, return error code
Yes, return UDP port number
Rewrite media ip:port
18
RTP Proxy - Operation After session is created, RTP proxy listens on
the port for filling in the ip:port structure of two side parties.
RTP streams
10.10.59.62 : 32768
10.10.21.17 : 7080
top related