This article describes the issue of NIS traffic, which utilizes the SUN-RPC ALG, not passing through, when specific SUN-RPC applications are used.
The Network Information Service or NIS (originally known as Yellow Pages or YP) is a client–server directory service protocol for distributing system configuration data, such as user and host names, between computers on a computer network. At times, it is used to provide authentication support for systems. All of the possible Sun RPC sessions are initiated over port TCP/UDP/111. Each host can then link the required RPC to an open TCP/UDP port and allow the client to connect to the port. This port information is communicated to the client over the TCP/UDP/111 control channel. The same RPC can be running on different ports on different hosts. These data ports are negotiated between the client and server by using GETPORT messages. It is the job of the SUN-RPC ALG to parse these messages and pinhole the negotiated data-ports. When NIS (yellow Pages) traffic is used, the closest SUN-RPC applications that are available in junos-defaults and expected to allow this traffic are:
#show usp algs sun-rpc map-table
root@FW-SJ-DMZ-SRX-1# run start shell
root@650-1% vty fwdd
root@FW-SJ-DMZ-SRX-1% vty node0.fpc7.pic0 BSD platform (XLR processor, 4095MB memory, 16384KB flash)
[flowd]FPC7.PIC0(vty)# sh usp alg sun-rpc map-table Sun RPC service mapping - hashed by (ip, port, prot) Bkt Lsys IP Port Prot Program 150 NULL 192.168.2.167 742 UDP 100004 153 NULL 192.168.2.167 743 TCP 100004 160 NULL 192.168.12.212 819 UDP 100004 193 NULL 192.168.3.41 632 TCP 100004 193 NULL 192.168.3.41 632 TCP 100004 5 record(s)
This issue is due to the unique design of SUN-RPC, in which it uses program numbers in the policy applications, rather that IP addresses ports. The applications that are defined in the policies must have a match of the program number with the corresponding program number in the sun-rpc map-table . If the match does not exist, the traffic is dropped. There are two NIs flavors:
A workaround for this issue is to create a customer application that opens the ports, which are learnt dynamically from the server; in this case, it is 632 . When this is explicitly allowed, there is no need for the dynamic table and program number association. You can create a custom application that mimics SUN-RPC-PROGRAM-YPBIND ; except, the program number will be 100004 :
root@Replication# show applications application SUN-RPC-PROGRAM-NIS-yellow-pages term t1 protocol udp rpc-program-number 100004; term t1 protocol tcp rpc-program-number 100004;