Let me see if I got this right...

1) HDFS is configured to trust the NFS gateway as a proxy user. 
2) NFS gateway will make RPC connections to HDFS with the real user and the effective user.   
    Does userName refer to the real user or the effective user?  I think you should change the variable names and add descriptions to the @params since this code is so sensitive.
3) HDFS will assert that the NFS gateway is a valid proxy by comparing its ip addr to the configuration from (1).   
4) ??? I'd imagine HDFS also validates the NFS gateways kerberos ticket, but I couldn't find any mention of that.   Hmmm...  ???
5) HDFS will assert that the effective user is a member of the proxy user's groups from (1).

So it bottoms out on HDFS trusting the NFS gateway to have authenticated its own clients.    How does the NFS gateway authenticate its own clients?   I think the answer is that the operating system does that.... so any process that runs on the box that speaks this protocol can act on behalf of any user in the NFS gateway's proxy user groups.

Correct?